-
Notifications
You must be signed in to change notification settings - Fork 15
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
Migrate to flat eslint
config file
#137
Conversation
@janosh. Would appreciate it if you have time to have a look (I have absolutely zero knowledge of javascript), not sure why
|
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.
thanks @DanielYang59! 👍
Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'eslint-plugin-svelte' imported from /Users/yang/developer/pymatviz/site/eslint.config.js
i had the same error over at matbench-discovery
which is why i just skipped eslint
there. i suspect it's a node
version incompatibility. i.e. that the default node
installed by pre-commit CI is too old. i briefly tried to fix that but didn't manage. not important enough to spend time on 😄
No worries at all :)
Ah, that's bad news. I would personally prefer to use the legacy config then if so. Even we suppressed pre-commit run --all-files
ruff.....................................................................Passed
ruff-format..............................................................Passed
mypy.....................................................................Passed
Format iPython Cells.....................................................Passed
check for case conflicts.................................................Passed
check for broken symlinks................................................Passed
check yaml...............................................................Passed
detect destroyed symlinks................................................Passed
fix end of files.........................................................Passed
mixed line ending........................................................Passed
trim trailing whitespace.................................................Passed
codespell................................................................Passed
nbstripout...............................................................Passed
No missing readme images.................................................Passed
prettier.................................................................Passed
eslint...................................................................Failed
- hook id: eslint
- exit code: 2
Oops! Something went wrong! :(
ESLint: 9.1.1
Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'eslint-plugin-svelte' imported from /Users/yang/developer/pymatviz/site/eslint.config.js
Did you mean to import "eslint-plugin-svelte/lib/index.js"?
at packageResolve (node:internal/modules/esm/resolve:845:9)
at moduleResolve (node:internal/modules/esm/resolve:918:18)
at defaultResolve (node:internal/modules/esm/resolve:1148:11)
at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:528:12)
at ModuleLoader.resolve (node:internal/modules/esm/loader:497:25)
at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:231:38)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:97:39)
at link (node:internal/modules/esm/module_job:96:36)
Oops! Something went wrong! :(
ESLint: 9.1.1
Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'eslint-plugin-svelte' imported from /Users/yang/developer/pymatviz/site/eslint.config.js
Did you mean to import "eslint-plugin-svelte/lib/index.js"?
at packageResolve (node:internal/modules/esm/resolve:845:9)
at moduleResolve (node:internal/modules/esm/resolve:918:18)
at defaultResolve (node:internal/modules/esm/resolve:1148:11)
at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:528:12)
at ModuleLoader.resolve (node:internal/modules/esm/loader:497:25)
at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:231:38)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:97:39)
at link (node:internal/modules/esm/module_job:96:36)
Oops! Something went wrong! :(
ESLint: 9.1.1
Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'eslint-plugin-svelte' imported from /Users/yang/developer/pymatviz/site/eslint.config.js
Did you mean to import "eslint-plugin-svelte/lib/index.js"?
at packageResolve (node:internal/modules/esm/resolve:845:9)
at moduleResolve (node:internal/modules/esm/resolve:918:18)
at defaultResolve (node:internal/modules/esm/resolve:1148:11)
at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:528:12)
at ModuleLoader.resolve (node:internal/modules/esm/loader:497:25)
at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:231:38)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:97:39)
at link (node:internal/modules/esm/module_job:96:36)
Oops! Something went wrong! :(
ESLint: 9.1.1
Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'eslint-plugin-svelte' imported from /Users/yang/developer/pymatviz/site/eslint.config.js
Did you mean to import "eslint-plugin-svelte/lib/index.js"?
at packageResolve (node:internal/modules/esm/resolve:845:9)
at moduleResolve (node:internal/modules/esm/resolve:918:18)
at defaultResolve (node:internal/modules/esm/resolve:1148:11)
at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:528:12)
at ModuleLoader.resolve (node:internal/modules/esm/loader:497:25)
at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:231:38)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:97:39)
at link (node:internal/modules/esm/module_job:96:36)
Oops! Something went wrong! :(
ESLint: 9.1.1
Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'eslint-plugin-svelte' imported from /Users/yang/developer/pymatviz/site/eslint.config.js
Did you mean to import "eslint-plugin-svelte/lib/index.js"?
at packageResolve (node:internal/modules/esm/resolve:845:9)
at moduleResolve (node:internal/modules/esm/resolve:918:18)
at defaultResolve (node:internal/modules/esm/resolve:1148:11)
at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:528:12)
at ModuleLoader.resolve (node:internal/modules/esm/loader:497:25)
at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:231:38)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:97:39)
at link (node:internal/modules/esm/module_job:96:36)
pyright..................................................................Passed |
I've been considering migrating typescript+svelte linting to https://github.com/oxc-project/oxc altogether. not sure how complete its feature set is at this point but |
closes #136