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

MAINT: sparse: fix init func sig to allow maxprint to be set #20719

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

dschult
Copy link
Contributor

@dschult dschult commented May 16, 2024

arg maxprint in _spbase.__init__() doesn't appear in subclasses so setting maxprint during construction is not possible. See #20490

This PR adds tests of setting maxprint, and tests that the new __str__ format works with maxprint set. Fixes __init__ function signatures to work with maxprint being set.

I set up maxprint to be a keyword-only parameter so it doesn't disrupt the positional parameters for subclasses (in e.g. BSR where number of position-keyword parameters is one more than the other subclasses).

@github-actions github-actions bot added scipy.sparse maintenance Items related to regular maintenance tasks labels May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Items related to regular maintenance tasks scipy.sparse
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant