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

Deprecate unused variables #671

Merged
merged 7 commits into from
Jan 30, 2017
Merged
Show file tree
Hide file tree
Changes from 2 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
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## 12.0.5

* Minor version change because deprecating unused variables
* Deprecate nbsala
Copy link
Member

Choose a reason for hiding this comment

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

s/deprecate/delete (?)

Copy link
Member

Choose a reason for hiding this comment

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

Jusqu'à maintenant on utilise plutôt deprecate.

Copy link
Member

Choose a reason for hiding this comment

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

Well 👌

Copy link
Member Author

Choose a reason for hiding this comment

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

* Deprecate tva_ent

## 12.0.4

* Change `aige_aine` column from IntCol to AgeCol.
Expand Down
30 changes: 2 additions & 28 deletions openfisca_france/model/revenus/activite/salarie.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,34 +100,6 @@ class ppe_tp_sa(Variable):

# (f1ax, f1bx, f1cx, f1dx, f1qx)

class nbsala(Variable):
column = EnumCol(
enum = Enum([
u"Sans objet",
u"Aucun salarié",
u"1 à 4 salariés",
u"5 à 9 salariés",
u"10 à 19 salariés",
u"20 à 49 salariés",
u"50 à 199 salariés",
u"200 à 499 salariés",
u"500 à 999 salariés",
u"1000 salariés ou plus",
u"Ne sait pas",
])
,
)
entity = Individu
label = u"Nombre de salariés dans l'établissement de l'emploi actuel"



class tva_ent(Variable):
column = BoolCol(default = True)
entity = Individu
label = u"L'entreprise employant le salarié paye de la TVA"



# build_column('code_risque', EnumCol(label = u"Code risque pour les accidents du travail"))
# TODO: Complete label, add enum and relevant default.
Expand All @@ -145,6 +117,7 @@ class exposition_accident(Variable):
entity = Individu
label = u"Exposition au risque pour les accidents du travail"


class exposition_penibilite(Variable):
column = EnumCol(
enum = Enum([
Expand Down Expand Up @@ -279,6 +252,7 @@ class cotisation_sociale_mode_recouvrement(Variable):
entity = Individu
label = u"Mode de recouvrement des cotisations sociales"


class entreprise_est_association_non_lucrative(Variable):
column = BoolCol
entity = Individu
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

setup(
name = 'OpenFisca-France',
version = '12.0.4',
version = '12.0.5',
Copy link
Member

Choose a reason for hiding this comment

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

Isn't it a major change, to remove 2 variables?

@MattiSG any advice?

Copy link
Member

Choose a reason for hiding this comment

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

En théorie, oui.

Copy link
Member Author

Choose a reason for hiding this comment

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

Ce sont des reliquats qui ont été remplacés par d'autres variables sans avoir été supprimées.
C'est plus du nettoyage qu'autre chose.

Copy link
Member

Choose a reason for hiding this comment

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

Dépréciation = changement mineur à minima.
Suppression = changement majeur.

Cf. https://speakerdeck.com/mattisg/git-session-2-strategies?slide=81

author = 'OpenFisca Team',
author_email = 'contact@openfisca.fr',
classifiers = [
Expand Down