Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.4.3: Tests fail to run: ImportError: cannot import name 'bs' from 'kliff.descriptors.bispectrum' #197

Open
yurivict opened this issue Nov 17, 2024 · 0 comments

Comments

@yurivict
Copy link

Describe the bug
Errors:

___________________________________________________________________ ERROR collecting tests/uq/test_bootstrap_empirical.py ___________________________________________________________________
ImportError while importing test module '/usr/ports/science/py-kliff/work-py311/kliff-0.4.3/tests/uq/test_bootstrap_empirical.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/local/lib/python3.11/importlib/__init__.py:126: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
tests/uq/test_bootstrap_empirical.py:9: in <module>
    from kliff.loss import Loss
kliff/loss.py:10: in <module>
    from kliff.calculators.calculator_torch import CalculatorTorch
kliff/calculators/__init__.py:9: in <module>
    from .calculator_torch import CalculatorTorch
kliff/calculators/calculator_torch.py:10: in <module>
    from kliff.dataset.dataset_torch import FingerprintsDataset, fingerprints_collate_fn
kliff/dataset/dataset_torch.py:7: in <module>
    from kliff.descriptors.descriptor import load_fingerprints
kliff/descriptors/__init__.py:1: in <module>
    from .bispectrum.bispectrum import Bispectrum
kliff/descriptors/bispectrum/bispectrum.py:4: in <module>
    from kliff.descriptors.bispectrum import bs  # C extension
E   ImportError: cannot import name 'bs' from 'kliff.descriptors.bispectrum' (/usr/ports/science/py-kliff/work-py311/kliff-0.4.3/kliff/descriptors/bispectrum/__init__.py)
______________________________________________________________________ ERROR collecting tests/uq/test_bootstrap_nn.py _______________________________________________________________________
ImportError while importing test module '/usr/ports/science/py-kliff/work-py311/kliff-0.4.3/tests/uq/test_bootstrap_nn.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/local/lib/python3.11/importlib/__init__.py:126: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
tests/uq/test_bootstrap_nn.py:12: in <module>
    from kliff.calculators import CalculatorTorch
kliff/calculators/__init__.py:9: in <module>
    from .calculator_torch import CalculatorTorch
kliff/calculators/calculator_torch.py:10: in <module>
    from kliff.dataset.dataset_torch import FingerprintsDataset, fingerprints_collate_fn
kliff/dataset/dataset_torch.py:7: in <module>
    from kliff.descriptors.descriptor import load_fingerprints
kliff/descriptors/__init__.py:1: in <module>
    from .bispectrum.bispectrum import Bispectrum
kliff/descriptors/bispectrum/bispectrum.py:4: in <module>
    from kliff.descriptors.bispectrum import bs  # C extension
E   ImportError: cannot import name 'bs' from 'kliff.descriptors.bispectrum' (/usr/ports/science/py-kliff/work-py311/kliff-0.4.3/kliff/descriptors/bispectrum/__init__.py)
______________________________________________________________ ERROR collecting tests/uq/test_bootstrap_nn_separate_species.py ______________________________________________________________

To Reproduce
pytest

Additional context
Add any other context about the problem here. For example,

  • Operating system (Linux/Mac/Win) and version: FreeBSD 14.1
  • Python version: 3.11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant