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

"`Polyfill Document.getElementsByClassName depends on document.querySelector, which does not exist within the polyfill-service" #134

Closed
weyert opened this issue Feb 19, 2019 · 1 comment

Comments

@weyert
Copy link

weyert commented Feb 19, 2019

What

After upgrading polyfill-library to 3.28.1 I am getting the following error while running yarn install:

Polyfill Document.getElementsByClassName depends on document.querySelector, which does not exist within the polyfill-service. Recommended to either add the missing polyfill or remove the dependency.

Log:

warning " > relish@2.1.0" has unmet peer dependency "hapi@>= 16.6.1 < 17".
[5/5] 🔨  Building fresh packages...
[-/6] ⠄ waiting...
[-/6] ⠄ waiting...
[6/6] ⠄ fsevents
[4/6] ⠄ polyfill-library
error /Users/weyert/Development/Projects/backend/node_modules/polyfill-library: Command failed.
Exit code: 1
Command: npm run build
Arguments: 
Directory: /Users/weyert/Development/Projects/backend/node_modules/polyfill-library
Output:
npm WARN lifecycle The node binary used for scripts is /var/folders/q_/g_m12x9x4gqg6r6zxjjfw8j80000gn/T/yarn--1550587547953-0.5868356523958553/node but npm is using /Users/weyert/.nvm/versions/node/v8.11.3/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.

> polyfill-library@3.28.1 build /Users/weyert/Development/Projects/backend/node_modules/polyfill-library
> npm run clean && node tasks/node/updatesources && node tasks/node/buildsources

npm WARN lifecycle The node binary used for scripts is /var/folders/q_/g_m12x9x4gqg6r6zxjjfw8j80000gn/T/yarn--1550587547953-0.5868356523958553/node but npm is using /Users/weyert/.nvm/versions/node/v8.11.3/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.

> polyfill-library@3.28.1 clean /Users/weyert/Development/Projects/backend/node_modules/polyfill-library
> rimraf ./polyfills/__dist

Updating third-party polyfills...
_TypedArray: New polyfill
  from ../js-polyfills/typedarray.js
~html5-elements: New polyfill
  from ../html5shiv/dist/html5shiv.min.js
atob: New polyfill
  from ../Base64/base64.js
AudioContext: New polyfill
  from ../audio-context-polyfill/AudioContext.js
EventSource: New polyfill
  from ../event-source-polyfill/eventsource.js
fetch: New polyfill
  from ../whatwg-fetch/fetch.js
 * Running module-specific update task update.task.js
HTMLPictureElement: New polyfill
  from ../picturefill/dist/picturefill.min.js
  from ../picturefill/dist/plugins/mutation/pf.mutation.min.js
Intl: New polyfill
  from ../intl/dist/Intl.min.js
 * Running module-specific update task update.task.js
Importing Intl.~locale.* polyfill from /Users/weyert/Development/Projects/backend/node_modules/intl/locale-data/jsonp
716 imported locales
Intl polyfill imported successfully
JSON: New polyfill
  from ../json3/lib/json3.js
MutationObserver: New polyfill
  from ../mutationobserver-shim/MutationObserver.js
Promise: New polyfill
  from ../yaku/dist/yaku.browser.global.min.js
UserTiming: New polyfill
  from ../usertiming/src/usertiming.js
WebAnimations: New polyfill
  from ../web-animations-js/web-animations.min.js
Polyfills updated successfully
Writing compiled polyfill sources to /Users/weyert/Development/Projects/backend/node_modules/polyfill-library/polyfills/__dist/...
Polyfill Document.getElementsByClassName depends on document.querySelector, which does not exist within the polyfill-service. Recommended to either add the missing polyfill or remove the dependency.
"Polyfill Document.getElementsByClassName depends on document.querySelector, which does not exist within the polyfill-service. Recommended to either add the missing polyfill or remove the dependency."
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! polyfill-library@3.28.1 build: `npm run clean && node tasks/node/updatesources && node tasks/node/buildsources`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the polyfill-library@3.28.1 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

Details

I have been trying to upgrade polyfill-library by removing all existing node_modules-directory before running yarn install.

I am not sure if this is a local issue or something polypill related issue within this project? I have tried 3.28.0 and in that version it installs successfully and not getting the above error

@JakeChampion
Copy link
Owner

I've installed the latest polyfill-library with npm and with yarn, they are both installing it correctly.

I'll be closing the issue as I cannot reproduce.

If you are able to make a reproducible example, please comment on this issue and I will re-open it :-)

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 16, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants