openfisca / openfisca-web-api

[DEPRECATED] Web API for OpenFisca
https://www.openfisca.fr/
GNU Affero General Public License v3.0
13 stars 11 forks source link

Fix the condition to detect if the country package has decompositions. #81

Closed fpagnoux closed 7 years ago

fpagnoux commented 7 years ago

Connected to #76.

Due to https://github.com/openfisca/openfisca-core/pull/397, any TaxBenefitSystem has a DEFAULT_DECOMP_FILE attribute.

We cannot use it to figure out whether a TBS has a real decomposition. We can instead check whether DEFAULT_DECOMP_FILE is not None, or if DECOMP_DIR exists.

fpagnoux commented 7 years ago

I don't know much about decompositions, and I'd prefer not to dig too much into it 😄 .

Can someone who use it tell me if this condition seem appropriate ? A decomposition can be a directory or a file, right ?

benjello commented 7 years ago

It is ok for me. I started some work here which I should finish soon if @cbenz gives me a hand ;-)

cbenz commented 7 years ago

This PR is now invalid since https://github.com/openfisca/openfisca-core/pull/450

benjello commented 7 years ago

So should we close this PR @cbenz ?

cbenz commented 7 years ago

No, I must update it to follow openfisca/openfisca-core#450