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

Run everything in containers #4948

Closed
xni opened this issue Oct 27, 2018 · 7 comments · Fixed by #10803
Closed

Run everything in containers #4948

xni opened this issue Oct 27, 2018 · 7 comments · Fixed by #10803
Labels
developer experience Anything that improves the experience for Warehouse devs

Comments

@xni
Copy link
Contributor

xni commented Oct 27, 2018

$ make reformat

Create our Python 3.6 virtual environment

rm -rf .state/env
python3.6 -m venv .state/env
make: python3.6: No such file or directory
make: *** [.state/env/pyvenv.cfg] Error 1

@di
Copy link
Member

di commented Oct 27, 2018

At the moment you'll need Python 3.6 installed on your machine to run this command. I'd recommend using pyenv to have multiple Python versions installed.

If you're interested, we might want to look into a way to move this into a Docker container instead, to avoid this issue in the future.

@di di added the developer experience Anything that improves the experience for Warehouse devs label Oct 27, 2018
@xni
Copy link
Contributor Author

xni commented Oct 27, 2018

Yes, it would be great! Same for linting...

@shevelevs
Copy link

@di, I can work on this - should be pretty straightforward

@shevelevs
Copy link

I guess the question is whether you should be able to run stuff (especially build docs) without having to run docker. If that's the case, it makes sense to still preserve venv on the host machine. Or it could be either separate target (IMO messy) or some kind of command line option or environment variable so you can select whether you want host or docker (or just default to docker if py3.6 is not found). Thoughts?

@di
Copy link
Member

di commented Oct 27, 2018

I think it's OK to assume that a Warehouse contributor has Docker installed. However, it's worth noting that Travis currently runs these commands (and the test command) without using a container -- the way it does this is by invoking the bin/tests script directly instead of using the Makefile command, so it is necessary to "preserve" a way to run this without Docker, but it should only be necessary for CI.

@jpurviance
Copy link
Contributor

I am also experiencing issues with this. I am unable to run make lint or make reformat

I manage my interpreters through brew. It recently moved me from 3.6 to 3.7. It would help me and other home-brew users as well if this was in the docker container.

@di di changed the title make reformat fails (I'm using Python 3.7) Run everything in containers May 18, 2020
@di di mentioned this issue Feb 20, 2021
@di
Copy link
Member

di commented Mar 12, 2021

Now that #9083 is merged, the remaining things that aren't running in containers are:

miketheman added a commit to miketheman/warehouse that referenced this issue Nov 21, 2021
Until all `make` targets are built in containers, a new contributor will
stumble on this error and there's nothing in the docs that tell you what
you need.

Refs: pypi#4948

Signed-off-by: Mike Fiedler <miketheman@gmail.com>
di pushed a commit that referenced this issue Nov 21, 2021
Until all `make` targets are built in containers, a new contributor will
stumble on this error and there's nothing in the docs that tell you what
you need.

Refs: #4948

Signed-off-by: Mike Fiedler <miketheman@gmail.com>
@di di closed this as completed in #10803 Feb 23, 2022
domdfcoding pushed a commit to domdfcoding/warehouse that referenced this issue Jun 7, 2022
Until all `make` targets are built in containers, a new contributor will
stumble on this error and there's nothing in the docs that tell you what
you need.

Refs: pypi#4948

Signed-off-by: Mike Fiedler <miketheman@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
developer experience Anything that improves the experience for Warehouse devs
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants