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

Python 3 Support #504

Closed
aneeshusa opened this issue Sep 7, 2016 · 24 comments
Closed

Python 3 Support #504

aneeshusa opened this issue Sep 7, 2016 · 24 comments

Comments

@aneeshusa
Copy link

Does NixOps support Python 3? I couldn't tell from setup.py or the issues, but it looks like it's Python 2 only right now. (I'm waiting for #502 so I can try nixops out.)

I think this would be nice to go along with NixOS/nixpkgs#18185.

@domenkozar
Copy link
Member

It doesn't support it yet.

@aske
Copy link
Member

aske commented Oct 18, 2016

I can try migrating NixOps to python3 (looks like we'll need to use boto3 library; need to check libraries used for non-AWS backends before that, though).

@aske
Copy link
Member

aske commented Oct 19, 2016

I'll make the PR to explicitly set python 2 version so we can move further with moving to python3 by default a bit later.

Alright, the rough roadmap right now looks like this:

  1. Migrate to boto3
  2. Upgrade/move to other libs for non-AWS backends
  3. Migrate tests to nose2 (or py.test?)
  4. Do the actual 2->3 migration

@aske
Copy link
Member

aske commented Oct 19, 2016

Also, cc @edolstra @rbvermaa I guess, in case they have any comments.

@domenkozar
Copy link
Member

@aske the plan sounds good. I'd keep nose2 for having a small scope for this somewhat big task.

@domenkozar
Copy link
Member

Boto3 migration guide: http://boto3.readthedocs.io/en/latest/guide/migration.html

@aske
Copy link
Member

aske commented Nov 29, 2016

I hope I'll be able to start working on migrating to boto3 this or next weekend (was a bit swamped with work).

@bachp
Copy link
Member

bachp commented Feb 7, 2017

I don't think nixops needs to support python2 along side python3. I assume it is mostly installed vis nixpkgs which already has python3 and it can easily be switched there.

Please correct me if I'm wrong.

@edolstra
Copy link
Member

Yeah, I don't think there's any reason to keep supporting Python 2.

@teto
Copy link
Member

teto commented Sep 25, 2017

Any news on the python3 front ? is there a PR one can follow/help with ?

@domenkozar
Copy link
Member

First we need to migrate to boto3 as per checklist from @aske.

@aske
Copy link
Member

aske commented Oct 19, 2017

Hm, hackathon at NixCon looks like the perfect opportunity to finally start working on this.

@domenkozar
Copy link
Member

Small boto3 progress: #749

@davidak
Copy link
Member

davidak commented Feb 18, 2019

The clock is ticking...

@takeda
Copy link

takeda commented Jul 24, 2019

So I pulled the trigger and made somewhat large changes in moving everything to boto3 the dependency is still there, but hopefully there's not much left. The changes I did though require testing, so if anyone could find issues and show the command and backtrace, that might help me fix them.

#1186

I also added typing information to the functions/methods that I touched so hopefully it will also help migrating to python 3 and find bugs in the code.

@takeda
Copy link

takeda commented Sep 14, 2019

I moved my commits into a new nixops-aws repo: NixOS/nixops-aws#1 since my old PR is no longer valid after dividing nixops into modules.

@asymmetric
Copy link
Contributor

asymmetric commented Sep 16, 2019

Should we close this then?


EDIT It seems there are some changes needed on nixops itself, so this shouldn't be closed yet, sorry.

@davidak
Copy link
Member

davidak commented Sep 16, 2019

Should we close this then?

This issue is not yet solved, so no!

Python 2.7 will not be maintained past 2020.

https://pythonclock.org/

So, to make this tool usable and maintainable past next year, we need to migrate it! We have 3 months and 15 days left...

@takeda
Copy link

takeda commented Sep 16, 2019

@asymmetric this patch doesn't make nixops python 3 complaint, it targets the dependence on boto which is python 2 only (and no longer supported AFAIK). The changes mentioned in that old PR was splitting nixops into modules so I redone my PR to just target nixops-aws.

@davidak with how things are moving I don't think we will make it in 3 months :) but it's not like python2.7 suddenly will stop from working, although new versions of packages will start breaking as maintainers will stop caring about 2.7.

@grahamc
Copy link
Member

grahamc commented Apr 20, 2020

NixOps is now python3 only.

@grahamc grahamc closed this as completed Apr 20, 2020
@jonringer
Copy link

jonringer commented Aug 17, 2020

it would be nice to expose the python3 version in nixpkgs, seeing as I would like to stop fixing python2 packages to ensure nixopsUnstable still builds with the python2 package set. NixOS/nixpkgs#95609 (comment)

plus it would be nice for the 20.09 release to not have a version based on an EOL python interpreter

@nixos-discourse
Copy link

This issue has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/new-nixos-org-design/9080/33

@dotlambda
Copy link
Member

Are there any plans to make the Python 3 versions of NixOps the default for 21.05?

@mweinelt
Copy link
Member

Or for 21.11?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests