diff --git a/catalyst/exchange/utils/exchange_utils.py b/catalyst/exchange/utils/exchange_utils.py index 5c40a26d..658a7002 100644 --- a/catalyst/exchange/utils/exchange_utils.py +++ b/catalyst/exchange/utils/exchange_utils.py @@ -446,12 +446,13 @@ def remove_old_files(algo_name, today, rel_path, environ=None): # run on all files in the folder for f in os.listdir(folder): try: - creation_unix = os.path.getctime(os.path.join(folder, f)) - creation_time = pd.to_datetime(creation_unix, unit='s', ) + file_path = os.path.join(folder, f) + creation_unix = os.path.getctime(file_path) + creation_time = pd.to_datetime(creation_unix, unit='s', utc=True) # if the file is older than 30 days erase it if today - pd.DateOffset(30) > creation_time: - os.unlink(f) + os.unlink(file_path) except OSError: error = 'unable to erase files in {}'.format(folder) diff --git a/docs/source/install.rst b/docs/source/install.rst index 5c24159f..6ef366b5 100644 --- a/docs/source/install.rst +++ b/docs/source/install.rst @@ -89,7 +89,7 @@ Once either Conda or MiniConda has been set up you can install Catalyst: .. code-block:: bash - conda env create -f python2.7-environment.yml + conda env create -f python2.7-environment.yml 4. Activate the environment (which you need to do every time you start a new session to run Catalyst): @@ -132,10 +132,19 @@ with the following steps: conda env remove --name catalyst 2. Create the environment: + + for python 2.7: .. code-block:: bash conda create --name catalyst python=2.7 scipy zlib + + or for python 3.6: + + .. code-block:: bash + + conda create --name catalyst python=3.6 scipy zlib + 3. Activate the environment: