brightway-lca / brightway2-calc

The calculation engine for the Brightway2 life cycle assessment framework.
BSD 3-Clause "New" or "Revised" License
11 stars 14 forks source link

Prevent multiple ``remap_inventory_dicts`` #77

Closed tfardet closed 8 months ago

tfardet commented 10 months ago

With brightway 2.5, there does not seem to be an easy way to check if the LCA dictionaries have been remapped (other than checking if the keys are integers), this means that on can call

lca.remap_inventory_dicts()

twice and then the 2nd call errors as it tries to remap a remapped dict.

Proposal

Have a remapped property (exposed or internal) so that multiple calls to remap_inventory_dicts have no further effect.

cc @cmutel