Skip to content

Workaround to bug in #4171 - #4393

Merged
embray merged 3 commits into
astropy:masterfrom
embray:analytic_functions/issue-4171
Dec 23, 2015
Merged

embray merged 3 commits into
astropy:masterfrom
embray:analytic_functions/issue-4171

Conversation

@embray

@embray embray commented Dec 11, 2015

Copy link
Copy Markdown
Member

Adds workaround for buggy implementations of expm1--shouldn't slow things down on platforms that don't have this bug, but will add a little overhead otherwise.

This attempts to add a workaround to the issue reported in #4171 rather than outright disable the tests. This puts a workaround in the function implementations so that they still return the correct results (at the cost of a little extra overhead on affected platforms).

This is also a possible alternative to #4275.

@embray

embray commented Dec 11, 2015

Copy link
Copy Markdown
Member Author

Passed on Appveyor \o/

@embray

embray commented Dec 11, 2015

Copy link
Copy Markdown
Member Author

Come to think of it, a simpler fix for this might be to just provide an alternative implementation of expm1 in cases where the built-in one is buggy. I think that should be done as an upstream fix to Numpy though (Numpy does provide its own implementation, but it only uses it if the platform libc doesn't have expm1 at all--it doesn't check for this bug).

@embray embray added the Upstream Action Required Was: Upstream Fix Required label Dec 11, 2015
@mwcraig

mwcraig commented Dec 11, 2015

Copy link
Copy Markdown
Member

FWIW this is no longer an issue in python 3.5/numpy 1.10, though it is in python 2.7/numpy 1.10. Best guess is that it has been fixed on the MSVC side since the compiler changed in 3.5

@embray

embray commented Dec 11, 2015

Copy link
Copy Markdown
Member Author

@mwcraig That's probably right--that the only reason it's fixed for Python 3.5 is the newer MSVC version it was built with.

@embray embray added the Affects-dev PRs and issues that do not impact an existing Astropy release label Dec 11, 2015
@embray embray added this to the v1.1.0 milestone Dec 11, 2015
@embray

embray commented Dec 11, 2015

Copy link
Copy Markdown
Member Author

Milestone set to v1.1.0 right now. @eteq @astrofrog Unless you disagree with merging this for whatever reason. Otherwise the milestone can be changed to v1.1.1, but "Affects-dev" will then have to be changed to "Affects-release" as well.

@eteq eteq modified the milestones: v1.1.1, v1.1.0 Dec 11, 2015
@eteq eteq added Affects-release and removed Affects-dev PRs and issues that do not impact an existing Astropy release labels Dec 11, 2015
@eteq

eteq commented Dec 11, 2015

Copy link
Copy Markdown
Member

Sorry, the gears had already been turning on v1.1 release (which is on PyPI now and will be announced first thing monday), so this will have to go to 1.1.1

@eteq

eteq commented Dec 11, 2015

Copy link
Copy Markdown
Member

Oh, and given that I guess it should get a changelog entry for 1.1.1, @embray (you'll probably need to rebase to do that because the section was just added in master)

@embray

embray commented Dec 11, 2015

Copy link
Copy Markdown
Member Author

That's fine.

@embray
embray force-pushed the analytic_functions/issue-4171 branch from b0919d3 to 2986cb2 Compare December 23, 2015 16:41
embray added a commit that referenced this pull request Dec 23, 2015
@embray
embray merged commit b263235 into astropy:master Dec 23, 2015
@embray
embray deleted the analytic_functions/issue-4171 branch December 23, 2015 16:41
embray added a commit that referenced this pull request Dec 23, 2015
dhomeier pushed a commit to dhomeier/astropy that referenced this pull request Jun 12, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Bug Upstream Action Required Was: Upstream Fix Required zzz 💤 analytic_functions archived: this package no longer exists

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants