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 wombat COVID rules to OpenFisca #191

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

mermop
Copy link
Contributor

@mermop mermop commented May 1, 2020

No description provided.

asgharkazi and others added 3 commits April 5, 2020 18:33
year. The test fails, but I'm not sure what the desired outcome is meant
to be. At least it doesn't crash anymore!
openfisca_aotearoa/entities.py Outdated Show resolved Hide resolved
openfisca_aotearoa/entities.py Outdated Show resolved Hide resolved
@mermop
Copy link
Contributor Author

mermop commented May 1, 2020

@asgharkazi @sarafalamaki we're keen to do some work around this - could you update the fork to be up-to-date with ServiceInnovationLab:master?

Copy link

@sarafalamaki sarafalamaki left a comment

Choose a reason for hiding this comment

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

Can you fix the issues the linter has picked up please?

@mermop
Copy link
Contributor Author

mermop commented May 1, 2020

I can't make changes to the wombatwombat fork @sarafalamaki :)

decline_in_business_revenue_due_to_covid_19: True
already_applied_for_wage_subsidy: False
output:
covid_19_wage_subsidy__eligibility: True
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Suggested change
covid_19_wage_subsidy__eligibility: True
covid_19_wage_subsidy__eligibility: False

already_applied_for_wage_subsidy: False
output:
covid_19_wage_subsidy__eligibility: True
- name: Sole trader, does not have IRD number, not eligible for wage subsidy
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The tests here don't seem to match the name - have made suggestions on the relevant lines

@@ -0,0 +1,26 @@
- name: Sole trader, eligible for wage subsidy
Copy link
Contributor Author

@mermop mermop May 4, 2020

Choose a reason for hiding this comment

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

These tests are both failing in CI - with the errors:

AssertionError: In test 'Sole trader, does not have IRD number, not eligible for wage subsidy', in file '/root/project/openfisca_aotearoa/tests/social_security/covid_19_wage_subsidy.yaml', covid_19_wage_subsidy__eligibility@2020-6: [0.] differs from 1.0 with an absolute margin [1.] > 0

Copy link
Contributor Author

Choose a reason for hiding this comment

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

As below - some debugging with @JacOng17 reveals that it's because of the missing located_in_NZ parameter. If you make those changes, the tests should pass @asgharkazi @sarafalamaki


roles=[
{
'key': 'business owner',
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Is it a bit strange to have a space in this key?

sole_trader_has_IRD_number: True
sole_trader_has_applicable_licenses: True
qualifications_or_registration_for_trade: True
registered_in_NZ: True
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Suggested change
registered_in_NZ: True
registered_in_NZ: True
located_in_NZ: True

@mermop
Copy link
Contributor Author

mermop commented May 12, 2020

@asgharkazi @sarafalamaki we've made some suggestions that should get the tests passing - can you please have a look at them?

sarafalamaki and others added 2 commits May 12, 2020 12:33
….yaml

Co-authored-by: Merrin Macleod <merrin.macleod@gmail.com>
….yaml

Co-authored-by: Merrin Macleod <merrin.macleod@gmail.com>
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.

None yet

3 participants