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

chore: update TS versions for TD and TM #845

Merged

Conversation

danielpeintner
Copy link
Member

No description provided.

@danielpeintner
Copy link
Member Author

We have issues in browser-bundle... grr
I had the locally too but was hoping it is a caching issue... need to look into

@relu91
Copy link
Member

relu91 commented Oct 17, 2022

@danielpeintner
Copy link
Member Author

danielpeintner commented Oct 18, 2022

What about this error: https://github.com/eclipse/thingweb.node-wot/actions/runs/3263939568/jobs/5363790618 ?

Thanks! I missed to store an opened file ...
I will provide an update.

@danielpeintner
Copy link
Member Author

The issue with browserify remains :-(
https://github.com/eclipse/thingweb.node-wot/actions/runs/3273332391/jobs/5385413069

@danielpeintner
Copy link
Member Author

The error message is as follows (at least locally)

> build
> tsc -b && npm run build -w packages/browser-bundle

error TS2688: Cannot find type definition file for 'bl'.
  The file is in the program because:
    Entry point for implicit type library 'bl'

error TS2688: Cannot find type definition file for 'bl'.
  The file is in the program because:
    Entry point for implicit type library 'bl'

Found 2 errors.

https://www.npmjs.com/package/@types/bl seems to be used by coap.

@JKRhb maybe you know whether those types are used somewhere not properly... I might be wrong but maybe you have a hint..

@JKRhb
Copy link
Member

JKRhb commented Nov 22, 2022

Hmm, I tried to reproduce the error, @danielpeintner, but I haven't seen any issues regarding bl locally :/ Instead I am getting the same errors as in the CI job.

However, one of the issues linked in browserify/browserify#1986 seems to have a similar problem (see rdfjs/N3.js#310), related to readable-stream. That module got recently updated to the latest version in node-coap, so my guess would be that this could be the root cause here :/

Edit: One comment in the last issue I linked suggests a workaround until the bug is fixed in browserify: rdfjs/N3.js#310 (comment)

@danielpeintner
Copy link
Member Author

Hmm, I tried to reproduce the error, @danielpeintner, but I haven't seen any issues regarding bl locally :/ Instead I am getting the same errors as in the CI job.

Very strange... the issue locally does not go away. If I call npm install I also see the following warning

npm WARN deprecated @types/bl@5.1.0: This is a stub types definition. bl provides its own type definitions, so you do not need this installed.

According to package-lock.json it is just used in node coap. I found also
https://github.com/coapjs/node-coap/blob/b66eac03a45cc1c6f1ee8b942bdc5f2f45e06dc4/package.json#L60

According to my understanding and https://www.npmjs.com/package/@types/bl it should not be installed directly. Am I wrong?

However, one of the issues linked in browserify/browserify#1986 seems to have a similar problem (see rdfjs/N3.js#310), related to readable-stream. That module got recently updated to the latest version in node-coap, so my guess would be that this could be the root cause here :/

Edit: One comment in the last issue I linked suggests a workaround until the bug is fixed in browserify: rdfjs/N3.js#310 (comment)

I tried to add the workaround but I cannot check locally whether it works (see issue before)
However, I noticed that now also the CI fails with the same problem.
see https://github.com/eclipse/thingweb.node-wot/actions/runs/3530119538/jobs/5921767506
@JKRhb any idea?

@JKRhb
Copy link
Member

JKRhb commented Nov 23, 2022

Thanks for the hint regarding the bl types! I will remove them from node-coap shortly -- maybe that already resolves the problem :)

node_modules/modbus-serial/ModbusRTU.d.ts:2:22 - error TS7016: Could not find a declaration file for module './ports/testport'. 'C:/Projects/WoT/thingweb/thingweb.node-wot-danielpeintner/node_modules/modbus-serial/ports/testport.js' implicitly has an 'any' type.

2 import TestPort from './ports/testport';
@danielpeintner
Copy link
Member Author

node-coap v1.2.2 seems to have resolved the coap issue. Thanks @JKRhb!

@danielpeintner
Copy link
Member Author

firestore fails. Other than that I think this PR is finally fine now.

@relu91 ?

Copy link
Member

@relu91 relu91 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Talked offline, it seems that also the browser examples work! merging.

@relu91 relu91 merged commit bbe1622 into eclipse-thingweb:master Nov 29, 2022
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.

None yet

3 participants