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

Manitoba Renters Tax Credit #423

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
- bump: minor
changes:
added:
- Manitoba renters tax credit amount.
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Manitoba provides different tax credits according to different age groups.
values:
2022-01-01: 65
metadata:
unit: year
label: Manitoba tax credit diference with people with different ages
reference:
- title: Manitoba Information Guide Manitoba Credits Form MB479
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5007-tc/5007-tc-22e.pdf # page=3
laviniawo marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Manitoba provides this specific percentage rate to renters tax credit.
values:
2022-01-01: 0.0075
metadata:
unit: currency-CAD
label: Manitoba renters tax credit rate
reference:
- title: Manitoba Information Guide Manitoba Credits Form MB479
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5007-tc/5007-tc-22e.pdf #page=3
laviniawo marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Manitoba provides this basic credit amount for either the head or the spouse having age of older than or equal to 65.
values:
2022-01-01: 825
metadata:
unit: currency-CAD
label: Manitoba basic credit amount of renters tax credit for either the head or the spouse having eligible age
reference:
- title: Manitoba Information Guide Manitoba Credits Form MB479
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5007-tc/5007-tc-22e.pdf #page=3
laviniawo marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Manitoba provides this credit value for renters tax credit calculation.
values:
2022-01-01: 43.75
metadata:
unit: currency-CAD
label: Manitoba credit value of renters tax credit
reference:
- title: Manitoba Information Guide Manitoba Credits Form MB479
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5007-tc/5007-tc-22e.pdf #page=3
laviniawo marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Manitoba provides this maximum value for renters tax credit calculation.
values:
2022-01-01: 300
metadata:
unit: currency-CAD
label: Manitoba maximum value of renters tax credit in calculation
reference:
- title: Manitoba Information Guide Manitoba Credits Form MB479
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5007-tc/5007-tc-22e.pdf #page=3
laviniawo marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Manitoba provides the certain time amount for education property tax credit calculations.
values:
2022-01-01: 365
metadata:
unit: year
label: Manitoba time amount for education property tax credit calculations
reference:
- title: Manitoba Information Guide Manitoba Credits Form MB479
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5007-tc/5007-tc-22e.pdf # page=3
laviniawo marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
from policyengine_canada.model_api import *


class mb_renters_tax_credit(Variable):
value_type = float
entity = Person
label = "Manitoba renters tax credit"
unit = CAD
definition_period = YEAR
defined_for = ProvinceCode.MB

def formula(person, period, parameters):
p = parameters(
period
).gov.provinces.mb.tax.income.credits.renters_tax_credit

age = person("age", period)
age_eligible = age >= p.age_amount

# household net income
net_income = person("adjusted_family_net_income", period)

# rent
rent = person("rent", period)

# education property tax credit
### waiting for issue418 to use this variable
education_property_tax_credit = person(
"mb_education_property_tax_credit_amount", period
)

max_amount_allowed = min_(
p.max_value, net_income * p.applicable_percentage
)

age_eligible_credit = age_eligible * (
(p.base_amount - max_amount_allowed) / p.months_in_year
Copy link
Collaborator

Choose a reason for hiding this comment

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

use mask for dividing by 0

)
max_tax_credit = max_(age_eligible_credit, p.credit_value)

number_of_months_in_rentals = person(
"months_living_in_rentals", period
)

renters_tax_credit_amount = (
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
renters_tax_credit_amount = (
return (

min_(max_tax_credit * number_of_months_in_rentals, rent)
+ education_property_tax_credit
)

return renters_tax_credit_amount
Copy link
Collaborator

Choose a reason for hiding this comment

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

we assume that 12 months have been rented - dont need this condition

Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
from policyengine_canada.model_api import *


class months_living_in_rentals(Variable):
value_type = int
entity = Person
label = "Time Livining in Rentals"
documentation = "Total number of months living in rental places"
definition_period = YEAR