You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
deploy notebook --static requires a requirements file it never uses #923
rsconnect deploy notebook --static requires a requirements file (or --force-generate), even though the static bundle contains only the rendered HTML and Connect never builds a Python environment for it.
$ rsconnect deploy notebook --static nb.ipynb
Error: The requirements file 'requirements.txt' does not exist in '.'.
Please create the file or specify a different file with --requirements-file.
To have the requirements file generated using pip freeze, pass --force-generate.
In a directory containing only nb.ipynb, with nbconvert and ipykernel installed in the active Python:
rsconnect deploy notebook --static nb.ipynb # fails as above
rsconnect deploy notebook --static --force-generate nb.ipynb # works
With --force-generate, the deployed bundle contains only nb.html and a manifest.json with appmode: static and no python section. The generated requirements are computed and then discarded.
Cause
deploy_notebook calls resolve_requirements_file(...) and Environment.create_python_environment(...) before branching on static (main.py#L2195-L2202). The static path only needs the environment's interpreter, to run nbconvert locally.
Expected
--static doesn't require or generate a requirements file. It only needs a Python interpreter with nbconvert to render the notebook.
Activity