Commits

Chris Mutel  committed fbfe3e2

Don't hard code biosphere database name

  • Participants
  • Parent commits 66516d1

Comments (0)

Files changed (2)

File bw2data/io/import_ecospold.py

             return self.link_activity(exc, ds, data, depends, name)
 
     def link_biosphere(self, exc):
-        exc["input"] = ("biosphere", exc["hash"])
-        if (u"biosphere", exc["hash"]) in Database("biosphere").load():
+        exc["input"] = (config.biosphere, exc["hash"])
+        if (config.biosphere, exc["hash"]) in Database(config.biosphere).load():
             return exc
         else:
             new_flow = copy.deepcopy(exc["matching"])

File bw2data/io/import_method.py

 
     def add_cf(self, cf):
         data = self.get_cf_data(cf)
-        if ("biosphere", data["hash"]) not in mapping:
+        if (config.biosphere, data["hash"]) not in mapping:
             self.add_flow(data)
         return (data["hash"], float(cf.get("meanValue")))