PardeeCenterDU / IFs-Issues-Tracking

This repository only holds the list of bugs that have been reported for IFs. Anyone may add a bug report, but please look to see if your issue has already been added!
2 stars 0 forks source link

dyadtariffratem not applying assigned values #241

Closed caleb-petry closed 1 year ago

caleb-petry commented 1 year ago

dyadtariffratem is not being applied to tariff rates leading to no change between a bilateral base and a scenario. I first noticed this while comparing results for the AfCFTA scenarios in a 7.96 VB6 install. I initially thought that this was a group-related issue, but this does not appear to be the case.

I was able to replicate it in a SCE where a dyadtariffratem intervention is applied to "Burkina Faso-Uganda-ICT" and no changes appear in the run. SCE included below:

HIGH0000,bilateralsw,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1
CUSTOM,dyadtariffratem,Burkina Faso,176, 6,1,.8,.6,.4,.2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
COMMENT,START

I have not yet tried to replicate in .NET.

caleb-petry commented 1 year ago

Replicated in a 7.96 .NET development version. dyadtariffratem is being read properly and seems to be applied.

While skimming the code, I didn't see anything immediately obvious to reset the value to the saved one between the parameter and the export of the run year's value.

PardeeCenterIFs commented 1 year ago

I found the issue, it was my mistake when implementing the additive parameter, it was overwritting the multiplicative one, but now they're both in place. The fix will be available in version 7.97 and forward. The problem was the same for vb6 and .NET.