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
I have searched the issues of this repo and believe that this is not a duplicate.
I have searched the documentation and believe that my question is not covered.
Feature Request
Ability to poetry install/pip install -e . on an (empty) folder during docker build.
The Docker image will have all project dependencies preinstalled with the correct versions - but does not yet know anything about the source code of the library - as this will be mounted when the container is started up.
Motivation
I want a new developer to be able to start changing Python-code, without having to know anything about poetry. The only manual step involved should be a docker-compose up. Having to run poetry install every time the container starts up feels repetitive, slow - and unneccesary. Dependencies don't change very often compared to source code.
Problem
poetry install right now seems to be "imperative"/"eager" (initially anyways). I would love if there was some "declarative"/"lazy" alternative, or something that could be done in advance, which would not need to have the source code available.
A key to this is that I'm personally responsible for ensuring that dependencies are available. I'm also using poetry config virtualenvs.create false inside the docker containers.
It is important to me that I don't include the source code itself in the docker image - so that the docker image can be shared without also sharing the source code.
Workflow
JupyterLab (custom prebuilt Docker image)
# JupyterLab: autoreloads allow for changing code and immediately playing around with it# without restarting the IPython kernel.%load_extautoreload%autoreload2# I don't want to have to run poetry install manually for this to work.importmyproject
VSCode (for editing code in shared docker volume)
I want to be able to edit my code here, and have tests rerun automatically. The latest version will immediately/auomatically become available in the JupyterLab container.
Automatic testing/test reporting container
This container will be responsible for automatically rerunning tests whenever files change. The test results will be exposed through an html test reporter and livereload.
The text was updated successfully, but these errors were encountered:
@bergkvist is there any reason that you cannot do a poetry install --no-root during build with pyproject.toml added in order to cache a layer with dependencies (default venv config should be good here, and probably better in most cases) and trigger poetry install on run via an entrypoint perhaps? As long as the poetry.lock or pyproject.toml do not change, the install should be quick and its a good idea since it will cover any include changes etc.
Feature Request
Ability to
poetry install
/pip install -e .
on an (empty) folder during docker build.The Docker image will have all project dependencies preinstalled with the correct versions - but does not yet know anything about the source code of the library - as this will be mounted when the container is started up.
Motivation
I want a new developer to be able to start changing Python-code, without having to know anything about poetry. The only manual step involved should be a
docker-compose up
. Having to runpoetry install
every time the container starts up feels repetitive, slow - and unneccesary. Dependencies don't change very often compared to source code.Problem
poetry install
right now seems to be "imperative"/"eager" (initially anyways). I would love if there was some "declarative"/"lazy" alternative, or something that could be done in advance, which would not need to have the source code available.A key to this is that I'm personally responsible for ensuring that dependencies are available. I'm also using
poetry config virtualenvs.create false
inside the docker containers.It is important to me that I don't include the source code itself in the docker image - so that the docker image can be shared without also sharing the source code.
Workflow
JupyterLab (custom prebuilt Docker image)
VSCode (for editing code in shared docker volume)
I want to be able to edit my code here, and have tests rerun automatically. The latest version will immediately/auomatically become available in the JupyterLab container.
Automatic testing/test reporting container
This container will be responsible for automatically rerunning tests whenever files change. The test results will be exposed through an html test reporter and livereload.
The text was updated successfully, but these errors were encountered: