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

TypeScript declarations broken in 9.0.4 #169

Open
grzegorzjudas opened this issue Jan 17, 2022 · 5 comments
Open

TypeScript declarations broken in 9.0.4 #169

grzegorzjudas opened this issue Jan 17, 2022 · 5 comments
Labels
need/triage Needs initial labeling and prioritization

Comments

@grzegorzjudas
Copy link

Hello,

after recent clean install of project dependencies (after removal of package-lock) we stumbled upon a build failure:

node_modules/ipfs-utils/dist/src/files/glob-source.d.ts:10:14 - error TS2503: Cannot find namespace 'fs'.

10     content: fs.ReadStream | undefined;

After examining the contents of that file, it looks like the fs has no reference. It worked in 9.0.2, so I downgraded and found that there's a missing part at the top:

/// <reference types="node" />

that causes the build to fail.

I'm not too sure what changed between the versions, but the downgrade definitely did the trick.

@grzegorzjudas grzegorzjudas added the need/triage Needs initial labeling and prioritization label Jan 17, 2022
@welcome
Copy link

welcome bot commented Jan 17, 2022

Thank you for submitting your first issue to this repository! A maintainer will be here shortly to triage and review.
In the meantime, please double-check that you have provided all the necessary information to make this process easy! Any information that can help save additional round trips is useful! We currently aim to give initial feedback within two business days. If this does not happen, feel free to leave a comment.
Please keep an eye on how this issue will be labeled, as labels give an overview of priorities, assignments and additional actions requested by the maintainers:

  • "Priority" labels will show how urgent this is for the team.
  • "Status" labels will show if this is ready to be worked on, blocked, or in progress.
  • "Need" labels will indicate if additional input or analysis is required.

Finally, remember to use https://discuss.ipfs.io if you just need general support.

@raress96
Copy link

Hello, I also have this same problem
Cannot find namespace 'fs'

Waiting for a fix, until then will downgrade I guess.

@jagadeeshmarali
Copy link

Hello, I also have this same problem Cannot find namespace 'fs'

Waiting for a fix, until then will downgrade I guess.

To which version we should downgrade.?

@raress96
Copy link

raress96 commented Feb 4, 2022

Hello, I also have this same problem Cannot find namespace 'fs'
Waiting for a fix, until then will downgrade I guess.

To which version we should downgrade.?

I downgraded to 9.0.2 and it works fine.

@H3xept
Copy link

H3xept commented Mar 23, 2022

Bump, this is still an issue.

node_modules/ipfs-utils/dist/src/files/glob-source.d.ts:10:14 - error TS2503: Cannot find namespace 'fs'.

10 content: fs.ReadStream | undefined;
~~

Found 1 error in node_modules/ipfs-utils/dist/src/files/glob-source.d.ts:10

A naive temporary solution is to patch the glob-source.d.ts file making it import fs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
need/triage Needs initial labeling and prioritization
Projects
None yet
Development

No branches or pull requests

4 participants