Add support for python 3 and other TC goals

Bug #1800186 reported by Boden R
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
networking-bigswitch
Fix Released
Undecided
Aditya Vaja

Bug Description

As part of bigswitch's opt-in for neutron-lib [1], you also committed to keeping the repo up to date for TC initiatives. In particular supporting python 3, zuul v3 and local tox targets [2].

While [3] adds local targets for pep8 and py27 there is still work to be done by someone on the bigswitch team:
- Python 3 support. Running the UTs with py3 has many failures; the code needs to be update to run for py3. This also includes a tox target for py3 and a py3 UT job for zuul.
- Almost no required projects are declared in requirements.txt.. This file needs to define your requirements rather than assuming another project will install them.
- The lower constraints zuul job and lower-constraints.txt file needs to be define in the repo to ensure the versions are proper.

[1] https://review.openstack.org/#/c/605335/
[2] http://lists.openstack.org/pipermail/openstack-dev/2018-September/135063.html
[3] https://review.openstack.org/#/c/613638/

Changed in networking-bigswitch:
assignee: nobody → Aditya Vaja (wolverine-av)
Revision history for this message
Aditya Vaja (wolverine-av) wrote :

Hey Boden,

I work at Big Switch Networks and would take over the tasks mentioned here. Let me provide some details for the points mentioned above:

- Python 3 support. Running the UTs with py3 has many failures; the code needs to be update to run for py3. This also includes a tox target for py3 and a py3 UT job for zuul.

[Aditya] this is planned for the dev cycle that we have internally, to be finished by end of Nov-beginning of Dec. I hope that timeline works with upstream requirements. If not, please let us know and we can expedite it.

- Almost no required projects are declared in requirements.txt.. This file needs to define your requirements rather than assuming another project will install them.

[Aditya] I'll look into it and update requirements.txt. Thanks for raising this.

- The lower constraints zuul job and lower-constraints.txt file needs to be define in the repo to ensure the versions are proper.

[Aditya] ah, gotcha. I added an upper constraints recently after running into a different issue. I'll add this too.

Apologies, I missed this bug mention in the PR.
Please feel free to add any other requirements that the project might be missing - I would be happy to oblige.

Thanks!
Aditya

Changed in networking-bigswitch:
status: New → In Progress
Revision history for this message
Boden R (boden) wrote :

Thanks for the update.

I've gone through this process with a few other projects so please feel free to reach out to me if any questions crop up.
One thing I will forward warn about is that when moving to python 3 we also had to up the versions of the pylint and related test-requirements in some other projects. This in turn introduced some new lint failures that we had to address. It's not difficult, just busy work.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-bigswitch (master)

Reviewed: https://review.openstack.org/613638
Committed: https://git.openstack.org/cgit/openstack/networking-bigswitch/commit/?id=8c7b6b429a5d2330c56304d3840cbbd1fac62120
Submitter: Zuul
Branch: master

commit 8c7b6b429a5d2330c56304d3840cbbd1fac62120
Author: Boden R <email address hidden>
Date: Fri Oct 26 10:34:59 2018 -0600

    add local tox targets for pep8 and py27

    This patch adds local tox targets for pep8 and python 2.7 as per [1]
    that will install dependencies in editable mode.
    To run them use the pep8-dev and py27-dev targets respectively.

    Py3 support is still needed, but it appears there's lots of work
    to do in this code before it'll run successfully.

    [1] https://etherpad.openstack.org/p/neutron-sibling-setup

    Partial-Bug: 1800186

    Change-Id: If65fb3494ca7453005be1526a5178ff2f581938e

Revision history for this message
Weifan Fu (weifan-fu) wrote :
Changed in networking-bigswitch:
status: In Progress → Fix Released
Revision history for this message
Aditya Vaja (wolverine-av) wrote :

Hey Boden,

Quick question - once we transition the master branch to test on both py2/py3 and then eventually just py3 - is that py3 only job to be applied to other stable branches as well?
I'm guessing not, since existing environments with those branches would be using py2. So it won't be transitioned.

Feel free to redirect me to a mail chain that answers this, because this would be a concern for many third party plugins :)

Thanks!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers