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

Add support for Python 3.8 #104

Merged
merged 2 commits into from
Nov 12, 2019
Merged

Add support for Python 3.8 #104

merged 2 commits into from
Nov 12, 2019

Conversation

hugovk
Copy link
Contributor

@hugovk hugovk commented Nov 11, 2019

No description provided.

@hugovk
Copy link
Contributor Author

hugovk commented Nov 11, 2019

One test is failing on Python 3.8:

=================================== FAILURES ===================================
__ test_numeric_chars_contains_all_valid_unicode_numeric_and_digit_characters __
tests/test_unicode_numbers.py:49: in test_numeric_chars_contains_all_valid_unicode_numeric_and_digit_characters
    assert i in set_numeric_hex
E   assert 73664 in {178, 179, 185, 188, 189, 190, ...}

@SethMMorton
Copy link
Owner

I'm surprised that TravisCI supports Python 3.8 already... typically it takes them months to roll out support.

@SethMMorton
Copy link
Owner

Regarding the failing check, this is pretty expected. Each new Python version adds more Unicode support, and natsort ends up having to update its hard-coded list of valid unicode numbers. You can generate the complete list of numbers by executing python38 natsort/unicode_numeric_hex.py and then replace the existing list at the top of the file with the list that is output, then run black on the file to get it formatted.

@hugovk
Copy link
Contributor Author

hugovk commented Nov 11, 2019

Travis was the first (of the CIs I've been checking) to add 3.8, in less than 24 hours!

It took GitHub Actions 21 days, Azure Pipelines 25 days and AppVeyor 26 days.

Thanks, will update the Unicode list when I'm next at a keyboard.

@codecov
Copy link

codecov bot commented Nov 12, 2019

Codecov Report

Merging #104 into master will decrease coverage by 4%.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #104   +/-   ##
=======================================
- Coverage   99.52%   95.52%   -4%     
=======================================
  Files          10       10           
  Lines         425      425           
=======================================
- Hits          423      406   -17     
- Misses          2       19   +17
Impacted Files Coverage Δ
natsort/compat/locale.py 57.14% <0%> (-38.1%) ⬇️
natsort/compat/fastnumbers.py 85.71% <0%> (-14.29%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2dd0fa7...30ae2f4. Read the comment docs.

@hugovk
Copy link
Contributor Author

hugovk commented Nov 12, 2019

Updated!

Python 3.8 passes.

WITH_EXTRAS="fast,icu" is now failing, but it is also now fails on master:

@SethMMorton
Copy link
Owner

Huh... from the message it looks like PyICU is not building. I'll take a look.

@SethMMorton
Copy link
Owner

Looks like PyICU made an update to 2.4 yesterday and compilation started breaking across all platforms. I filed this issue as well (ovalhub/pyicu#116), as our signature seems different from others.

@SethMMorton
Copy link
Owner

I'm going to merge this, because the failure is not related to your change.

@SethMMorton SethMMorton merged commit 546a780 into SethMMorton:master Nov 12, 2019
@hugovk hugovk deleted the add-3.8 branch November 12, 2019 17:42
@dvzrv
Copy link

dvzrv commented Nov 12, 2019

@SethMMorton can you release a new version with this change included? We're currently already in the middle of rebuilds for python3.8 on Arch Linux and I'd like to be able to drop the patch.
Thanks! :)

@SethMMorton
Copy link
Owner

@dvzrv Hmm... I was hoping to wait and release along with the drop of 2.7 support. Though, I suppose now is as good of a time as any to start the long-term-support branch...

@SethMMorton
Copy link
Owner

@dvzrv What's your timeline for wanting a release with this?

@hugovk
Copy link
Contributor Author

hugovk commented Nov 13, 2019

@SethMMorton On some projects, I have Travis CI set up to auto-deploy to PyPI on tags, it makes releasing much easier. (It also auto-deploys to Test PyPI for merges to master.)

Let me know if you'd like something similar. I'd be happy to create a PR and help you set it up. It uses encrypted API tokens for upload: https://pypi.org/help/#apitoken.

@dvzrv
Copy link

dvzrv commented Nov 13, 2019 via email

@SethMMorton
Copy link
Owner

@dvzrv I'll release today

@SethMMorton
Copy link
Owner

@hugovk Thank you for the suggestion. I actually had that set up many years ago but removed it because something went wrong (I don't remember what now). I would feel more comfortable if there were some sort of button I had to press in the CI to actually enact the deployment, because I am always afraid of accidentally releasing something broken.

@SethMMorton
Copy link
Owner

@dvzrv Released

@SethMMorton
Copy link
Owner

@hugovk I'm not opposed to the idea. I'd be interested in seeing the PR.

@hugovk
Copy link
Contributor Author

hugovk commented Nov 14, 2019

Please see PR #106.

@dvzrv
Copy link

dvzrv commented Nov 14, 2019 via email

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.

3 participants