-
Notifications
You must be signed in to change notification settings - Fork 83
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
Update vite and vitest, compile and fix tests #410
Conversation
6361faa
to
75bc208
Compare
@kaisalmen
Is it an inversify <-> typescript version mismatch? |
This should have been prevented by fixing the version to |
It says:
|
@kaisalmen |
15433c1
to
fb1432d
Compare
Done. vscode related problems should be fixed. Tests execution is instable. The test themselves are bot broken. Code issues are fixed. Happens more often in the pipeline. Don't know why, yet. Will investigate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Running the tests in Gitpod I get
FAIL packages/sprotty/src/base/commands/command-stack.spec.ts [ packages/sprotty/src/base/commands/command-stack.spec.ts ]
Error: Expression expected
❯ error node_modules/rollup/dist/es/shared/parseAst.js:337:30
❯ nodeConverters node_modules/rollup/dist/es/shared/parseAst.js:2084:9
❯ convertNode node_modules/rollup/dist/es/shared/parseAst.js:969:12
❯ convertProgram node_modules/rollup/dist/es/shared/parseAst.js:960:48
❯ parseAstAsync node_modules/rollup/dist/es/shared/parseAst.js:2150:20
❯ ssrTransformScript node_modules/vite/dist/node/chunks/dep-YJaePtkC.js:49505:15
❯ loadAndTransform node_modules/vite/dist/node/chunks/dep-YJaePtkC.js:49093:11
It may be vitest problem. I am not sure, yet. Happens very rarely on Windows, more likely on Linux. |
ed0eff3
to
3c9a3ef
Compare
@dhuebner and @spoenemann squashed all commits into one and removed all unrelated dependency changes. Dependency changes are only related to vite and vitest. vite v5 itself require node 18, so I kept that change. All compiler adjustments and test fixes are kept as well. The vitest instability is still not resolved. I am digging into this now... |
- Fix vscode issue. Add proper tsc build configuration to examples integrate it into overall watch - Fix references to local projects not resolved in vscode, fix lint, remove tasks - Add test code compilation - Only use one thread for test execution - Update inversify and reflect-metadata
3c9a3ef
to
68e17bc
Compare
@dhuebner and @spoenemann this is now ready for review. Description is now up-to-date with performed changes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No inversify type errors in the IDE, nice! :-) Tests are passing.
One thing we need to keep an eye on are regex inclusion exclusion patterns. We have a folder named lib
in packages/sprotty/src/lib
and the output folders are also named lib
. However, right now it seams to work well!
vite
is now explicitly included as devDependency, so its version is more transparent.There were a couple of undetected compilation errors in spec files. Therefore special
tsconfig.test.json
withnoEmit=true
have been added. They are included in the main compilation now.tsconfig.src.json
cover the regular code compilation.tsconfig.json
are required for vscode/eslint only now (we do the same in other projects, e.g. Langium). Alle"type": []
usages has been removed from tsconfig files as they shadows type issues. ThereforeskipLibCheck
is needed in test configs to shadow snabbdom and rollup type definition errors.Node version in GitHub Action is upgraded to node 18. vite v5 requires it.
Volta instructions have been added.
Test were unstable with new default setting. Reason is unknown. It could be inversify not being safe with regard to concurrency, but that is speculation. pool is now configured to use only one worker thread.
inversify
andreflect-metadata
have been updated to~6.0.2
and~0.1.14
respectively.