Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<img src="#x"> crashes the builder #3186

Closed
peterbe opened this issue Mar 10, 2021 · 0 comments · Fixed by #3187
Closed

<img src="#x"> crashes the builder #3186

peterbe opened this issue Mar 10, 2021 · 0 comments · Fixed by #3187
Assignees

Comments

@peterbe
Copy link
Contributor

peterbe commented Mar 10, 2021

Put this into a HTML page:

<img src="#x">

This is what happens if you try to view the page:

2:49:18 PM server.1     |  Error in buildDocumentFromURL(/en-us/docs/web/api/window/personalbar/) Error: The document's slug (Web/API/Window/personalbar) doesn't match its disk folder name (en-us/web/api/window/personalbar/)
2:49:18 PM server.1     |      at buildDocument (/Users/peterbe/dev/MOZILLA/MDN/yari/build/index.js:220:11)
2:49:18 PM server.1     |      at buildDocumentFromURL (/Users/peterbe/dev/MOZILLA/MDN/yari/server/index.js:52:16)
2:49:18 PM server.1     |      at /Users/peterbe/dev/MOZILLA/MDN/yari/server/index.js:220:25
2:49:18 PM server.1     |      at Layer.handle [as handle_request] (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/express/lib/router/layer.js:95:5)
2:49:18 PM server.1     |      at next (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/express/lib/router/route.js:137:13)
2:49:18 PM server.1     |      at Route.dispatch (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/express/lib/router/route.js:112:3)
2:49:18 PM server.1     |      at Layer.handle [as handle_request] (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/express/lib/router/layer.js:95:5)
2:49:18 PM server.1     |      at /Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/express/lib/router/index.js:281:22
2:49:18 PM server.1     |      at param (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/express/lib/router/index.js:354:14)
2:49:18 PM server.1     |      at param (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/express/lib/router/index.js:365:14)

This is what happens when you try to yarn build a HTML file that contains that:

▶ yarn build /Users/peterbe/dev/MOZILLA/MDN/content/files/en-us/web/api/window/personalbar/index.html
yarn run v1.22.10
$ cross-env NODE_ENV=production node build/cli.js /Users/peterbe/dev/MOZILLA/MDN/content/files/en-us/web/api/window/personalbar/index.html

Building Documents...
Building roots: [ '/Users/peterbe/dev/MOZILLA/MDN/content/files' ]
Building roots: [ '/Users/peterbe/dev/MOZILLA/MDN/content/files' ]
Error: ENOTSUP: operation not supported on socket, copyfile '/Users/peterbe/dev/MOZILLA/MDN/content/files/en-us/web/api/window/personalbar/' -> '/Users/peterbe/dev/MOZILLA/MDN/yari/client/build/en-us/docs/web/api/window/personalbar/personalbar'
    at Object.copyFileSync (node:fs:2016:3)
    at buildDocuments (/Users/peterbe/dev/MOZILLA/MDN/yari/build/cli.js:185:10)
    at processTicksAndRejections (node:internal/process/task_queues:93:5)
    at async Se._action (/Users/peterbe/dev/MOZILLA/MDN/yari/build/cli.js:286:60)
    at async Se.run (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/@caporal/core/dist/index.js:1:27579)
    at async Te._run (/Users/peterbe/dev/MOZILLA/MDN/yari/node_modules/@caporal/core/dist/index.js:1:32257) {
  errno: -45,
  syscall: 'copyfile',
  code: 'ENOTSUP',
  path: '/Users/peterbe/dev/MOZILLA/MDN/content/files/en-us/web/api/window/personalbar/',
  dest: '/Users/peterbe/dev/MOZILLA/MDN/yari/client/build/en-us/docs/web/api/window/personalbar/personalbar'
}

error: ENOTSUP: operation not supported on socket, copyfile '/Users/peterbe/dev/MOZILLA/MDN/content/files/en-us/web/api/window/personalbar/' -> '/Users/peterbe/dev/MOZILLA/MDN/yari/client/build/en-us/docs/web/api/window/personalbar/personalbar'

error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
peterbe added a commit to peterbe/yari that referenced this issue Mar 10, 2021
@peterbe peterbe self-assigned this Mar 10, 2021
escattone pushed a commit that referenced this issue Mar 10, 2021
peterbe added a commit to peterbe/yari that referenced this issue Jun 1, 2021
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 a pull request may close this issue.

1 participant