Resolve Phantom Dependency problems #1

Merged
mu-hun merged 2 commits from patch/phantom-dependency into main 2022-09-02 17:10:24 +02:00
mu-hun commented 2022-09-02 16:16:02 +02:00 (Migrated from github.com)

I'm having two issues related Phantom Dependency in Yarn berry:

✘ [ERROR] Could not resolve "@codemirror/view"

    ../../node_modules/.store/@codemirror-lang-html-npm-6.1.0-c047364f83/node_modules/@codemirror/lang-html/dist/index.js:4:27:
      4 │ import { EditorView } from '@codemirror/view';
        ╵                            ~~~~~~~~~~~~~~~~~~

⬆️ In HEAD/src/html.ts#L4 referring @codemirror/view but the package isn't included in the package.json.

✘ [ERROR] Could not resolve "@lezer/common"

    ../../node_modules/.store/@lezer-html-npm-1.0.0-f4e61d2cf6/node_modules/@lezer/html/dist/index.es.js:3:27:
      3 │ import { parseMixed } from '@lezer/common';
        ╵                            ~~~~~~~~~~~~~~~

⬆️ This issue has been resolved in @lezer/html@1.0.1, so I suggest upgrading.


Yarn berry is a package manager that blocks phantom dependency issues.

  • For npm or yarn classic users, this is a problem you won't run into
  • if you're using a Yarn berry(v2~) that completely blocks Phantom dependencies, you can't avoid it

If possible, I would like to upgrade to a version that fixes this problem and use it.. 🥺


Additional proposals: Package lock files

How about create package-lock.json or yarn.lock as a lock file?

I'm having two issues related Phantom Dependency in Yarn berry: ``` ✘ [ERROR] Could not resolve "@codemirror/view" ../../node_modules/.store/@codemirror-lang-html-npm-6.1.0-c047364f83/node_modules/@codemirror/lang-html/dist/index.js:4:27: 4 │ import { EditorView } from '@codemirror/view'; ╵ ~~~~~~~~~~~~~~~~~~ ``` ⬆️ In [`HEAD/src/html.ts#L4`](https://github.com/codemirror/lang-html/blob/afd2e86f/src/html.ts#L4) referring `@codemirror/view` but the package isn't included in the `package.json`. ``` ✘ [ERROR] Could not resolve "@lezer/common" ../../node_modules/.store/@lezer-html-npm-1.0.0-f4e61d2cf6/node_modules/@lezer/html/dist/index.es.js:3:27: 3 │ import { parseMixed } from '@lezer/common'; ╵ ~~~~~~~~~~~~~~~ ``` ⬆️ This issue has been resolved in `@lezer/html@1.0.1`, so I suggest upgrading. --- Yarn berry is a package manager that blocks [phantom dependency](https://rushjs.io/pages/advanced/phantom_deps/) issues. - For npm or yarn classic users, this is a problem you won't run into - if you're using a Yarn berry(v2~) that completely blocks Phantom dependencies, you can't avoid it If possible, I would like to upgrade to a version that fixes this problem and use it.. 🥺 --- ### Additional proposals: Package lock files How about create `package-lock.json` or `yarn.lock` as a [lock file](https://nodejs.dev/en/learn/the-package-lockjson-file/)?
marijnh commented 2022-09-02 16:28:39 +02:00 (Migrated from github.com)

Your patch upgrades @lezer/common and removes the dependency on @lezer/html. Is that intentional?

Your patch upgrades @lezer/common and _removes_ the dependency on @lezer/html. Is that intentional?
mu-hun commented 2022-09-02 16:58:19 +02:00 (Migrated from github.com)

It was my mistake 😅. I amend latest commit and did a force push, so please review it again 🙏🏻 .

It was my mistake 😅. I amend latest commit and did a force push, so please review it again 🙏🏻 .
mu-hun commented 2022-09-05 08:50:25 +02:00 (Migrated from github.com)

I would like to upgrade to a version that fixes this problem and use it.. 🥺 Could you please upload a new version to NPM..?

I would like to upgrade to a version that fixes this problem and use it.. 🥺 Could you please upload a new version to NPM..?
marijnh commented 2022-09-05 10:36:21 +02:00 (Migrated from github.com)

Sure. I've tagged 6.1.1

Sure. I've tagged 6.1.1
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
codemirror/lang-html!1
No description provided.