Skip to content

Move away from virtualenv #625

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

Closed
showell opened this issue Sep 23, 2020 · 10 comments · Fixed by #646
Closed

Move away from virtualenv #625

showell opened this issue Sep 23, 2020 · 10 comments · Fixed by #646

Comments

@showell
Copy link
Contributor

showell commented Sep 23, 2020

Since python3.5, the recommended methodology for creating virtual environments is to use the native venv module.

Now that we no longer support older versions of python, we no longer need virtualenv.

More discussion here: https://chat.zulip.org/#narrow/stream/2-general/topic/page.20not.20found/near/1022651

@QEDK
Copy link
Collaborator

QEDK commented Oct 1, 2020

I'll just add a note that while venv works fine on native Linux distributions, Microsoft's WSL and Windows itself work quite badly with it. I'm not quite sure why to be honest but venv itself is plagued with permissions errors (on WSL atleast). While it's surely something upstream, just my two cents.

@LoopThrough-i-j
Copy link
Contributor

LoopThrough-i-j commented Jan 21, 2021

I hope this issue is open to work @showell. Can you please add some labels that would allow me to claim the issue.

@LoopThrough-i-j
Copy link
Contributor

@zulipbot claim

@zulipbot
Copy link
Member

Hello @LoopThrough-i-j!

Thanks for your interest in Zulip! You have attempted to claim an issue without the labels "help wanted", "good first issue". Since you're a new contributor, you can only claim and submit pull requests for issues with the help wanted or good first issue labels.

If this is your first time here, we recommend reading our guide for new contributors before getting started.

@LoopThrough-i-j
Copy link
Contributor

LoopThrough-i-j commented Jan 23, 2021

I'll just add a note that while venv works fine on native Linux distributions, Microsoft's WSL and Windows itself work quite badly with it. I'm not quite sure why to be honest but venv itself is plagued with permissions errors (on WSL atleast). While it's surely something upstream, just my two cents.

@QEDK, @showell and @neiljp I tested venv on WSL and everything felt nice and smooth. Not sure of the issue @QEDK is talking about. I insatlled windows to test everything out. Probably @QEDK made some irregular sudo usage that could have broken venv(I am not sure though).

@QEDK
Copy link
Collaborator

QEDK commented Jan 23, 2021

I'll just add a note that while venv works fine on native Linux distributions, Microsoft's WSL and Windows itself work quite badly with it. I'm not quite sure why to be honest but venv itself is plagued with permissions errors (on WSL atleast). While it's surely something upstream, just my two cents.

@QEDK, @showell and @neiljp I tested venv on WSL and everything felt nice and smooth. Not sure of the issue @QEDK is talking about. I insatlled windows to test everything out. Probably @QEDK made some irregular sudo usage that could have broken venv(I am not sure though).

You missed what I said on Zulip, it needs to be the Windows filesystem inside WSL. I know to not use sudo, the way file systems are implemented are what's the problem, which even causes problems with Git.

@LoopThrough-i-j
Copy link
Contributor

LoopThrough-i-j commented Jan 23, 2021

@QEDK yeah, I understand and am trying things out. I wrote this comment before checking for the chat, sorry for that.
btw I tested out with the windows file system as well in different drives. We can continue our chat at chat.zulip.org.

@QEDK
Copy link
Collaborator

QEDK commented Jan 23, 2021 via email

@zulipbot
Copy link
Member

zulipbot commented Feb 7, 2021

Hello @LoopThrough-i-j, you claimed this issue to work on it, but this issue and any referenced pull requests haven't been updated for 10 days. Are you still working on this issue?

If so, please update this issue by leaving a comment on this issue to let me know that you're still working on it. Otherwise, I'll automatically remove you from this issue in 4 days.

If you've decided to work on something else, simply comment @zulipbot abandon so that someone else can claim it and continue from where you left off.

Thank you for your valuable contributions to Zulip!

@LoopThrough-i-j
Copy link
Contributor

@rht would you mind taking a look at the PR

LoopThrough-i-j pushed a commit to LoopThrough-i-j/python-zulip-api that referenced this issue Feb 8, 2021
LoopThrough-i-j added a commit to LoopThrough-i-j/python-zulip-api that referenced this issue Feb 8, 2021
LoopThrough-i-j added a commit to LoopThrough-i-j/python-zulip-api that referenced this issue Feb 23, 2021
LoopThrough-i-j added a commit to LoopThrough-i-j/python-zulip-api that referenced this issue Feb 25, 2021
LoopThrough-i-j added a commit to LoopThrough-i-j/python-zulip-api that referenced this issue Feb 25, 2021
Fixes zulip#625
Changes:
- Replace virtualenv, to python native venv. The venv used is native to
  python3 and need not be shipped separately on any OS other than
  Ubuntu/Debian.
- Remove redundant activation script. An activation script is required
  to use the pip and python in the virtual environment, but in case
  the path to the pip is mentioned, pip takes care of installing the
  packages in the environment where pip is located.
timabbott pushed a commit that referenced this issue Feb 25, 2021
- Replace virtualenv with python 3's native venv feature. The venv used is native to
  python3.5+, so there's no need for a separate dependency.
- Remove redundant activation script. An activation script is required
  to use the pip and python in the virtual environment, but because we're
  calling the pip inside the venv, we don't need one.

Fixes #625.
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

Successfully merging a pull request may close this issue.

4 participants