According to the documentation, Scenario.timeseries() is supposed to filter results with various fields (or indices), but applying the year field gives an error and doesn't work as intended.
Code sample or context
import ixmp
import message_ix
mp_ENE = ixmp.Platform("ixmp_dev")
sc = message_ix.Scenario(mp_ENE, model= "xxx", scenario="yyy")
# This works fine, and the result includes values for 1990 onwards.
ts_chn=sc.timeseries(region="R12_CHN")
# Both below give an error.
ts_chn=sc.timeseries(region="R12_CHN", year=1990)
ts_chn=sc.timeseries(region="R12_CHN", year="1990")
Expected result
To give a data frame with the filtered result
Problem description
File "C:\ProgramData\Anaconda3\envs\local_mix\lib\site-packages\ixmp\core\timeseries.py", line 372, in timeseries
df = pd.DataFrame(
File "C:\ProgramData\Anaconda3\envs\local_mix\lib\site-packages\pandas\core\frame.py", line 710, in __init__
data = list(data)
File "C:\ProgramData\Anaconda3\envs\local_mix\lib\site-packages\ixmp\backend\jdbc.py", line 734, in get_data
for row in self.jindex[ts].getTimeseries(r, v, u, None, y):
java.lang.ClassCastException: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Number
According to the documentation,
Scenario.timeseries()
is supposed to filter results with various fields (or indices), but applying the year field gives an error and doesn't work as intended.Code sample or context
Expected result
To give a data frame with the filtered result
Problem description
Versions