bopen / c3s-eqc-toolbox-template

CADS Toolbox template application
Apache License 2.0
5 stars 4 forks source link

Missing writing privileges in /tmp/cacholote/ #11

Closed paololanteri closed 1 year ago

paololanteri commented 1 year ago

The following error is occurring when importing cads_toolbox package on jupyter notebook run from path: /data/wp4/bin/

Traceback (most recent call last): File "", line 1, in File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cads_toolbox/init.py", line 25, in from . import analysis, catalogue File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cads_toolbox/analysis/init.py", line 8, in from cads_toolbox._inputs_transform import transform_module_inputs File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cads_toolbox/_inputs_transform.py", line 14, in from cads_toolbox.catalogue import Remote File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cads_toolbox/catalogue.py", line 20, in import cacholote File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cacholote/init.py", line 18, in from . import config, extra_encoders, utils File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cacholote/config.py", line 209, in reset() File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cacholote/config.py", line 201, in reset set() File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cacholote/config.py", line 169, in init new_settings.make_cache_dir() File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/cacholote/config.py", line 115, in make_cache_dir fs.mkdirs(urlpath, exist_ok=True) File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/fsspec/spec.py", line 1309, in mkdirs return self.makedirs(path, exist_ok=exist_ok) File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/site-packages/fsspec/implementations/local.py", line 50, in makedirs os.makedirs(path, exist_ok=exist_ok) File "/data/wp4/miniconda3/envs/my_env/lib/python3.9/os.py", line 225, in makedirs mkdir(name, mode) PermissionError: [Errno 13] Permission denied: '/tmp/cacholote/cache_files'

malmans2 commented 1 year ago

Hi @paololanteri, Good catch. We did not set the environment variables for wp users. I just edited the wp4 bashrc, can you try again? (You need to source the bashrc, the easiest thing you can do is to start a new session).

Let me know if it works now!

paololanteri commented 1 year ago

Thank you Mattia, very clear, now it works! I would have another question: should we (eqc evaluators) already be able to download and run the template notebooks from the "notebook" folder inside c3s-eqc-toolbox-template?

malmans2 commented 1 year ago

Yes! Please report any issue. Make sure the environment is up-to-date though, we changed many things in the upstream libraries.