You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running pytest for diffpy.pdfmorph in the main branch.
FAILED tests/test_pdfmorphapp.py::TestApp::test_parser_systemexits - AttributeError: module 'diffpy.utils.parsers' has no attribute 'loaddata'
FAILED tests/test_pdfmorphapp.py::TestApp::test_morphsequence - AttributeError: module 'diffpy.utils.parsers' has no attribute 'loaddata'
FAILED tests/test_pdfmorphio.py::TestApp::test_morph_outputs - AttributeError: module 'diffpy.utils.parsers' has no attribute 'loaddata'
FAILED tests/test_tools.py::TestTools::test_field_sort - AttributeError: module 'diffpy.utils.parsers' has no attribute 'loaddata'
The problem is related to diffpy.utils's sub-package parsers. Old parser is reconstructed as a sub-package and loaddata is a module now.
Proposed solution
A similar structure found in other projects under diffpy.
e.g. for diffpy.pdfmorph 's sub-package morph. The problem is avoided by importing the package's modules in its __init__.py.
Problem
Running pytest for
diffpy.pdfmorph
in the main branch.It comes from
diffpy.pdfmorph
tools.pyThe problem is related to
diffpy.utils
's sub-packageparsers
. Oldparser
is reconstructed as a sub-package andloaddata
is a module now.Proposed solution
A similar structure found in other projects under
diffpy
.e.g. for
diffpy.pdfmorph
's sub-packagemorph
. The problem is avoided by importing the package's modules in its__init__.py
.Mirroring this method may solve the problem
The text was updated successfully, but these errors were encountered: