Skip to content

Remove the numpy restrictions and fix issues with coverage/coveralls#443

Merged
jtgrasb merged 5 commits into
sandialabs:devfrom
jtgrasb:no-numpy-restrictions
Nov 19, 2025
Merged

Remove the numpy restrictions and fix issues with coverage/coveralls#443
jtgrasb merged 5 commits into
sandialabs:devfrom
jtgrasb:no-numpy-restrictions

Conversation

@jtgrasb

@jtgrasb jtgrasb commented Oct 31, 2025

Copy link
Copy Markdown
Collaborator

Description

This PR removes the numpy restrictions (see #391) which were a result of autograd being outdated. Since we switched to jax, this update is relatively straightforward but did require switching np.NaN to np.nan in the AH example.

This PR also address coverage issues that we've been having. By reverting back to coverage instead of pytest-cov, the coverage data will actually be uploaded to coveralls (instead of displaying as 0%). I also added

[tool.coverage.run]
source = [
    "wecopttool",
]

to pyproject.toml, which specifies only coverage for files in the source directory should be recorded. This fixes an error with the ubuntu tests trying to find some _netcdf4.pyx file.

Type of PR

  • Bug fix
  • New feature
  • Documentation
  • Other: (specify)

Checklist for PR

@coveralls

coveralls commented Oct 31, 2025

Copy link
Copy Markdown

Pull Request Test Coverage Report for Build 19516522764

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+87.9%) to 87.938%

Totals Coverage Status
Change from base Build 18696515447: 87.9%
Covered Lines: 1254
Relevant Lines: 1426

💛 - Coveralls

@jtgrasb jtgrasb mentioned this pull request Nov 12, 2025
12 tasks
@jtgrasb

jtgrasb commented Nov 19, 2025

Copy link
Copy Markdown
Collaborator Author

I also contacted coveralls support regarding the issue with the line-by-line source code not showing up in coveralls. This was occurring because we did not have a "repo owner" set. Now that the repo owner is set, the line-by-line coverage is available.

@jtgrasb jtgrasb merged commit 81bf65e into sandialabs:dev Nov 19, 2025
9 of 10 checks passed
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.

2 participants