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

Added python3.10 to tox environment list #1336

Merged

Conversation

matthewhegarty
Copy link
Contributor

@matthewhegarty matthewhegarty commented Oct 8, 2021

Problem

Now that python 3.10 is available, I have added it to the list of supported python releases.

Whilst testing this, I noticed tox failures for >= 3.9 only, because support for pytz was dropped in that release. However, since pytz is still a dependency for Django, I added it to the import list in test.txt, since it is required for test_widgets.py.

Solution

  • Updated files to reference python 3.10.

Acceptance Criteria

Ran full tox run through locally.

@coveralls
Copy link

coveralls commented Oct 8, 2021

Coverage Status

Coverage remained the same at 98.073% when pulling c167156 on matthewhegarty:python-3-10-update into 125c1cf on django-import-export:main.

@matthewhegarty matthewhegarty marked this pull request as draft October 9, 2021 09:31
@manelclos
Copy link
Contributor

Hi @matthewhegarty, looks the tests are not passing due to DeprecationWarning. Also not all tests are run, is this because one test failed?

Would you mind creating your branches in this repository instead of in your fork? I could try some commits to this branch when/if I have spare time :)

Thanks!

@matthewhegarty
Copy link
Contributor Author

Hi Manel, thanks for taking a look. I've marked it as draft because the issue is that the distutils library is deprecated in 3.10 but current Django releases still use it. The solution would be to only run tests if using the Django main branch when python version is 3.10. I haven't got round to fixing that yet.

@matthewhegarty
Copy link
Contributor Author

Have updated the "exclusion" matrix, so now python3.10 will only be used against Django main.

matthewhegarty added a commit to matthewhegarty/django-import-export that referenced this pull request Oct 17, 2021
@matthewhegarty matthewhegarty marked this pull request as ready for review October 17, 2021 16:22
matthewhegarty added a commit to matthewhegarty/django-import-export that referenced this pull request Nov 14, 2021
@matthewhegarty
Copy link
Contributor Author

@manelclos I believe this is ok to be merged now - would you mind checking?

Copy link
Contributor

@manelclos manelclos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@matthewhegarty matthewhegarty marked this pull request as draft November 17, 2021 15:16
@matthewhegarty
Copy link
Contributor Author

Marked as draft until I can successfully test manually on 3.10

@matthewhegarty
Copy link
Contributor Author

matthewhegarty commented Dec 6, 2021

Manually tested on 3.10 (Ubuntu 20.04):

  • ran through a manual import & export
sudo apt-get install python3-dev default-libmysqlclient-dev build-essential
sudo apt-get install python3.10-dev

python3.10 -m venv env
source env/bin/activate
pip install -r requirements/dev.txt
pip install -r requirements/test.txt

./manage.py runserver

@matthewhegarty matthewhegarty self-assigned this Dec 6, 2021
@matthewhegarty matthewhegarty marked this pull request as ready for review December 6, 2021 14:23
@matthewhegarty matthewhegarty merged commit a59bb44 into django-import-export:main Dec 6, 2021
@matthewhegarty matthewhegarty deleted the python-3-10-update branch December 6, 2021 14:23
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 this pull request may close these issues.

None yet

3 participants