ansys/pymapdl-reader

Bug located when installing in editable mode in Windows

germa89 opened this issue · 2 comments

Before submitting the issue

  • I have searched among the existing issues
  • I am using a Python virtual environment

Description of the bug

(emptypymapdl) PS C:\Users\gayuso\Other_Projects\pymapdl-reader> pip install -e .
Obtaining file:///C:/Users/gayuso/Other_Projects/pymapdl-reader
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Requirement already satisfied: pyvista>=0.32.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from ansys-mapdl-reader==0.52.dev0) (0.34.1)
Requirement already satisfied: numpy>=1.16.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from ansys-mapdl-reader==0.52.dev0) (1.22.3)
Requirement already satisfied: matplotlib>=3.0.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from ansys-mapdl-reader==0.52.dev0) (3.5.1)
Requirement already satisfied: tqdm>=4.45.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from ansys-mapdl-reader==0.52.dev0) (4.64.0)
Requirement already satisfied: appdirs>=1.4.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from ansys-mapdl-reader==0.52.dev0) (1.4.4)
Requirement already satisfied: python-dateutil>=2.7 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (2.8.2)
Requirement already satisfied: pyparsing>=2.2.1 in c:\users\gayuso\appdata\roaming\python\python39\site-packages (from matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (3.0.8)
Requirement already satisfied: fonttools>=4.22.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (4.33.3)
Requirement already satisfied: kiwisolver>=1.0.1 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (1.4.2)
Requirement already satisfied: packaging>=20.0 in c:\users\gayuso\appdata\roaming\python\python39\site-packages (from matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (21.3)
Requirement already satisfied: cycler>=0.10 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (0.11.0)
Requirement already satisfied: pillow>=6.2.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (9.1.0)
Requirement already satisfied: six>=1.5 in c:\users\gayuso\appdata\roaming\python\python39\site-packages (from python-dateutil>=2.7->matplotlib>=3.0.0->ansys-mapdl-reader==0.52.dev0) (1.16.0)
Requirement already satisfied: imageio in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (2.18.0)
Requirement already satisfied: scooby>=0.5.1 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (0.5.12)
Requirement already satisfied: vtk in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (9.1.0)
Requirement already satisfied: colorama in c:\users\gayuso\appdata\roaming\python\python39\site-packages (from tqdm>=4.45.0->ansys-mapdl-reader==0.52.dev0) (0.4.4)
Requirement already satisfied: wslink>=1.0.4 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (1.6.1)
Requirement already satisfied: aiohttp in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (3.8.1)
Requirement already satisfied: frozenlist>=1.1.1 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (1.3.0)
Requirement already satisfied: multidict<7.0,>=4.5 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (6.0.2)
Requirement already satisfied: yarl<2.0,>=1.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (1.7.2)
Requirement already satisfied: charset-normalizer<3.0,>=2.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (2.0.12)
Requirement already satisfied: attrs>=17.3.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (21.4.0)
Requirement already satisfied: aiosignal>=1.1.2 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (1.2.0)
Requirement already satisfied: async-timeout<5.0,>=4.0.0a3 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (4.0.2)
Requirement already satisfied: idna>=2.0 in c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages (from yarl<2.0,>=1.0->aiohttp->wslink>=1.0.4->vtk->pyvista>=0.32.0->ansys-mapdl-reader==0.52.dev0) (3.3)
Installing collected packages: ansys-mapdl-reader
  Attempting uninstall: ansys-mapdl-reader
    Found existing installation: ansys-mapdl-reader 0.51.11
    Uninstalling ansys-mapdl-reader-0.51.11:
      Successfully uninstalled ansys-mapdl-reader-0.51.11
  Running setup.py develop for ansys-mapdl-reader
    ERROR: Command errored out with exit status 1:
     command: 'C:\ProgramData\Miniconda3\envs\emptypymapdl\python.exe' -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\gayuso\\Other_Projects\\pymapdl-reader\\setup.py'"'"'; __file__='"'"'C:\\Users\\gayuso\\Other_Projects\\pymapdl-reader\\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps
         cwd: C:\Users\gayuso\Other_Projects\pymapdl-reader\
    Complete output (22 lines):
    running develop
    C:\Users\gayuso\AppData\Local\Temp\pip-build-env-yxf4fm3r\overlay\Lib\site-packages\setuptools\command\easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
      warnings.warn(
    C:\Users\gayuso\AppData\Local\Temp\pip-build-env-yxf4fm3r\overlay\Lib\site-packages\setuptools\command\install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
      warnings.warn(
    running egg_info
    writing ansys_mapdl_reader.egg-info\PKG-INFO
    writing dependency_links to ansys_mapdl_reader.egg-info\dependency_links.txt
    writing requirements to ansys_mapdl_reader.egg-info\requires.txt
    writing top-level names to ansys_mapdl_reader.egg-info\top_level.txt
    reading manifest file 'ansys_mapdl_reader.egg-info\SOURCES.txt'
    reading manifest template 'MANIFEST.in'
    adding license file 'LICENSE'
    writing manifest file 'ansys_mapdl_reader.egg-info\SOURCES.txt'
    running build_ext
    skipping 'ansys/mapdl/reader/cython\_archive.c' Cython extension (up-to-date)
    skipping 'ansys/mapdl/reader/cython\_reader.c' Cython extension (up-to-date)
    skipping 'ansys/mapdl/reader/cython\_relaxmidside.c' Cython extension (up-to-date)
    skipping 'ansys/mapdl/reader/cython\_cellqual.c' Cython extension (up-to-date)
    skipping 'ansys/mapdl/reader/cython\_binary_reader.cpp' Cython extension (up-to-date)
    copying build\lib.win-amd64-cpython-39\ansys\mapdl\reader\_archive.cp39-win_amd64.pyd -> ansys\mapdl\reader
    error: could not delete 'ansys\mapdl\reader\_archive.cp39-win_amd64.pyd': Access is denied
    ----------------------------------------
  Rolling back uninstall of ansys-mapdl-reader
  Moving to c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages\ansys\mapdl\reader\
   from C:\ProgramData\Miniconda3\envs\emptypymapdl\Lib\site-packages\ansys\mapdl\~eader
  Moving to c:\programdata\miniconda3\envs\emptypymapdl\lib\site-packages\ansys_mapdl_reader-0.51.11.dist-info\
   from C:\ProgramData\Miniconda3\envs\emptypymapdl\Lib\site-packages\~nsys_mapdl_reader-0.51.11.dist-info
ERROR: Command errored out with exit status 1: 'C:\ProgramData\Miniconda3\envs\emptypymapdl\python.exe' -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\gayuso\\Other_Projects\\pymapdl-reader\\setup.py'"'"'; __file__='"'"'C:\\Users\\gayuso\\Other_Projects\\pymapdl-reader\\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps Check the logs for full command output.

Steps To Reproduce

Run pip install -e . in the cloned repo.

Which Operating System are you using?

Windows

Which Python version are you using?

3.9

Installed packages


(emptypymapdl) PS C:\Users\gayuso\Other_Projects\pymapdl-reader> python -m pip freeze
aiohttp==3.8.1
aiosignal==1.2.0
ansys-api-mapdl==0.5.1
ansys-mapdl-reader==0.51.11
appdirs==1.4.4
argcomplete==2.0.0
argon2-cffi==21.3.0
argon2-cffi-bindings==21.2.0
async-timeout==4.0.2
attrs==21.4.0
beautifulsoup4==4.11.1
bleach==4.1.0
certifi==2021.10.8
cffi==1.15.0
charset-normalizer==2.0.12
click==8.1.2
colorama==0.4.4
cycler==0.11.0
debugpy==1.5.1
defusedxml==0.7.1
entrypoints==0.3
fonttools==4.33.3
frozenlist==1.3.0
geomdl==5.3.1
google==3.0.0
grpcio==1.44.0
idna==3.3
imageio==2.18.0
importlib-metadata==4.11.3
ipython-genutils==0.2.0
ipywidgets==7.6.5
Jinja2==3.0.3
jsonschema==4.4.0
jupyter==1.0.0
jupyter-client==7.1.1
jupyter-console==6.4.0
jupyter-core==4.9.1
jupyterlab-pygments==0.1.2
jupyterlab-widgets==1.0.2
kiwisolver==1.4.2
mapdl @ file:///C:/Program%20Files/ANSYS%20Inc/v212/ANSYS/syslib/ansGRPC/User/mapdl-pyupf.tar.gz
MarkupSafe==2.0.1
matplotlib==3.5.1
mistune==0.8.4
mpmath==1.2.1
multidict==6.0.2
nbclient==0.5.10
nbconvert==6.4.0
nest-asyncio==1.5.4
nose==1.3.7
notebook==6.4.7
numpy==1.22.3
packaging==21.3
pandocfilters==1.5.0
Pillow==9.1.0
pipx==1.0.0
prometheus-client==0.12.0
protobuf==3.20.1
pycparser==2.21
pyiges==0.2.1
pyparsing==3.0.8
pyrsistent==0.18.1
pytest-cov==3.0.0
python-dateutil==2.8.2
pytz==2021.3
pyvista==0.34.1
pywin32==303
pywinpty==1.1.6
pyzmq==22.3.0
qtconsole==5.2.2
QtPy==2.0.0
scipy==1.8.0
scooby==0.5.12
Send2Trash==1.8.0
six==1.16.0
soupsieve==2.3.2.post1
sympy==1.9
terminado==0.12.1
testpath==0.5.0
tornado==6.1
tqdm==4.64.0
userpath==1.8.0
vtk==9.1.0
webencodings==0.5.1
widgetsnbextension==3.5.2
wincertstore==0.2
wslink==1.6.1
yarl==1.7.2
zipp==3.8.0

Probably related to #123 and #130

My fault.

It seems I was having some python processes running which were using the pymapdl-reader package, hence the access problem.

If I do a new cloned repo, there is no issue.