This patch implements the command and Makefile target::
./manage test.pyright
make test.pyright
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Pyright [1] is in the nvm enviroment, may be you need to rebuild the nvm
environment and install nodejs in::
./manage nvm.clean
./manage nvm.nodejs
The last command installs nodejs and the packages from .nvm_packages.
You can test your pyright installation, to get a bash within the nvm run::
./manage nvm.bash
(nvm) $ which pyright
./.nvm/versions/node/v16.13.0/bin/pyright
If you have a local nvm in your HOME folder, the output from ``which`` is
different. Press ``[CTRL-D]`` to get out of this bash.
[1] https://github.com/microsoft/pyright
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Without specifying folders to check, pyright will also scan files in folders
like ./build, ./cache, ./.nvm and more.
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
By adding this file Pyright automatically detects the
packages from our Python virtual environment.
This can be tested by using the Pyright extension
for VS Code or by running npx pyright.
Since https://github.com/searxng/searxng/pull/354
the searx.network.stream(...) returns a tuple
This commits update the checker code according to
this function signature change.
With Sphinx-doc update 4.4.0 we get some warnings about links that can be
replaced by already defined 'sphinx.ext.extlinks':
admin/engines/sql-engines.rst:144: WARNING: hardcoded link 'https://pypi.org/project/mysql-connector-python' could be replaced by an extlink (try using ':pypi:`mysql-connector-python`' instead)
docs/admin/installation-switch2ng.rst:10: WARNING: hardcoded link 'https://github.com/searxng/searxng/pull/446#issuecomment-954730358' could be replaced by an extlink (try using ':pull:`446#issuecomment-954730358`' instead)
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
$ make test.shell
./manage line 716:
build_msg TEST "[reST markup] ${RST_FILES[@]}""
^-------------^ SC2145: Argument mixes string and array. Use * or separate argument.
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
webapp.py monkey-patches the Flask request global.
This commit adds a type cast so that e.g. Pyright[1]
doesn't show "Cannot access member" errors everywhere.
[1]: https://github.com/microsoft/pyright
* add "Differences to searx" section
* normalize some reST markup & trailing whitespace
* Use `===` and `----` to markup chapters & sections (like we use in other
documentations).
Co-authored-by: Markus Heiser <markus.heiser@darmarit.de>
Co-authored-by: Alexandre Flament <alex@al-f.net>
* mirror all inline SVGs so that direction SVGs display correctly on RTL
* set the bold list element in info box to RTL so the colon gets displayed on the right side
* set correct .ltr function for the left border on the search button in #q
* move text to the right in autocomplete
* move search form in lign with result article on RTL
* add the correct padding for img thumbnails in categories like music on RTL
* apply RTL to result table for map results
* align text in tables part of /preferences on RTL
* move burger menu on index page to the left on RTL
* fix positioning of drop down arrow on select boxes on RTL
* align result URL on the right (written LTR)
* align vim hotkeys help on the left since it is not translated
* image detail:
* labels (author, format, URL, etc...) are written on the right,
values are on the left.
* URL are written LTR and overflow on the right