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

bad install spec for dev environment? #1149

Closed
drammock opened this issue Feb 3, 2023 · 1 comment
Closed

bad install spec for dev environment? #1149

drammock opened this issue Feb 3, 2023 · 1 comment

Comments

@drammock
Copy link
Collaborator

drammock commented Feb 3, 2023

I think it ought to be possible to run our basic dev commands (test, docs, docs-live) in the dev environment we recommend contributors to use (in fact, I would prefer not creating dedicated venvs for them at all / setting --no-venv as the default nox setting, but I don't need to take that hard-line stance here). So I would have expected this to work:

mamba create -n pst python pip
conda activate pst
# cd /path/to/pydata-sphinx-theme
pip install -e .[dev]
nox -s docs --no-venv

actual results Here's the tail end of the output:

preparing documents... done
/opt/miniforge3/envs/pst/lib/python3.11/site-packages/pandas/core/frame.py:docstring of pandas.core.frame.DataFrame.groupby:37: WARNING: undefined label: 'groupby.transform'
sphinx-sitemap: sitemap.xml was generated for URL http://127.0.0.1:8000/ in /opt/pydata-sphinx-theme/docs/_build/html/sitemap.xml

Extension error (pydata_sphinx_theme):
Handler <function update_and_remove_templates at 0x7fb9c9756d40> for event 'html-page-context' threw an exception (exception: ablog/postcard.html)
nox > Command sphinx-build -b=html docs/ docs/_build/html failed with exit code 2
nox > Session docs failed.

nox -s docs-live --no-venv also fails:

$ nox -s docs-live --no-venv
nox > Running session docs-live
nox > Running with `--no-venv` so don't install anything...
nox > Program stb not found.
nox > Session docs-live failed.

Proposal

  1. can we somehow specify --pre only when installing ablog (not for all packages)? Currently in pyproject.toml we say "ablog>=0.11.0rc2" but in fact the environment is ending up with version 0.10.33
    • if not I guess the problem will go away once ablog actually pushes out 0.11
  2. add sphinx-theme-builder[cli] to the [dev] (or [doc]?) group of optional dependencies
    • once I pip install sphinx-theme-builder[cli] into the dev env it still fails, but it's an ablog-version-related failure: jinja2.exceptions.TemplateNotFound: ablog/postcard.html

@choldgraf @12rambau WDYT?

@trallard
Copy link
Collaborator

trallard commented Jul 1, 2024

This should already be fixed by the current tox usage

  • Users can run commands individually (test, docs, lint) or by invoking tox run. By default, lint,compile,py312-docs,py312-tests,a11y-tests will be run within the same environment.
  • We also have separate dev, docs, test, a11y, dependencies groups in our pyproject.toml

so will close this issue at it seems stale

@trallard trallard closed this as completed Jul 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants