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 Nunavut single status credit #430

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 8 commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions changelog_entry.yaml
Copy link
Collaborator

Choose a reason for hiding this comment

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

need a make format and git pull upstream master

Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
- bump: minor
changes:
changed:
- Nunavut Single Status Credit.
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
description: Nunavut credits this amount under the single status credit.
values:
2022-01-01: 16_000
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
metadata:
unit: currency-CAD
label: Nunavut single status credit amount
reference:
- title: Nunavut Income Tax Act Part I Division B Subvision c 2.16
href: https://www.nunavutlegislation.ca/en/consolidated-law/income-tax-act-consolidation
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
- title: 2022 Form NU428, Nunavut Tax
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5014-c/5014-c-22e.pdf#page=1
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
- name: Person with single status
period: 2023
input:
province_code: NU
is_married: false
output:
nu_single_status_credit: 16_000

- name: Person with married status
period: 2023
input:
province_code: NU
is_married: true
output:
nu_single_status_credit: 0
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
from policyengine_canada.model_api import *


class nu_single_status_credit(Variable):
value_type = float
entity = Person
label = "Nunavut single status credit"
definition_period = YEAR
defined_for = ProvinceCode.NU
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved

def formula(person, period, parameters):
eligible = person("nu_single_status_credit_eligible", period)
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
amount = parameters(
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
period
).gov.provinces.nu.tax.income.credits.single_status_credit.amount
return amount * eligible
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
from policyengine_canada.model_api import *


class nu_single_status_credit_eligible(Variable):
value_type = float
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
entity = Person
label = "Nunavut single status credit eligible"
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
definition_period = YEAR
defined_for = ProvinceCode.NU

def formula(person, period, parameters):
single_status = ~person.household("is_married", period)
no_dependants = person.household("count_dependants", period) == 0
eligible = (single_status & no_dependants)
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved
return eligible
runyao-yin marked this conversation as resolved.
Show resolved Hide resolved