Content-Length: 433846 | pFad | https://github.com/numpy/numpy/pull/13558#event-2359974599

F1 MAINT: Fix errors seen on new python 3.8 by seberg · Pull Request #13558 · numpy/numpy · GitHub
Skip to content

MAINT: Fix errors seen on new python 3.8 #13558

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

Merged
merged 1 commit into from
May 22, 2019
Merged

Conversation

seberg
Copy link
Member

@seberg seberg commented May 14, 2019

One of this is a small issue exposed by new warnings, the others are
simply adapting our test suit to stricter integer coercion rules
(avoiding float -> int conversions).

The last one is that we assumed pickle protocl 5 would be in 3.8, but
it seems that it did not make the cut.

Closes gh-13412


Marking as draft, since the pickle 5 protocol was approved for inclusion in 3.8, so I am not sure this is correct or python 3.8a3 is just lagging behind there. @pitrou do you know this quickly?

@pitrou
Copy link
Member

pitrou commented May 14, 2019

PEP 574 is accepted but its implementation needs reviewing before it's integrated.

@seberg
Copy link
Member Author

seberg commented May 14, 2019

So we can assume that it will not be in 3.8 and change the test accordingly?

@seberg seberg marked this pull request as ready for review May 14, 2019 20:11
@pitrou
Copy link
Member

pitrou commented May 14, 2019

For now we can assume it but I hope it will be integrated in time for 3.8 beta 1.

@seberg
Copy link
Member Author

seberg commented May 14, 2019

Thanks @pitrou, then I will just remove that for the moment. I do not care about the failure in the alpha release I think, I guess we probably will not officially support 3.8 in 1.17 anyway.

@mattip
Copy link
Member

mattip commented May 14, 2019

According to this mail, pickle 5 is slated for inclusion in 3.8, but it does seem a bit iffy since the first beta is supposed to be May 31.

@juliantaylor juliantaylor added this to the 1.17.0 release milestone May 14, 2019
@pitrou
Copy link
Member

pitrou commented May 19, 2019

By the way, the C sources need re-cythonizing to fix them for Python 3.8:
cython/cython#2938 (comment)

@seberg
Copy link
Member Author

seberg commented May 20, 2019

I do not think we ship any cython generated C-sources for a while now. But we may have checks flying around to ensure that nobody uses too old cython versions?

@pitrou
Copy link
Member

pitrou commented May 20, 2019

numpy/random/mtrand/mtrand.c is in the repo, so it won't be re-generated if you pip install from e.g. git master.

@seberg
Copy link
Member Author

seberg commented May 20, 2019

No, but the file is in .gitignore, so you may have to do a git clean -xdf or similar to make sure cython will regenerate it.

@mattip
Copy link
Member

mattip commented May 20, 2019

We ship the C code in the sdist, so that issue is relevant for our wheels/sdist creation

@pitrou
Copy link
Member

pitrou commented May 20, 2019

@seberg Hmm, it is weird then. Perhaps pip installs its own Cython when building from an external source?

@mattip
Copy link
Member

mattip commented May 21, 2019

This seems like a good cleanup and is ready for merge, if there are no objections. We can handle any further changes and a possible bump of cython version in a future PR.

One of this is a small issue exposed by new warnings, the others are
simply adapting our test suit to stricter integer coercion rules
(avoiding float -> int conversions).

The last one is that we assumed pickle protocol 5 would be in 3.8.
It is not yet included in the alpha releases at least.
It seems not necessary for the numpy test suit to check whether
it is available based on the python version so removing that test.
(Also testing if the pickle5 module works seems unnecessary.)

Closes numpygh-13412
@seberg
Copy link
Member Author

seberg commented May 22, 2019

Since it got lost again here. Eric had pointed out that the commit message was wrong (it said it modified the pickle5 test, not deleted it), I fixed the commit message. I did not feel that xfail is helpful, since it is not directly related to numpy whether or not the test fails.

@mattip mattip merged commit 9b89cfd into numpy:master May 22, 2019
@seberg seberg deleted the py38-compat branch May 22, 2019 16:50
@pitrou
Copy link
Member

pitrou commented May 26, 2019

For the record, I've just merged the PEP 574 PR (python/cpython#7076) so unless something bad happens it will be in 3.8 beta1.

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

Successfully merging this pull request may close these issues.

Pyth 3.8.0a3 DeprecationWarning: an integer is required (got type float)
6 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/numpy/numpy/pull/13558#event-2359974599

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy