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

Workaround for #5310: theano import error with recent NumPy #5316

Merged
merged 1 commit into from
Jan 6, 2022
Merged

Workaround for #5310: theano import error with recent NumPy #5316

merged 1 commit into from
Jan 6, 2022

Conversation

treszkai
Copy link
Contributor

@treszkai treszkai commented Jan 6, 2022

Importing Theano with NumPy>=1.22.0 installed raises an exception as it accesses an undefined variable in NumPy's __config__ module. This PR implements a workaround as suggested in #5310 (comment)

@twiecki twiecki changed the base branch from main to v3 January 6, 2022 17:56
twiecki
twiecki previously approved these changes Jan 6, 2022
@twiecki twiecki requested a review from michaelosthege January 6, 2022 17:57
michaelosthege
michaelosthege previously approved these changes Jan 6, 2022
Copy link
Member

@michaelosthege michaelosthege left a comment

Choose a reason for hiding this comment

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

LGTM

pymc3/__init__.py Outdated Show resolved Hide resolved
@michaelosthege
Copy link
Member

@treszkai did you tick the "allow maintainers to push this branch" checkbox?

I tried to commit a mention in the release notes using the GitHub Web IDE, but it won't let me do it.

Otherwise please append this to the "3.11.5" section in the release notes, and remove that one line 29 in the __init__.py in the same commit..

### Bugfixes
+ A hotfix is applied on import to remain compatible with NumPy 1.22 (see [#5316](https://github.com/pymc-devs/pymc/pull/5316)).

@treszkai treszkai dismissed stale reviews from michaelosthege and twiecki via c352814 January 6, 2022 19:49
@treszkai
Copy link
Contributor Author

treszkai commented Jan 6, 2022

@michaelosthege I only clicked "Allow edits by maintainers" in this PR. Edited the release notes and removed the Aesara comment.

@michaelosthege michaelosthege merged commit 80dae6b into pymc-devs:v3 Jan 6, 2022
@michaelosthege michaelosthege added this to the v3.11.5 (vNext) milestone Jan 6, 2022
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