# to use, copy, modify, and distribute this software is granted under
# terms provided in the LICENSE file distributed with this software.
# to use, copy, modify, and distribute this software is granted under
# terms provided in the LICENSE file distributed with this software.
self.source, relative=self.relative, universe=self.universe)
try:
self.data = yaml.safe_load(open(self.source))
self.source, relative=self.relative, universe=self.universe)
try:
self.data = yaml.safe_load(open(self.source))
except FileNotFoundError:
# it's normal if the file is one which doesn't exist yet
self.data = {}
log_entry = ("File %s is unavailable." % self.source, 6)
except FileNotFoundError:
# it's normal if the file is one which doesn't exist yet
self.data = {}
log_entry = ("File %s is unavailable." % self.source, 6)
- try:
- mudpy.misc.log(*log_entry)
- except NameError:
- # happens when we're not far enough along in the init process
- self.universe.setup_loglines.append(log_entry)
+ try:
+ mudpy.misc.log(*log_entry)
+ except NameError:
+ # happens when we're not far enough along in the init process
+ self.universe.setup_loglines.append(log_entry)
if not hasattr(self.universe, "files"):
self.universe.files = {}
self.universe.files[self.source] = self
if not hasattr(self.universe, "files"):
self.universe.files = {}
self.universe.files[self.source] = self