Skip to content

import xswap requires numpy but setup.py does not include this dependency #23

@dhimmel

Description

@dhimmel
>>> import xswap
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/dhimmel/anaconda3/envs/xswap/lib/python3.7/site-packages/xswap/__init__.py", line 1, in <module>
    from xswap import network_formats
  File "/home/dhimmel/anaconda3/envs/xswap/lib/python3.7/site-packages/xswap/network_formats.py", line 3, in <module>
    import numpy
ModuleNotFoundError: No module named 'numpy'

I think we wanted users without numpy to be able to use the package, right? So we should probably just make the numpy import lazy.

Also you may want to specify extras_require in setup.py for users who want to install the extra dependencies.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions