Skip to content

Commit

Permalink
Correct git merge of Scenario.__init__
Browse files Browse the repository at this point in the history
  • Loading branch information
khaeru committed Jan 30, 2020
1 parent 6ffae69 commit 6335564
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ixmp/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -586,16 +586,16 @@ def __init__(self, mp, model, scenario, version=None, scheme=None,
warn('Using `ixmp.Scenario` for MESSAGE-scheme scenarios is '
'deprecated, please use `message_ix.Scenario`')

@property
def _cache(self):
return hasattr(self.platform._backend, '_cache')

# Retrieve the Model class correlating to the *scheme*
model_class = get_model(scheme).__class__

# Use the model class to initialize the Scenario
model_class.initialize(self, **model_init_args)

@property
def _cache(self):
return hasattr(self.platform._backend, '_cache')

@classmethod
def from_url(cls, url, errors='warn'):
"""Instantiate a Scenario given an ixmp-scheme URL.
Expand Down

0 comments on commit 6335564

Please sign in to comment.