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

Add get_defaults method to allow sub-class to customize parameter loading #138

Merged
merged 1 commit into from
Nov 23, 2024

Conversation

hdoupe
Copy link
Collaborator

@hdoupe hdoupe commented Jul 26, 2024

@jdebacker , let me know if this works for you. You can override the get_defaults class in taxcalc.Parameters and change this value in the JSON to use the new last year value.

https://github.com/PSLmodels/Tax-Calculator/blob/b41af537803488b6ac40beb0a0e0a7e81cfb6dbd/taxcalc/policy_current_law.json#L9

@hdoupe
Copy link
Collaborator Author

hdoupe commented Sep 10, 2024

@jdebacker you mind if I merge this?

@jdebacker
Copy link
Member

@hdoupe No problem with you merging this, but I had been working off of this branch and was unable to use this how I wanted. That's surely my problem, but I might want to follow up with you for a little more guidance.

But if this PR is ready, can you bump the version and we'll make a new release with this functionality?

@jdebacker
Copy link
Member

Can you confirm that this change is fully backwards compatible? It seemed to work find in Tax-Calculator, but I wanted to be sure more broadly.

@hdoupe If this PR is ready to go, let me know and I will merge it.

I was able to use these changes to do what I needed in Tax-Calculator with respect to extending the range of years in the default parameters JSON file.

@jdebacker jdebacker merged commit d68b28a into master Nov 23, 2024
4 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