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

Yukon Pension Income Amount #405

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 3 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
1 change: 1 addition & 0 deletions changelog_entry.yaml
sqw0418 marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

sqw0418 marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Yukon provides this maximum pension income amount.
values:
2022-01-01: 2_000
metadata:
unit: currency-CAD
label: Yukon pension income max amount
reference:
- title: Maximum Pension Amount
sqw0418 marked this conversation as resolved.
Show resolved Hide resolved
href: https://www.canada.ca/content/dam/cra-arc/formspubs/pbg/5011-c/5011-c-22e.pdf
sqw0418 marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@
members: [c1, c2]
province_code: QC
output:
qc_sa_married_both_eligible: 1
qc_sa_married_both_eligible: 1
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@
members: [c1, c2]
province_code: QC
output:
qc_sa_married_one_eligible: 1
qc_sa_married_one_eligible: 1
sqw0418 marked this conversation as resolved.
Show resolved Hide resolved
sqw0418 marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
- name: Below Maximum Pension Amount
period: 2022
input:
province_code: YT
pension_and_savings_plan_income: 10_000
output:
yt_pension_amount: 2_000

- name: Above Maximum Pension Amount
period: 2022
input:
province_code: YT
pension_and_savings_plan_income: 0
output:
yt_pension_amount: 0

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


class yt_pension_amount(Variable):
value_type = float
entity = Person
label = "Yukon Pension Amount"
definition_period = YEAR
defined_for = ProvinceCode.YT

def formula(person, period, parameters):
p = parameters(
period
).gov.provinces.yt.tax.income.pension_income

pension_and_savings_income = person(
"pension_and_savings_plan_income", period
)

max_values = p.amount
sqw0418 marked this conversation as resolved.
Show resolved Hide resolved

return min_(max_values, pension_and_savings_income)
sqw0418 marked this conversation as resolved.
Show resolved Hide resolved
Loading