-
- Downloads
Python 2.7 compatibility
This commit makes the Python code backwards compatible down to Python 2.7. Previously it would only run on Python 3.5 and up. Problems fixed included: - `time.perf_counter()` doesn't exist - all classes need to be new-style - `functools.lru_cache` doesn't exist - only the last argument to a function call can be `*`-expanded - the `nonlocal` keyword doesn't exist - metaclasses are used with a different syntax - `yield from` doesn't exist - `tempdir.TemporaryDirectory` doesn't exist - iterators need a `next()` method
Showing
- boundaries/boundaryhandling.py 1 addition, 1 deletionboundaries/boundaryhandling.py
- cache.py 7 additions, 4 deletionscache.py
- continuous_distribution_measures.py 3 additions, 4 deletionscontinuous_distribution_measures.py
- creationfunctions.py 7 additions, 6 deletionscreationfunctions.py
- cumulants.py 4 additions, 7 deletionscumulants.py
- fieldaccess.py 1 addition, 1 deletionfieldaccess.py
- forcemodels.py 3 additions, 3 deletionsforcemodels.py
- gridvisualization.py 1 addition, 1 deletiongridvisualization.py
- maxwellian_equilibrium.py 1 addition, 1 deletionmaxwellian_equilibrium.py
- methods/abstractlbmethod.py 1 addition, 2 deletionsmethods/abstractlbmethod.py
- methods/conservedquantitycomputation.py 1 addition, 1 deletionmethods/conservedquantitycomputation.py
- methods/creationfunctions.py 5 additions, 6 deletionsmethods/creationfunctions.py
- methods/entropic.py 1 addition, 1 deletionmethods/entropic.py
- methods/momentbasedsimplifications.py 1 addition, 1 deletionmethods/momentbasedsimplifications.py
- moments.py 9 additions, 5 deletionsmoments.py
- serialscenario.py 16 additions, 26 deletionsserialscenario.py
Loading
Please register or sign in to comment