Skip to content
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

Minified js stemmers not included in the pypi distribution 3.5.0 #8884

Closed
heitorPB opened this issue Feb 14, 2021 · 6 comments
Closed

Minified js stemmers not included in the pypi distribution 3.5.0 #8884

heitorPB opened this issue Feb 14, 2021 · 6 comments

Comments

@heitorPB
Copy link

Describe the bug
Updated Sphinx to 3.5.0 and got a warning (treated as error with SPHINXOPTS="-W" make html) that FileNotFoundError: [Errno 2] No such file or directory: 'venv/lib/python3.9/site-packages/sphinx/search/minified-js/base-stemmer.js'

Downgrading to sphinx 3.4.3 fixes the problem.

To Reproduce
Steps to reproduce the behavior:

$ git clone https://github.com/grupy-sanca/curso-python
$ cd curso-python
$ virtualenv venv && source venv/bin/activate
$ pip install -r requirements.txt
$ make html SPHINXOPTS="-WT"

[ommited checks]

Traceback (most recent call last):
  File "/home/h/projects/curso-python-intro-plus/venv/lib/python3.9/site-packages/sphinx/builders/html/__init__.py", line 806, in copy_static_files
    context.update(self.indexer.context_for_searchtool())
  File "/home/h/projects/curso-python-intro-plus/venv/lib/python3.9/site-packages/sphinx/search/__init__.py", line 442, in context_for_searchtool
    'search_language_stemming_code': self.get_js_stemmer_code(),
  File "/home/h/projects/curso-python-intro-plus/venv/lib/python3.9/site-packages/sphinx/search/__init__.py", line 465, in get_js_stemmer_code
    with open(path.join(js_dir, 'base-stemmer.js')) as js_file:
FileNotFoundError: [Errno 2] No such file or directory: '/home/h/projects/curso-python-intro-plus/venv/lib/python3.9/site-packages/sphinx/search/minified-js/base-stemmer.js'

Expected behavior
No warning/error on Sphinx js files.

Environment info

  • OS: ArchLinux
  • Python version: 3.9
  • Sphinx version: 3.5.0
  • Sphinx extensions: sphinxcontrib-spelling
@heitorPB
Copy link
Author

curiously, on sphinx 3.4.3 there's no warning/error, but those minified files also don't exist.

@mitya57
Copy link
Contributor

mitya57 commented Feb 14, 2021

It was my change which broke this — so sorry for the inconvenience. I created PR #8886 to fix this.

@heitorPB
Copy link
Author

Thanks for fixing it quickly! Do you think it is possible to release 3.5.1 with this fix soon? I'm not sure how/if this bug affects other projects

@mitya57
Copy link
Contributor

mitya57 commented Feb 14, 2021

Do you think it is possible to release 3.5.1 with this fix soon?

I am not a project member, just a contributor, so that's a question to @tk0miya.

@tk0miya
Copy link
Member

tk0miya commented Feb 15, 2021

Now I merged the fix. And I'll take a look at other reports for 3.5.0 from now on. So please wait a moment.
Thank you for reporting.

@tk0miya tk0miya closed this as completed Feb 15, 2021
@heitorPB
Copy link
Author

Thanks for fixing it!
Have a nice week

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants