openfisca / openfisca-france-indirect-taxation

French indirect taxation module for OpenFisca
http://www.openfisca.fr/
GNU Affero General Public License v3.0
5 stars 13 forks source link

Fix creation of YearlyVariable #168

Closed benjello closed 5 years ago

benjello commented 5 years ago

When adapting YearlyVariable I had to get rid of 'baseline_variable attribute'. But I clearly need it as this test shows:

openfisca test openfisca_france_indirect_taxation/tests/reforms/rattrapage_diesel.yaml -v"

@sandcha you helped solve problem with YearlyVariable some time ago. Could you help again ;-)

You should use ultimate-migration branch.

Thanks !

benjello commented 5 years ago

cc other python masters @maukoquiroga @Morendil @cbenz @eraviart

bonjourmauko commented 5 years ago

Hello @benjello, I don't understand why you need to get rid of baseline_variable and the error you're encountering.

benjello commented 5 years ago

I had a huge code base where definition_periodwas not defined so I decided to use a class YearlyVariable inheriting from Variable to do the trick. @maukoquiroga : I am sorry I made a mistake. I did not mention the country package when running the test. I do not have an error right now.

sandcha commented 5 years ago

@benjello Do you use this YearlyVariable class in this repository only? Would it help if I updated the yearly variables of this repository to the standard Variable?

benjello commented 5 years ago

No it is ok for now.