Skip to content

MAINT: Fix issue in StataReader due to upstream changes #35427

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
Aug 6, 2020

Conversation

bashtage
Copy link
Contributor

Avoid creating an array of dtypes to workaround NumPy future change

closes #35426

@bashtage bashtage force-pushed the fix-stata-array-struct branch from adb2604 to 4f6159b Compare July 27, 2020 10:58
@simonjayhawkins simonjayhawkins added CI Continuous Integration Compat pandas objects compatability with Numpy or Python functions IO Stata read_stata, to_stata labels Jul 27, 2020
@simonjayhawkins simonjayhawkins added this to the 1.1 milestone Jul 27, 2020
Copy link
Member

@simonjayhawkins simonjayhawkins left a comment

Choose a reason for hiding this comment

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

Thanks @bashtage

@bashtage bashtage force-pushed the fix-stata-array-struct branch from 109dfb6 to 8141742 Compare July 27, 2020 15:00
@TomAugspurger
Copy link
Contributor

Probably no reason to do this for 1.1.0. Are you OK with waiting for 1.1.1 @simonjayhawkins?

@simonjayhawkins
Copy link
Member

Probably no reason to do this for 1.1.0. Are you OK with waiting for 1.1.1 @simonjayhawkins?

no problem.

@simonjayhawkins simonjayhawkins modified the milestones: 1.1, 1.1.1 Jul 27, 2020
@bashtage bashtage force-pushed the fix-stata-array-struct branch from 8141742 to f004de6 Compare July 27, 2020 17:18
@@ -108,7 +108,7 @@ def test_ewma_halflife_without_times(halflife_with_times):
@pytest.mark.parametrize("min_periods", [0, 2])
def test_ewma_with_times_equal_spacing(halflife_with_times, times, min_periods):
halflife = halflife_with_times
data = np.arange(10)
data = np.arange(10.)
Copy link
Member

Choose a reason for hiding this comment

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

IIUC you can revert this and just keep this PR scoped to the Stata change. see #35426 (comment)

@simonjayhawkins
Copy link
Member

moving milestone. The Stata tests are no longer failing with Linux py37_np_dev on master so this won't need backport.

@simonjayhawkins simonjayhawkins modified the milestones: 1.1.1, 1.2 Jul 29, 2020
@simonjayhawkins simonjayhawkins added Refactor Internal refactoring of code and removed CI Continuous Integration Compat pandas objects compatability with Numpy or Python functions labels Jul 29, 2020
@bashtage
Copy link
Contributor Author

bashtage commented Jul 29, 2020 via email

@simonjayhawkins
Copy link
Member

The second fix does appear to be needed or at least a good idea since assigning Nan to an int array has a funny smell.

Thanks. I'm not sure where we are with numpy-dev. We still have 20 fails on master. not sure whether further changes in numpy will resolve these or we still have work to do.

Should we just close this as unneeded?

up to you.

@bashtage
Copy link
Contributor Author

@simonjayhawkins I reverted the second commit so this just a small, sensible always safe refactor.

@bashtage bashtage requested a review from simonjayhawkins July 30, 2020 14:07
Copy link
Member

@simonjayhawkins simonjayhawkins left a comment

Choose a reason for hiding this comment

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

Thanks @bashtage

Avoid creating an array of dtypes to workaround NumPy future change

closes pandas-dev#35426
@bashtage bashtage force-pushed the fix-stata-array-struct branch from 51ef825 to abac7c9 Compare August 2, 2020 23:26
@jbrockmendel
Copy link
Member

Restarted the Travis build, LGTM pending green

@bashtage
Copy link
Contributor Author

bashtage commented Aug 5, 2020

@jbrockmendel green.

@simonjayhawkins simonjayhawkins merged commit b827fe2 into pandas-dev:master Aug 6, 2020
@simonjayhawkins
Copy link
Member

Thanks @bashtage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
IO Stata read_stata, to_stata Refactor Internal refactoring of code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CI/COMPAT: read_stata failing in numpy dev pipeline
4 participants