Changeset 955:d98b211d32fa for src/mlx/pirep.py
- Timestamp:
- 05/12/19 07:18:47 (5 years ago)
- Branch:
- python3
- hg-Phase:
- (<MercurialRepository 1 'hg:/home/ivaradi/mlx/hg' '/'>, 'public')
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mlx/pirep.py
r919 r955 2 2 from .util import utf2unicode 3 3 from .flight import Flight 4 from .common import fixUnpickled 4 5 5 6 from . import const … … 114 115 try: 115 116 with open(path, "rb") as f: 116 pirep = pickle.load(f )117 pirep = pickle.load(f, fix_imports = True, encoding = "bytes") 117 118 if "numCrew" not in dir(pirep): 118 119 pirep.numCrew = pirep.bookedFlight.numCrew … … 412 413 413 414 return ([], attrs) 415 416 def __setstate__(self, state): 417 """Set the state from the given unpickled dictionary.""" 418 self.__dict__.update(fixUnpickled(state))
Note:
See TracChangeset
for help on using the changeset viewer.