feat: preinstall Playwright and Puppeteer browser system dependencies (issue #68)#69
feat: preinstall Playwright and Puppeteer browser system dependencies (issue #68)#69
Conversation
Adding .gitkeep for PR creation (default mode). This file will be removed when the task is complete. Issue: #68
…wser dependencies) Compile CI logs, research findings, root cause analysis, and proposed solution for the missing Playwright/Puppeteer system dependencies issue. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… (issue #68) Add all OS-level library dependencies required by Chromium, Firefox, and WebKit to the sandbox-js base Dockerfile and essentials-sandbox install script. This eliminates the "Host system is missing dependencies to run browsers" warning reported in the hive-mind CI logs. Changes: - ubuntu/24.04/js/Dockerfile: add ~60 system packages for Playwright/Puppeteer (libasound2t64, libatk*, libcups2t64, libxkbcommon0, xvfb, fonts, etc.) - ubuntu/24.04/essentials-sandbox/install.sh: install playwright and @puppeteer/browsers CLIs globally via npm for all sandbox users All derived images (sandbox-essentials, sandbox-full) inherit the browser deps from the js base image. No manual `npx playwright install-deps` required. Fixes #68 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This reverts commit b2b4392.
🤖 Solution Draft LogThis log file contains the complete execution trace of the AI solution draft process. 💰 Cost estimation:
Now working session is ended, feel free to review and add any feedback on the solution draft. |
🔄 Auto-restart 1/3Detected uncommitted changes from previous run. Starting new session to review and commit them. Uncommitted files: Auto-restart will stop after changes are committed or after 2 more iterations. Please wait until working session will end and give your feedback. |
🔄 Auto-restart 1/3 LogThis log file contains the complete execution trace of the AI solution draft process. 💰 Cost estimation:
Now working session is ended, feel free to review and add any feedback on the solution draft. |
✅ Ready to mergeThis pull request is now ready to be merged:
Monitored by hive-mind with --auto-restart-until-mergeable flag |
Summary
Fixes #68
This PR adds all OS-level system library dependencies required to run Chromium, Firefox, and WebKit browsers via Playwright and Puppeteer. It also globally installs the
playwrightand@puppeteer/browsersCLI tools.Problem
When using
npx playwright installinside a container based onkonard/sandbox, browsers are downloaded but the host system is missing required OS libraries. Playwright emits:Observed in hive-mind CI: https://github.com/link-assistant/hive-mind/actions/runs/22902572178/job/66453518615
Root Cause
The
sandbox-jsbase Dockerfile only installs minimal prerequisites (curl git sudo ca-certificates unzip). The ~60 system libraries needed by browser engines (GTK, CUPS, D-Bus, libXkbcommon, ALSA, GStreamer, ATK, etc.) were absent.Solution
ubuntu/24.04/js/Dockerfile— Add the complete set of browser system dependencies as a newapt-get installlayer. Sincesandbox-jsis the base for all images (sandbox-essentials,sandbox-full), all derived images inherit these deps automatically.ubuntu/24.04/essentials-sandbox/install.sh— Add the same deps for standalone installs, and globally installplaywrightand@puppeteer/browsersCLIs via npm.docs/case-studies/issue-68/CASE-STUDY.md— Deep root cause analysis with CI log data, official dependency sources, and solution rationale.Packages Added
The complete union of Playwright (Chromium + Firefox + WebKit) and Puppeteer (Chrome) dependencies for Ubuntu 24.04:
libasound2t64,libatk-bridge2.0-0t64,libatk1.0-0t64,libcups2t64,libgbm1,libnspr4,libnss3,libxkbcommon0, and morelibavcodec60,libgtk-3-0t64,libpangocairo-1.0-0,libxcursor1, etc.gstreamer1.0-*,libenchant-2-2,libgtk-4-1,libgstreamer-*,libharfbuzz-*, etc.xvfb,fonts-liberation,fonts-noto-color-emoji,fonts-ipafont-gothic, etc.libxss1,libxtst6,xdg-utilsCLIs Installed
playwright—npx playwright install [chromium|firefox|webkit],npx playwright test@puppeteer/browsers—npx @puppeteer/browsers install chrome@stableReferences
This PR was created automatically by the AI issue solver