Skip to content

fix: migrate playwright-go to mxschmitt module path after deprecation - #2782

Open
faisalaffan wants to merge 1 commit into
terrastruct:masterfrom
faisalaffan:fix/migrate-playwright-go-to-mxschmitt
Open

fix: migrate playwright-go to mxschmitt module path after deprecation#2782
faisalaffan wants to merge 1 commit into
terrastruct:masterfrom
faisalaffan:fix/migrate-playwright-go-to-mxschmitt

Conversation

@faisalaffan

Copy link
Copy Markdown

Problem

github.com/playwright-community/playwright-go is deprecated. The project
has moved to github.com/mxschmitt/playwright-go.

Additionally, Microsoft CDN has removed all Playwright driver binaries
for versions 1.47 through 1.60, causing d2 init-playwright to fail with:

err: failed to install Playwright: could not install driver: could not install driver:
error: got non 200 status code: 404 (404 Not Found) from
https://playwright.azureedge.net/builds/driver/playwright-1.52.0-mac-arm64.zip

Fix

  • Migrate import path: playwright-community/playwright-gomxschmitt/playwright-go
  • Bump version: v0.5200.0v0.6100.0
  • Driver 1.61.0 is still available on Microsoft CDN

Changes

  • lib/png/png.go — import path
  • lib/xgif/xgif.go — import path
  • d2cli/main.go — import path
  • go.mod / go.sum — dependency update

Test

  • d2 init-playwright succeeds
  • Render to PNG/GIF/PDF works

Local Test

  • Test init playwright
image
  • Test render png to gif
image

playwright-community/playwright-go is deprecated and its bundled driver
versions (1.47–1.60) have been removed from Microsoft CDN, causing 404
errors on `d2 init-playwright`.

Migrate to github.com/mxschmitt/playwright-go v0.6100.0 which bundles
driver 1.61.0 — still available on CDN.
@faisalaffan

Copy link
Copy Markdown
Author

Hi @alixander, could you review this when you get a chance? This affects anyone trying to render non-SVG formats — with the deprecated module path and purged CDN drivers, d2 init-playwright is completely broken. Quite a few people are hitting this (seen in #2776 and elsewhere).

This is actually my first time contributing here. I discovered D2 through AI — tried PlantUML and Mermaid before, but neither came close to the completeness and beauty of D2, especially the animation support. Honestly mind-blowing to see a diagramming tool this polished. Huge respect for the work you've put into this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant