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

Ipp 5 : Mise à jour de la réduction d'IR pour investissements forestiers #911

Merged
merged 19 commits into from
Mar 27, 2018

Conversation

claireleroy
Copy link
Contributor

Les modifications de cette PR sont comparées à la branche ipp-update-tax-reductions_immobiliers (#910)

  • Évolution du système socio-fiscal.
  • Périodes concernées : à partir du 01/01/2002
  • Zones impactées :
  • openfisca_france/model/prelevements_obligatoires/impot_revenu/reductions_impots.py.
  • openfisca_france/model/prelevements_obligatoires/impot_revenu/variables_reductions_credits.py
  • Détails :
    • Mise à jour des formules (2014-2016) de la réduction d'impôt 'invfor'
    • Correction d'une erreur dans la formule précédente : les reports de dépenses entrent dans le plafonnement de la réduction
    • TODO : une partie de la réduction d'impôt pour investissement forestier devient un crédit d'impôt en 2014 (Brochure Pratique IR revenus 2014, page 36)

Ces changements :

  • Ajoutent une fonctionnalité (par exemple ajout d'une variable).
  • Corrigent ou améliorent un calcul déjà existant.

Copy link
Member

@benjello benjello left a comment

Choose a reason for hiding this comment

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

J'aurais dû le dire plus tôt mais tu peux faire un peu de nettoyage en enlevant les Pet en remplaçant par la feuille de l'arbre vers lequel ce P pointe.
Je vais faire un exemple en commentaire des changements.

@claireleroy claireleroy force-pushed the ipp-update-tax-credit-invfor branch from d02f38a to 39d7f98 Compare February 20, 2018 08:45
@claireleroy claireleroy force-pushed the ipp-update-tax-reductions-immobiliers branch from cadfa45 to 20a01ca Compare February 20, 2018 14:33
@claireleroy claireleroy force-pushed the ipp-update-tax-credit-invfor branch from 39d7f98 to e524eaf Compare February 20, 2018 15:27
@@ -1751,8 +1751,6 @@ class invfor(Variable):
entity = FoyerFiscal
label = u"invfor"
definition_period = YEAR
end = '2013-12-31'
Copy link
Contributor

Choose a reason for hiding this comment

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

Est-ce qu'il est possible d'ajouter une référence pour cette variable ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

cf. PR #909

@@ -1820,7 +1818,7 @@ def formula_2011_01_01(foyer_fiscal, period, parameters):
P = parameters(period).impot_revenu.reductions_impots.invfor

max0 = max_(0, P.ifortra_seuil * (maries_ou_pacses + 1) - f7ul)
max1 = max_(0, max0 - f7uu + f7te + f7uv + f7tf)
max1 = max_(0, max0 - f7uu - f7te - f7uv - f7tf)
return (P.taux * (
Copy link
Contributor

Choose a reason for hiding this comment

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

Il vaut mieux mettre les opérateurs (+ ) en début de ligne qu'en fin de ligne : https://www.python.org/dev/peps/pep-0008/#should-a-line-break-before-or-after-a-binary-operator

@@ -1820,7 +1818,7 @@ def formula_2011_01_01(foyer_fiscal, period, parameters):
P = parameters(period).impot_revenu.reductions_impots.invfor

max0 = max_(0, P.ifortra_seuil * (maries_ou_pacses + 1) - f7ul)
max1 = max_(0, max0 - f7uu + f7te + f7uv + f7tf)
max1 = max_(0, max0 - f7uu - f7te - f7uv - f7tf)
Copy link
Contributor

Choose a reason for hiding this comment

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

max0, max1 sont il assez explicites ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

C'est difficile de faire plus explicite, comme dans d'autres réductions, c'est simplement un moyen de respecter l'ordre d'imputation des dépenses éligibles à la réduction..

@@ -1846,7 +1844,7 @@ def formula_2012_01_01(foyer_fiscal, period, parameters):
P = parameters(period).impot_revenu.reductions_impots.invfor

max0 = max_(0, P.ifortra_seuil * (maries_ou_pacses + 1) - f7ul)
max1 = max_(0, max0 - f7uu + f7te + f7uv + f7tf)
max1 = max_(0, max0 - f7uu - f7te - f7uv - f7tf)
Copy link
Contributor

Choose a reason for hiding this comment

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

max0, max1 sont il assez explicites ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

cf. plus haut

@@ -1876,7 +1874,7 @@ def formula_2013_01_01(foyer_fiscal, period, parameters):
P = parameters(period).impot_revenu.reductions_impots.invfor

max0 = max_(0, P.ifortra_seuil * (maries_ou_pacses + 1) - f7ul)
max1 = max_(0, max0 - f7uu + f7te + f7uv + f7tf)
max1 = max_(0, max0 - f7uu - f7te - f7uv - f7tf)
Copy link
Contributor

Choose a reason for hiding this comment

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

max0, max1, ... sont il assez explicites ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

cf. plus haut

value_type = int
unit = 'currency'
entity = FoyerFiscal
label = u"Investissements forestiers"
Copy link
Contributor

Choose a reason for hiding this comment

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

le label est le même que `f7ti, il y a t'il un moyen d'expliquer simplement la différence entre les deux ?

@@ -2243,7 +2243,7 @@ class f7ui(Variable):
value_type = int
unit = 'currency'
entity = FoyerFiscal
end = '2008-12-31'
# end = '2008-12-31' changes meaning in 2014
Copy link
Contributor

Choose a reason for hiding this comment

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

Est-ce que ça n'aurait pas plus de sens de mettre ce commentaire dans cerfa? Avec une mention de la variable qui est maintenant sur la même case.
Pourquoi avoir commenté le end?

value_type = int
unit = 'currency'
entity = FoyerFiscal
label = u"Investissements forestiers"
Copy link
Contributor

Choose a reason for hiding this comment

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

le label est le même que `f7ti, il y a t'il un moyen d'expliquer simplement la différence entre les deux ?

value_type = int
unit = 'currency'
entity = FoyerFiscal
label = u"Investissements forestiers"
Copy link
Contributor

Choose a reason for hiding this comment

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

le label est le même que `f7ti, il y a t'il un moyen d'expliquer simplement la différence entre les deux ?

value_type = int
unit = 'currency'
entity = FoyerFiscal
label = u"Investissements forestiers"
Copy link
Contributor

Choose a reason for hiding this comment

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

le label est le même que `f7ti, il y a t'il un moyen d'expliquer simplement la différence entre les deux ?

@claireleroy
Copy link
Contributor Author

@fpagnoux C'est normal que tu aies fermé ma PR ?

@fpagnoux
Copy link
Member

Non c'est une erreur.
J'ai supprimé la branche ipp-update-tax-reductions-immobiliers en pensant qu'elle n'était pas utile parce que déjà mergée, et du coup ça a automatiquement fermé la PR.

Si tu as une version locale de ipp-update-tax-reductions-immobiliers, est-ce que tu peux la repousser sur le dépôt ?

@claireleroy
Copy link
Contributor Author

C'est fait normalement

@Anna-Livia Anna-Livia reopened this Mar 21, 2018
value_type = int
unit = 'currency'
entity = FoyerFiscal
label = u"Investissements forestiers : report 2015, hors sinistre, avec adhésion à une association de producteurs
Copy link
Contributor

Choose a reason for hiding this comment

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

Les guillemets ne sont pas fermés :/

@claireleroy claireleroy force-pushed the ipp-update-tax-credit-invfor branch from ea6572a to 32b2597 Compare March 26, 2018 07:38
@claireleroy claireleroy changed the base branch from ipp-update-tax-reductions-immobiliers to master March 26, 2018 15:53
@benjello
Copy link
Member

Bravo @ClaireLeroyIPP !

@benjello benjello deleted the ipp-update-tax-credit-invfor branch March 30, 2018 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants