Skip to content

fix(KNO-9523): import jose statically - #124

Merged
mattmikolay merged 2 commits into
mainfrom
mattmik-kno-9523-node-sdk-import-jose-statically
Aug 19, 2025
Merged

fix(KNO-9523): import jose statically#124
mattmikolay merged 2 commits into
mainfrom
mattmik-kno-9523-node-sdk-import-jose-statically

Conversation

@mattmikolay

Copy link
Copy Markdown
Contributor

This PR updates lib/tokenSigner.ts to import jose statically rather than dynamically. This is safe because jose is no longer an optional peer dependency in this codebase.

It remains TBD if this will make our token signing work with Node’s experimental support for loading ES modules using require, because jose’s README does in fact indicate it should.

@linear

linear Bot commented Aug 19, 2025

Copy link
Copy Markdown

Comment thread .tool-versions
@@ -0,0 +1 @@
nodejs 20.19.4

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

My local machine was using Node v20.9.0, which does not have the ability to require ES modules enabled by default. This led to build failures and test run failures.

So, to avoid having to pass in the --experimental-require-module flag everywhere, I’m adding a .tool-versions file that uses v20.9.

@mattmikolay
mattmikolay marked this pull request as ready for review August 19, 2025 21:33
@mattmikolay
mattmikolay requested a review from a team as a code owner August 19, 2025 21:33
@mattmikolay
mattmikolay requested review from connorlindsey, kylemcd and meryldakin and removed request for a team August 19, 2025 21:33
@mattmikolay
mattmikolay merged commit 5007d42 into main Aug 19, 2025
7 checks passed
@mattmikolay
mattmikolay deleted the mattmik-kno-9523-node-sdk-import-jose-statically branch August 19, 2025 22:05
This was referenced Aug 19, 2025
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.

3 participants