Closed mellamoSimon closed 7 months ago
The test also fails for ECEMF. The problem is the variable emi.vars.wNonEn
, which is declared under the condition you introduced, is also used later on outside of your condition in line 2770: https://github.com/mellamoSimon/remind2/blob/fix-emissions-inconsistency/R/reportEmi.R#L2770
So it crashes with
Error in intersect(emi.vars.wBunkers, emi.vars.wNonEn) :
object 'emi.vars.wNonEn' not found
So you just have to make sure that emi.vars.wNonEn
is defined with reasonable values under any condition. Or you avoid using this variable when creating emi.vars.wBunkers.wNonEn
ok, will do, thank you! For the record: I didn't realize that the mapping tests can be skipped and buildLibrary still is successful when running locally (which is what had happened here)
I ran all the mapping tests manually and they all passed (with warnings of missing variables for some and the gaps in the summation checks, as expected)
:shipit:
This restores a condition designed to enable the reporting of industry emissions from feedstocks with an ad-hoc ex-post fix designed for the Ariadne project. Used when feedstock flows are not available (older remind versions). This PR is NOT intended to fix the inconsistencies in emissions accounting. That will come in this one: https://github.com/pik-piam/remind2/pull/530 .