chore(ci): from Rye to uv (#476)

* chore(ci): from Rye to uv

uv is just better for what I need to do, and Rye will eventually be replaced by uv anyway

* chore(ci): add tests' extra

* chore(ci): oops

* fix(ci): some tests

* chore(ci): remove -W error

Because it breaks on the CI, but not locally..
This commit is contained in:
Jérome Eertmans
2024-09-24 17:15:18 +02:00
committed by GitHub
parent 6ad89ecdf6
commit de91ac7b7c
15 changed files with 3591 additions and 927 deletions

View File

@ -18,18 +18,13 @@ jobs:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Setup Rye - name: Setup uv
env: uses: astral-sh/setup-uv@v2
RYE_INSTALL_OPTION: --yes with:
run: | enable-cache: true
curl -sSf https://rye.astral.sh/get | bash
echo "$HOME/.rye/shims" >> $GITHUB_PATH
- name: Configure Rye
run: rye config --set-bool behavior.use-uv=true
- name: Build package - name: Build package
run: rye build run: uv build
- name: Publish to PyPI - name: Publish to PyPI
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')

View File

@ -69,29 +69,13 @@ jobs:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Setup Rye - name: Setup uv
if: matrix.os != 'windows-latest' uses: astral-sh/setup-uv@v2
env: with:
RYE_TOOLCHAIN_VERSION: ${{ matrix.pyversion}} enable-cache: true
RYE_INSTALL_OPTION: --yes
run: |
curl -sSf https://rye.astral.sh/get | bash
echo "$HOME/.rye/shims" >> $GITHUB_PATH
# Stolen from https://github.com/bluss/pyproject-local-kernel/blob/2b641290694adc998fb6bceea58d3737523a68b7/.github/workflows/ci.yaml - name: Setup Python ${{ matrix.pyversion }}
- name: Install Rye (Windows) run: uv python install ${{ matrix.pyversion }}
if: matrix.os == 'windows-latest'
shell: bash
run: |
C:/msys64/usr/bin/wget.exe -q 'https://github.com/astral-sh/rye/releases/latest/download/rye-x86_64-windows.exe' -O rye-x86_64-windows.exe
./rye-x86_64-windows.exe self install --toolchain-version ${{ matrix.pyversion }} --modify-path -y
echo "$HOME\\.rye\\shims" >> $GITHUB_PATH
- name: Configure Rye
shell: bash
run: |
rye config --set-bool behavior.use-uv=true
rye pin ${{ matrix.pyversion }}
- name: Install manim dependencies on MacOS - name: Install manim dependencies on MacOS
if: matrix.os == 'macos-latest' if: matrix.os == 'macos-latest'
@ -113,12 +97,10 @@ jobs:
uses: ssciwr/setup-mesa-dist-win@v2 uses: ssciwr/setup-mesa-dist-win@v2
- name: Install Manim Slides - name: Install Manim Slides
shell: bash run: uv sync --locked --extra tests
run: rye sync
- name: Run pytest - name: Run pytest
shell: bash run: uv run pytest
run: rye run pytest
- name: Upload to codecov.io - name: Upload to codecov.io
uses: codecov/codecov-action@v4 uses: codecov/codecov-action@v4

3
.gitignore vendored
View File

@ -4,7 +4,6 @@ __pycache__/
/build /build
/dist /dist
*.egg-info/ *.egg-info/
.pdm-python
# Manim files # Manim files
images/ images/
@ -45,7 +44,7 @@ paper/paper.pdf
paper/media/ paper/media/
# Others # Others
.coverage .coverage*
coverage.xml coverage.xml
rendering_times.csv rendering_times.csv

View File

@ -20,10 +20,6 @@ repos:
- id: pretty-format-toml - id: pretty-format-toml
exclude: poetry.lock exclude: poetry.lock
args: [--autofix, --trailing-commas] args: [--autofix, --trailing-commas]
- repo: https://github.com/keewis/blackdoc
rev: v0.3.9
hooks:
- id: blackdoc
- repo: https://github.com/astral-sh/ruff-pre-commit - repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.6.7 rev: v0.6.7
hooks: hooks:

View File

@ -46,6 +46,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
[#467](https://github.com/jeertmans/manim-slides/pull/467) [#467](https://github.com/jeertmans/manim-slides/pull/467)
- Documented potential fix for PPTX issue. - Documented potential fix for PPTX issue.
[#475](https://github.com/jeertmans/manim-slides/pull/475) [#475](https://github.com/jeertmans/manim-slides/pull/475)
- Changed project manager from Rye to uv.
[#476](https://github.com/jeertmans/manim-slides/pull/476)
(unreleased-fixed)= (unreleased-fixed)=
### Fixed ### Fixed

View File

@ -24,25 +24,30 @@ the repository, and clone it locally.
As for every Python project, using virtual environment is recommended to avoid As for every Python project, using virtual environment is recommended to avoid
conflicts between modules. conflicts between modules.
For this project, we use [Rye](https://rye.astral.sh/) to easily manage project For this project, we use [uv](https://github.com/astral-sh/uv) to easily manage project
and development dependencies. If not already, please install this tool. and development dependencies. If not already, please install this tool.
## Installing Python modules ## Installing Python modules
With Rye, installation becomes straightforward: With uv, installation becomes straightforward:
```bash ```bash
rye sync --all-features uv sync --all-extras
``` ```
:::{note}
You still need the same dependencies as to install Manim and ManimGL,
so please check their respective installation guides.
:::
## Running commands ## Running commands
Because modules are installed in a new Python environment, Because modules are installed in a new Python environment,
you cannot use them directly in the shell. you cannot use them directly in the shell.
Instead, you either need to prepend `rye run` to any command, e.g.: Instead, you either need to prepend `uv run` to any command, e.g.:
```bash ```bash
rye run manim-slides wizard uv run manim-slides wizard
``` ```
## Testing your code ## Testing your code
@ -51,7 +56,7 @@ Most of the tests are done with GitHub actions, thus not on your computer.
The only command you should run locally is: The only command you should run locally is:
```bash ```bash
rye run pre-commit run --all-files uv run pre-commit run --all-files
``` ```
This runs a few linter and formatter to make sure the code quality and style stay This runs a few linter and formatter to make sure the code quality and style stay
@ -61,7 +66,7 @@ If a warning or an error is displayed, please fix it before going to next step.
For testing your code, simply run: For testing your code, simply run:
```bash ```bash
rye run pytest uv run pytest
``` ```
## Building the documentation ## Building the documentation
@ -73,7 +78,7 @@ To generate the documentation, run the following:
```bash ```bash
cd docs cd docs
rye run make html uv run make html
``` ```
Then, the output index file is located at `docs/build/html/index.html` and Then, the output index file is located at `docs/build/html/index.html` and

View File

@ -313,7 +313,7 @@ class PresentationConfig(BaseModel): # type: ignore[misc]
use_cached: bool = True, use_cached: bool = True,
include_reversed: bool = True, include_reversed: bool = True,
prefix: str = "", prefix: str = "",
) -> "PresentationConfig": ) -> None:
"""Copy the files to a given directory.""" """Copy the files to a given directory."""
for slide_config in self.slides: for slide_config in self.slides:
file = slide_config.file file = slide_config.file
@ -322,13 +322,8 @@ class PresentationConfig(BaseModel): # type: ignore[misc]
dest = folder / f"{prefix}{file.name}" dest = folder / f"{prefix}{file.name}"
rev_dest = folder / f"{prefix}{rev_file.name}" rev_dest = folder / f"{prefix}{rev_file.name}"
slide_config.file = dest
slide_config.rev_file = rev_dest
if not use_cached or not dest.exists(): if not use_cached or not dest.exists():
shutil.copy(file, dest) shutil.copy(file, dest)
if include_reversed and (not use_cached or not rev_dest.exists()): if include_reversed and (not use_cached or not rev_dest.exists()):
shutil.copy(rev_file, rev_dest) shutil.copy(rev_file, rev_dest)
return self

View File

@ -65,6 +65,7 @@ pyside6 = ["pyside6>=6.6.1"]
pyside6-full = ["manim-slides[full,pyside6]"] pyside6-full = ["manim-slides[full,pyside6]"]
sphinx-directive = ["docutils>=0.20.1", "manim-slides[manim]"] sphinx-directive = ["docutils>=0.20.1", "manim-slides[manim]"]
tests = [ tests = [
"manim-slides[full,manimgl,pyqt6,pyside6,sphinx-directive]",
"pytest>=7.4.0", "pytest>=7.4.0",
"pytest-cov>=4.1.0", "pytest-cov>=4.1.0",
"pytest-env>=0.8.2", "pytest-env>=0.8.2",
@ -136,7 +137,7 @@ search = "<!-- start changelog -->"
builtin = "clear,rare,informal,usage,names,en-GB_to_en-US" builtin = "clear,rare,informal,usage,names,en-GB_to_en-US"
check-hidden = true check-hidden = true
ignore-words-list = "master" ignore-words-list = "master"
skip = "requirements.lock,requirements-dev.lock" skip = "uv.lock"
[tool.coverage.report] [tool.coverage.report]
exclude_lines = [ exclude_lines = [
@ -185,11 +186,10 @@ env = [
"QT_QPA_PLATFORM=offscreen", "QT_QPA_PLATFORM=offscreen",
] ]
filterwarnings = [ filterwarnings = [
"error",
'''ignore:'audioop' is deprecated:DeprecationWarning''', '''ignore:'audioop' is deprecated:DeprecationWarning''',
'ignore:pkg_resources is deprecated as an API:DeprecationWarning', 'ignore:pkg_resources is deprecated as an API:DeprecationWarning',
'ignore::DeprecationWarning:pkg_resources.*:', 'ignore::DeprecationWarning:pkg_resources.*:',
'ignore::SyntaxWarning:pydub.*:', 'ignore::DeprecationWarning:pydub.*:',
] ]
[tool.ruff] [tool.ruff]
@ -220,15 +220,12 @@ isort = {known-first-party = ["manim_slides", "tests"]}
"docs/source/reference/magic_example.ipynb" = ["F403", "F405"] "docs/source/reference/magic_example.ipynb" = ["F403", "F405"]
"tests/test_slide.py" = ["N801"] "tests/test_slide.py" = ["N801"]
[tool.rye] [tool.uv]
dev-dependencies = [ dev-dependencies = [
"bump-my-version>=0.20.3", "bump-my-version>=0.20.3",
"pre-commit>=3.5.0", "pre-commit>=3.5.0",
"setuptools>=73.0.1", "setuptools>=73.0.1",
] ]
managed = true
[tool.uv]
override-dependencies = [ override-dependencies = [
# Bypass constraints from ManimGL # Bypass constraints from ManimGL
"manimpango>=0.5.0,<1.0.0", "manimpango>=0.5.0,<1.0.0",

View File

@ -1,447 +0,0 @@
# generated by rye
# use `rye lock` or `rye sync` to update this lockfile
#
# last locked with the following flags:
# pre: false
# features: []
# all-features: true
# with-sources: false
# generate-hashes: false
# universal: false
-e file:.
alabaster==1.0.0
# via sphinx
annotated-types==0.7.0
# via pydantic
asttokens==2.4.1
# via stack-data
attrs==24.2.0
# via jsonschema
# via referencing
av==12.3.0
# via manim-slides
babel==2.16.0
# via sphinx
beautifulsoup4==4.12.3
# via furo
# via nbconvert
bleach==6.1.0
# via nbconvert
bracex==2.5
# via wcmatch
bump-my-version==0.26.0
certifi==2024.7.4
# via requests
cfgv==3.4.0
# via pre-commit
charset-normalizer==3.3.2
# via requests
click==8.1.7
# via bump-my-version
# via click-default-group
# via cloup
# via manim
# via manim-slides
# via rich-click
# via sphinx-click
click-default-group==1.2.4
# via manim-slides
cloup==3.0.5
# via manim
colour==0.1.5
# via manimgl
comm==0.2.2
# via ipykernel
contourpy==1.3.0
# via matplotlib
coverage==7.6.1
# via pytest-cov
cycler==0.12.1
# via matplotlib
debugpy==1.8.5
# via ipykernel
decorator==5.1.1
# via ipython
# via manim
defusedxml==0.7.1
# via nbconvert
distlib==0.3.8
# via virtualenv
docutils==0.21.2
# via manim-slides
# via myst-parser
# via nbsphinx
# via sphinx
# via sphinx-click
executing==2.0.1
# via stack-data
fastjsonschema==2.20.0
# via nbformat
filelock==3.15.4
# via virtualenv
fonttools==4.53.1
# via matplotlib
furo==2024.8.6
# via manim-slides
glcontext==3.0.0
# via moderngl
identify==2.6.0
# via pre-commit
idna==3.8
# via requests
imagesize==1.4.1
# via sphinx
iniconfig==2.0.0
# via pytest
ipykernel==6.29.5
# via manim-slides
ipython==8.26.0
# via ipykernel
# via manim-slides
# via manimgl
isosurfaces==0.1.2
# via manim
# via manimgl
jedi==0.19.1
# via ipython
jinja2==3.1.4
# via manim-slides
# via myst-parser
# via nbconvert
# via nbsphinx
# via sphinx
jsonschema==4.23.0
# via nbformat
jsonschema-specifications==2023.12.1
# via jsonschema
jupyter-client==8.6.2
# via ipykernel
# via nbclient
jupyter-core==5.7.2
# via ipykernel
# via jupyter-client
# via nbclient
# via nbconvert
# via nbformat
jupyterlab-pygments==0.3.0
# via nbconvert
kiwisolver==1.4.5
# via matplotlib
lxml==5.3.0
# via manim-slides
# via python-pptx
manim==0.18.1
# via manim-slides
manimgl==1.6.1
# via manim-slides
manimpango==0.5.0
# via --override (workspace)
# via manim
# via manimgl
mapbox-earcut==1.0.2
# via manim
# via manimgl
markdown-it-py==3.0.0
# via mdit-py-plugins
# via myst-parser
# via rich
markupsafe==2.1.5
# via jinja2
# via nbconvert
matplotlib==3.9.2
# via manimgl
matplotlib-inline==0.1.7
# via ipykernel
# via ipython
mdit-py-plugins==0.4.1
# via myst-parser
mdurl==0.1.2
# via markdown-it-py
mistune==3.0.2
# via nbconvert
moderngl==5.11.1
# via manim
# via manimgl
# via moderngl-window
moderngl-window==2.4.6
# via manim
# via manimgl
mpmath==1.3.0
# via sympy
multipledispatch==1.0.0
# via pyrr
myst-parser==4.0.0
# via manim-slides
nbclient==0.10.0
# via nbconvert
nbconvert==7.16.4
# via nbsphinx
nbformat==5.10.4
# via nbclient
# via nbconvert
# via nbsphinx
nbsphinx==0.9.5
# via manim-slides
nest-asyncio==1.6.0
# via ipykernel
networkx==3.3
# via manim
nodeenv==1.9.1
# via pre-commit
numpy==1.24.0
# via --override (workspace)
# via contourpy
# via isosurfaces
# via manim
# via manim-slides
# via manimgl
# via mapbox-earcut
# via matplotlib
# via moderngl-window
# via pyrr
# via scipy
packaging==24.1
# via ipykernel
# via matplotlib
# via nbconvert
# via pytest
# via qtpy
# via sphinx
pandoc==2.4
# via manim-slides
pandocfilters==1.5.1
# via nbconvert
parso==0.8.4
# via jedi
pexpect==4.9.0
# via ipython
pillow==10.4.0
# via manim
# via manim-slides
# via manimgl
# via matplotlib
# via moderngl-window
# via python-pptx
platformdirs==4.2.2
# via jupyter-core
# via virtualenv
pluggy==1.5.0
# via pytest
# via pytest-qt
plumbum==1.8.3
# via pandoc
ply==3.11
# via pandoc
pre-commit==3.8.0
prompt-toolkit==3.0.47
# via ipython
# via questionary
psutil==6.0.0
# via ipykernel
ptyprocess==0.7.0
# via pexpect
pure-eval==0.2.3
# via stack-data
pycairo==1.26.1
# via manim
pydantic==2.8.2
# via bump-my-version
# via manim-slides
# via pydantic-extra-types
# via pydantic-settings
pydantic-core==2.20.1
# via pydantic
pydantic-extra-types==2.9.0
# via manim-slides
pydantic-settings==2.4.0
# via bump-my-version
pydub==0.25.1
# via manim
# via manimgl
pyglet==2.0.17
# via moderngl-window
pygments==2.18.0
# via furo
# via ipython
# via manim
# via manimgl
# via nbconvert
# via rich
# via sphinx
pyopengl==3.1.7
# via manimgl
pyparsing==3.1.4
# via matplotlib
pyqt6==6.7.1
# via manim-slides
pyqt6-qt6==6.7.2
# via pyqt6
pyqt6-sip==13.8.0
# via pyqt6
pyrr==0.10.3
# via moderngl-window
pyside6==6.7.2
# via manim-slides
pyside6-addons==6.7.2
# via pyside6
pyside6-essentials==6.7.2
# via pyside6
# via pyside6-addons
pytest==8.3.2
# via manim-slides
# via pytest-cov
# via pytest-env
# via pytest-missing-modules
# via pytest-qt
pytest-cov==5.0.0
# via manim-slides
pytest-env==1.1.3
# via manim-slides
pytest-missing-modules==0.1.0
# via manim-slides
pytest-qt==4.4.0
# via manim-slides
python-dateutil==2.9.0.post0
# via jupyter-client
# via matplotlib
python-dotenv==1.0.1
# via pydantic-settings
python-pptx==1.0.2
# via manim-slides
pyyaml==6.0.2
# via manimgl
# via myst-parser
# via pre-commit
pyzmq==26.2.0
# via ipykernel
# via jupyter-client
qtpy==2.4.1
# via manim-slides
questionary==1.10.0
# via bump-my-version
referencing==0.35.1
# via jsonschema
# via jsonschema-specifications
requests==2.32.3
# via manim-slides
# via sphinx
rich==13.7.1
# via bump-my-version
# via manim
# via manim-slides
# via manimgl
# via rich-click
rich-click==1.8.3
# via bump-my-version
rpds-py==0.20.0
# via jsonschema
# via referencing
rtoml==0.11.0
# via manim-slides
scipy==1.14.1
# via manim
# via manimgl
screeninfo==0.8.1
# via manim
# via manimgl
setuptools==73.0.1
shiboken6==6.7.2
# via pyside6
# via pyside6-addons
# via pyside6-essentials
six==1.16.0
# via asttokens
# via bleach
# via python-dateutil
skia-pathops==0.8.0.post1
# via manim
# via manimgl
snowballstemmer==2.2.0
# via sphinx
soupsieve==2.6
# via beautifulsoup4
sphinx==8.0.2
# via furo
# via manim-slides
# via myst-parser
# via nbsphinx
# via sphinx-basic-ng
# via sphinx-click
# via sphinx-copybutton
# via sphinxext-opengraph
sphinx-basic-ng==1.0.0b2
# via furo
sphinx-click==6.0.0
# via manim-slides
sphinx-copybutton==0.5.2
# via manim-slides
sphinxcontrib-applehelp==2.0.0
# via sphinx
sphinxcontrib-devhelp==2.0.0
# via sphinx
sphinxcontrib-htmlhelp==2.1.0
# via sphinx
sphinxcontrib-jsmath==1.0.1
# via sphinx
sphinxcontrib-qthelp==2.0.0
# via sphinx
sphinxcontrib-serializinghtml==2.0.0
# via sphinx
sphinxext-opengraph==0.9.1
# via manim-slides
srt==3.5.3
# via manim
stack-data==0.6.3
# via ipython
svgelements==1.9.6
# via manim
# via manimgl
sympy==1.13.2
# via manimgl
tinycss2==1.3.0
# via nbconvert
tomlkit==0.13.2
# via bump-my-version
tornado==6.4.1
# via ipykernel
# via jupyter-client
tqdm==4.66.5
# via manim
# via manim-slides
# via manimgl
traitlets==5.14.3
# via comm
# via ipykernel
# via ipython
# via jupyter-client
# via jupyter-core
# via matplotlib-inline
# via nbclient
# via nbconvert
# via nbformat
# via nbsphinx
typing-extensions==4.12.2
# via ipython
# via manim
# via pydantic
# via pydantic-core
# via python-pptx
# via rich-click
urllib3==2.2.2
# via requests
validators==0.33.0
# via manimgl
virtualenv==20.26.3
# via pre-commit
watchdog==4.0.2
# via manim
wcmatch==9.0
# via bump-my-version
wcwidth==0.2.13
# via prompt-toolkit
webencodings==0.5.1
# via bleach
# via tinycss2
xlsxwriter==3.2.0
# via python-pptx

View File

@ -1,408 +0,0 @@
# generated by rye
# use `rye lock` or `rye sync` to update this lockfile
#
# last locked with the following flags:
# pre: false
# features: []
# all-features: true
# with-sources: false
# generate-hashes: false
# universal: false
-e file:.
alabaster==1.0.0
# via sphinx
annotated-types==0.7.0
# via pydantic
asttokens==2.4.1
# via stack-data
attrs==24.2.0
# via jsonschema
# via referencing
av==12.3.0
# via manim-slides
babel==2.16.0
# via sphinx
beautifulsoup4==4.12.3
# via furo
# via nbconvert
bleach==6.1.0
# via nbconvert
certifi==2024.7.4
# via requests
charset-normalizer==3.3.2
# via requests
click==8.1.7
# via click-default-group
# via cloup
# via manim
# via manim-slides
# via sphinx-click
click-default-group==1.2.4
# via manim-slides
cloup==3.0.5
# via manim
colour==0.1.5
# via manimgl
comm==0.2.2
# via ipykernel
contourpy==1.3.0
# via matplotlib
coverage==7.6.1
# via pytest-cov
cycler==0.12.1
# via matplotlib
debugpy==1.8.5
# via ipykernel
decorator==5.1.1
# via ipython
# via manim
defusedxml==0.7.1
# via nbconvert
docutils==0.21.2
# via manim-slides
# via myst-parser
# via nbsphinx
# via sphinx
# via sphinx-click
executing==2.0.1
# via stack-data
fastjsonschema==2.20.0
# via nbformat
fonttools==4.53.1
# via matplotlib
furo==2024.8.6
# via manim-slides
glcontext==3.0.0
# via moderngl
idna==3.8
# via requests
imagesize==1.4.1
# via sphinx
iniconfig==2.0.0
# via pytest
ipykernel==6.29.5
# via manim-slides
ipython==8.26.0
# via ipykernel
# via manim-slides
# via manimgl
isosurfaces==0.1.2
# via manim
# via manimgl
jedi==0.19.1
# via ipython
jinja2==3.1.4
# via manim-slides
# via myst-parser
# via nbconvert
# via nbsphinx
# via sphinx
jsonschema==4.23.0
# via nbformat
jsonschema-specifications==2023.12.1
# via jsonschema
jupyter-client==8.6.2
# via ipykernel
# via nbclient
jupyter-core==5.7.2
# via ipykernel
# via jupyter-client
# via nbclient
# via nbconvert
# via nbformat
jupyterlab-pygments==0.3.0
# via nbconvert
kiwisolver==1.4.5
# via matplotlib
lxml==5.3.0
# via manim-slides
# via python-pptx
manim==0.18.1
# via manim-slides
manimgl==1.6.1
# via manim-slides
manimpango==0.5.0
# via --override (workspace)
# via manim
# via manimgl
mapbox-earcut==1.0.2
# via manim
# via manimgl
markdown-it-py==3.0.0
# via mdit-py-plugins
# via myst-parser
# via rich
markupsafe==2.1.5
# via jinja2
# via nbconvert
matplotlib==3.9.2
# via manimgl
matplotlib-inline==0.1.7
# via ipykernel
# via ipython
mdit-py-plugins==0.4.1
# via myst-parser
mdurl==0.1.2
# via markdown-it-py
mistune==3.0.2
# via nbconvert
moderngl==5.11.1
# via manim
# via manimgl
# via moderngl-window
moderngl-window==2.4.6
# via manim
# via manimgl
mpmath==1.3.0
# via sympy
multipledispatch==1.0.0
# via pyrr
myst-parser==4.0.0
# via manim-slides
nbclient==0.10.0
# via nbconvert
nbconvert==7.16.4
# via nbsphinx
nbformat==5.10.4
# via nbclient
# via nbconvert
# via nbsphinx
nbsphinx==0.9.5
# via manim-slides
nest-asyncio==1.6.0
# via ipykernel
networkx==3.3
# via manim
numpy==1.24.0
# via --override (workspace)
# via contourpy
# via isosurfaces
# via manim
# via manim-slides
# via manimgl
# via mapbox-earcut
# via matplotlib
# via moderngl-window
# via pyrr
# via scipy
packaging==24.1
# via ipykernel
# via matplotlib
# via nbconvert
# via pytest
# via qtpy
# via sphinx
pandoc==2.4
# via manim-slides
pandocfilters==1.5.1
# via nbconvert
parso==0.8.4
# via jedi
pexpect==4.9.0
# via ipython
pillow==10.4.0
# via manim
# via manim-slides
# via manimgl
# via matplotlib
# via moderngl-window
# via python-pptx
platformdirs==4.2.2
# via jupyter-core
pluggy==1.5.0
# via pytest
# via pytest-qt
plumbum==1.8.3
# via pandoc
ply==3.11
# via pandoc
prompt-toolkit==3.0.47
# via ipython
psutil==6.0.0
# via ipykernel
ptyprocess==0.7.0
# via pexpect
pure-eval==0.2.3
# via stack-data
pycairo==1.26.1
# via manim
pydantic==2.8.2
# via manim-slides
# via pydantic-extra-types
pydantic-core==2.20.1
# via pydantic
pydantic-extra-types==2.9.0
# via manim-slides
pydub==0.25.1
# via manim
# via manimgl
pyglet==2.0.17
# via moderngl-window
pygments==2.18.0
# via furo
# via ipython
# via manim
# via manimgl
# via nbconvert
# via rich
# via sphinx
pyopengl==3.1.7
# via manimgl
pyparsing==3.1.4
# via matplotlib
pyqt6==6.7.1
# via manim-slides
pyqt6-qt6==6.7.2
# via pyqt6
pyqt6-sip==13.8.0
# via pyqt6
pyrr==0.10.3
# via moderngl-window
pyside6==6.7.2
# via manim-slides
pyside6-addons==6.7.2
# via pyside6
pyside6-essentials==6.7.2
# via pyside6
# via pyside6-addons
pytest==8.3.2
# via manim-slides
# via pytest-cov
# via pytest-env
# via pytest-missing-modules
# via pytest-qt
pytest-cov==5.0.0
# via manim-slides
pytest-env==1.1.3
# via manim-slides
pytest-missing-modules==0.1.0
# via manim-slides
pytest-qt==4.4.0
# via manim-slides
python-dateutil==2.9.0.post0
# via jupyter-client
# via matplotlib
python-pptx==1.0.2
# via manim-slides
pyyaml==6.0.2
# via manimgl
# via myst-parser
pyzmq==26.2.0
# via ipykernel
# via jupyter-client
qtpy==2.4.1
# via manim-slides
referencing==0.35.1
# via jsonschema
# via jsonschema-specifications
requests==2.32.3
# via manim-slides
# via sphinx
rich==13.7.1
# via manim
# via manim-slides
# via manimgl
rpds-py==0.20.0
# via jsonschema
# via referencing
rtoml==0.11.0
# via manim-slides
scipy==1.14.1
# via manim
# via manimgl
screeninfo==0.8.1
# via manim
# via manimgl
shiboken6==6.7.2
# via pyside6
# via pyside6-addons
# via pyside6-essentials
six==1.16.0
# via asttokens
# via bleach
# via python-dateutil
skia-pathops==0.8.0.post1
# via manim
# via manimgl
snowballstemmer==2.2.0
# via sphinx
soupsieve==2.6
# via beautifulsoup4
sphinx==8.0.2
# via furo
# via manim-slides
# via myst-parser
# via nbsphinx
# via sphinx-basic-ng
# via sphinx-click
# via sphinx-copybutton
# via sphinxext-opengraph
sphinx-basic-ng==1.0.0b2
# via furo
sphinx-click==6.0.0
# via manim-slides
sphinx-copybutton==0.5.2
# via manim-slides
sphinxcontrib-applehelp==2.0.0
# via sphinx
sphinxcontrib-devhelp==2.0.0
# via sphinx
sphinxcontrib-htmlhelp==2.1.0
# via sphinx
sphinxcontrib-jsmath==1.0.1
# via sphinx
sphinxcontrib-qthelp==2.0.0
# via sphinx
sphinxcontrib-serializinghtml==2.0.0
# via sphinx
sphinxext-opengraph==0.9.1
# via manim-slides
srt==3.5.3
# via manim
stack-data==0.6.3
# via ipython
svgelements==1.9.6
# via manim
# via manimgl
sympy==1.13.2
# via manimgl
tinycss2==1.3.0
# via nbconvert
tornado==6.4.1
# via ipykernel
# via jupyter-client
tqdm==4.66.5
# via manim
# via manim-slides
# via manimgl
traitlets==5.14.3
# via comm
# via ipykernel
# via ipython
# via jupyter-client
# via jupyter-core
# via matplotlib-inline
# via nbclient
# via nbconvert
# via nbformat
# via nbsphinx
typing-extensions==4.12.2
# via ipython
# via manim
# via pydantic
# via pydantic-core
# via python-pptx
urllib3==2.2.2
# via requests
validators==0.33.0
# via manimgl
watchdog==4.0.2
# via manim
wcwidth==0.2.13
# via prompt-toolkit
webencodings==0.5.1
# via bleach
# via tinycss2
xlsxwriter==3.2.0
# via python-pptx

View File

@ -1,5 +1,5 @@
#! /bin/bash #! /bin/bash
rye run manim-slides render -t -qk -s --format png --resolution 64,64 static/logo.py ManimSlidesFavicon && mv media/images/logo/*.png static/favicon.png uv run manim-slides render -t -qk -s --format png --resolution 64,64 static/logo.py ManimSlidesFavicon && mv media/images/logo/*.png static/favicon.png
ln -f -r -s static/favicon.png docs/source/_static/favicon.png ln -f -r -s static/favicon.png docs/source/_static/favicon.png

View File

@ -1,21 +1,21 @@
#! /bin/bash #! /bin/bash
MANIM_SLIDES_THEME=light rye run manim-slides render -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo.png MANIM_SLIDES_THEME=light uv run manim-slides render -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo.png
ln -f -r -s static/logo.png docs/source/_static/logo.png ln -f -r -s static/logo.png docs/source/_static/logo.png
MANIM_SLIDES_THEME=dark_docs rye run manim-slides render -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_dark_docs.png MANIM_SLIDES_THEME=dark_docs uv run manim-slides render -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_dark_docs.png
ln -f -r -s static/logo_dark_docs.png docs/source/_static/logo_dark_docs.png ln -f -r -s static/logo_dark_docs.png docs/source/_static/logo_dark_docs.png
MANIM_SLIDES_THEME=dark_github rye run manim-slides render -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_dark_github.png MANIM_SLIDES_THEME=dark_github uv run manim-slides render -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_dark_github.png
ln -f -r -s static/logo_dark_github.png docs/source/_static/logo_dark_github.png ln -f -r -s static/logo_dark_github.png docs/source/_static/logo_dark_github.png
MANIM_SLIDES_THEME=light rye run manim-slides render -t -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_light_transparent.png MANIM_SLIDES_THEME=light uv run manim-slides render -t -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_light_transparent.png
ln -f -r -s static/logo_light_transparent.png docs/source/_static/logo_light_transparent.png ln -f -r -s static/logo_light_transparent.png docs/source/_static/logo_light_transparent.png
MANIM_SLIDES_THEME=dark_docs rye run manim-slides render -t -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_dark_transparent.png MANIM_SLIDES_THEME=dark_docs uv run manim-slides render -t -qk -s --format png --resolution 2560,1280 static/logo.py ManimSlidesLogo && mv media/images/logo/*.png static/logo_dark_transparent.png
ln -f -r -s static/logo_dark_transparent.png docs/source/_static/logo_dark_transparent.png ln -f -r -s static/logo_dark_transparent.png docs/source/_static/logo_dark_transparent.png

View File

@ -71,7 +71,7 @@ def paths() -> Generator[list[Path], None, None]:
yield [random_path() for _ in range(20)] yield [random_path() for _ in range(20)]
@pytest.fixture(scope="session") @pytest.fixture
def presentation_config( def presentation_config(
slides_folder: Path, slides_folder: Path,
) -> Generator[PresentationConfig, None, None]: ) -> Generator[PresentationConfig, None, None]:

View File

@ -166,12 +166,15 @@ class TestConverter:
HtmlZip(presentation_configs=[presentation_config]).convert_to(archive) HtmlZip(presentation_configs=[presentation_config]).convert_to(archive)
RevealJS(presentation_configs=[presentation_config]).convert_to(expected) RevealJS(presentation_configs=[presentation_config]).convert_to(expected)
shutil.unpack_archive(str(archive)) shutil.unpack_archive(str(archive), extract_dir=tmp_path)
assert archive.exists()
assert got.exists() assert got.exists()
assert expected.exists() assert expected.exists()
assert got.read_text() == expected.read_text() assert got.read_text() == expected.read_text().replace(
"expected_assets", "got_assets"
)
@pytest.mark.parametrize("num_presentation_configs", (1, 2)) @pytest.mark.parametrize("num_presentation_configs", (1, 2))
def test_revealjs_multiple_scenes_converter( def test_revealjs_multiple_scenes_converter(

3545
uv.lock generated Normal file

File diff suppressed because it is too large Load Diff