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

update docstring tests -- numpy-2.0 failures #769

Merged
merged 11 commits into from
Jun 20, 2024

Conversation

jGaboardi
Copy link
Member

@jGaboardi jGaboardi commented Jun 20, 2024

@jGaboardi jGaboardi added the ci label Jun 20, 2024
@jGaboardi jGaboardi self-assigned this Jun 20, 2024
@martinfleis
Copy link
Member

Can we maybe try to fix it rather than disabling failing tests?

@jGaboardi
Copy link
Member Author

@martinfleis

Yes, this was done in haste yesterday evening. I'm on the fence as to:

  1. update the types in docstrings (X.Y vs. np.float64(X.Y)); or
  2. make actual changes in the code base

Very worth noting that none of the actual functional tests fail, only the docstring examples.

@martinfleis
Copy link
Member

make actual changes in the code base

Not worth it imho, just creates unnecessary copies of data.

@jGaboardi jGaboardi changed the title disable docstring test -- numpy-2.0 failures update docstring tests -- numpy-2.0 failures Jun 20, 2024
@jGaboardi
Copy link
Member Author

  • need to try skipping doctest only in the 310-oldest.yaml environment

Copy link

codecov bot commented Jun 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.3%. Comparing base (17a411c) to head (6d03fbb).

Additional details and impacted files

Impacted file tree graph

@@          Coverage Diff          @@
##            main    #769   +/-   ##
=====================================
  Coverage   99.3%   99.3%           
=====================================
  Files          4       4           
  Lines       1133    1133           
=====================================
  Hits        1125    1125           
  Misses         8       8           
Files Coverage Δ
spaghetti/analysis.py 100.0% <100.0%> (ø)
spaghetti/network.py 99.1% <ø> (ø)
spaghetti/util.py 100.0% <ø> (ø)

Copy link
Member

@martinfleis martinfleis left a comment

Choose a reason for hiding this comment

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

This change in numpy 2 is so annoying...



- name: declare doctest run
run: |
Copy link
Member

Choose a reason for hiding this comment

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

I think this is fine but it may be worth adding either as a separate action (as in momepy) or as a separate job (as in geopandas)

Copy link
Member Author

Choose a reason for hiding this comment

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

I'll add that as a To DO issue.

@jGaboardi jGaboardi merged commit e2c54d6 into pysal:main Jun 20, 2024
10 checks passed
@jGaboardi jGaboardi deleted the GH767__numpy_20_compat branch June 20, 2024 19:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fix doctests in CI -- numpy 2.0 current CI failures [2024-06-19]
2 participants