forked from zaclys/searxng
[fix] ensure that test.pyright installs pyright
nodejs.ensure only sets up NVM if there isn't a system-wide installation of Node that matches our NODE_MINIMUM_VERSION. The ubuntu image in the CI comes with an up to date node version, so pyright from .nvm_packages is never installed. This commit fixes this by introducing a package.json file.
This commit is contained in:
parent
96450b17d4
commit
6d701d2fea
|
@ -16,3 +16,6 @@ dist/
|
||||||
local/
|
local/
|
||||||
gh-pages/
|
gh-pages/
|
||||||
*.egg-info/
|
*.egg-info/
|
||||||
|
|
||||||
|
/package-lock.json
|
||||||
|
/node_modules/
|
||||||
|
|
|
@ -5,5 +5,4 @@
|
||||||
# [1] https://github.com/nvm-sh/nvm#default-global-packages-from-file-while-installing
|
# [1] https://github.com/nvm-sh/nvm#default-global-packages-from-file-while-installing
|
||||||
|
|
||||||
eslint
|
eslint
|
||||||
pyright
|
|
||||||
|
|
||||||
|
|
3
manage
3
manage
|
@ -687,9 +687,10 @@ test.pylint() {
|
||||||
test.pyright() {
|
test.pyright() {
|
||||||
build_msg TEST "[pyright] static type check of python sources"
|
build_msg TEST "[pyright] static type check of python sources"
|
||||||
nodejs.ensure
|
nodejs.ensure
|
||||||
|
npm install
|
||||||
# We run Pyright in the virtual environment because Pyright
|
# We run Pyright in the virtual environment because Pyright
|
||||||
# executes "python" to determine the Python version.
|
# executes "python" to determine the Python version.
|
||||||
pyenv.cmd pyright -p pyrightconfig-ci.json
|
pyenv.cmd npx --no-install pyright -p pyrightconfig-ci.json
|
||||||
dump_return $?
|
dump_return $?
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"dependencies": {
|
||||||
|
"pyright": "^1.1.212"
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue