diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 31e3a4a2..d9c4c069 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -31,7 +31,7 @@ jobs: - name: Install dependencies run: | python3 -m pip install --upgrade pip - python3 -m pip install -e ".[test]" --constraint .github/dependabot/constraints.txt + python3 -m pip install ".[test]" --constraint .github/dependabot/constraints.txt - name: Test with pytest run: | diff --git a/setup.py b/setup.py index ee1dc136..4fa60399 100755 --- a/setup.py +++ b/setup.py @@ -21,55 +21,57 @@ def find_version(*parts): raise RuntimeError("Unable to find version string.") -setup(name="EXtra-geom", - version=find_version("extra_geom", "__init__.py"), - author="European XFEL GmbH", - author_email="da-support@xfel.eu", - maintainer="Thomas Michelat", - url="https://github.com/European-XFEL/EXtra-geom", - description="Tools to work with EuXFEL detector geometry and assemble detector images", - long_description=read("README.md"), - long_description_content_type='text/markdown', - license="BSD-3-Clause", - packages=find_packages(), - package_data={ - 'extra_geom.tests': ['dssc_geo_june19.h5', 'lpd_mar_18.h5'], - }, - install_requires=[ - 'cfelpyutils>=0.92', - 'h5py>=2.7.1', - 'matplotlib', - 'numpy', - 'scipy', - ], - extras_require={ - 'docs': [ - 'sphinx', - 'nbsphinx', - 'ipython', # For nbsphinx syntax highlighting - 'sphinxcontrib_github_alt', - ], - 'test': [ - 'pytest', - 'pytest-cov', - 'coverage', - 'nbval', - 'testpath', - ] - }, - python_requires='>=3.6', - classifiers=[ - 'Development Status :: 3 - Alpha', - 'Environment :: Console', - 'Intended Audience :: Developers', - 'Intended Audience :: Science/Research', - 'License :: OSI Approved :: BSD License', - 'Operating System :: POSIX :: Linux', - 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.5', - 'Programming Language :: Python :: 3.6', - 'Programming Language :: Python :: 3.7', - 'Topic :: Scientific/Engineering :: Information Analysis', - 'Topic :: Scientific/Engineering :: Physics', - ] +setup( + name="EXtra-geom", + version=find_version("src", "extra_geom", "__init__.py"), + author="European XFEL GmbH", + author_email="da-support@xfel.eu", + maintainer="Thomas Michelat", + url="https://github.com/European-XFEL/EXtra-geom", + description="Tools to work with EuXFEL detector geometry and assemble detector images", + long_description=read("README.md"), + long_description_content_type='text/markdown', + license="BSD-3-Clause", + packages=find_packages("src"), + package_dir={"": "src"}, + # package_data={ + # 'extra_geom.tests': ['dssc_geo_june19.h5', 'lpd_mar_18.h5'], + # }, + install_requires=[ + 'cfelpyutils>=0.92', + 'h5py>=2.7.1', + 'matplotlib', + 'numpy', + 'scipy', + ], + extras_require={ + 'docs': [ + 'sphinx', + 'nbsphinx', + 'ipython', # For nbsphinx syntax highlighting + 'sphinxcontrib_github_alt', + ], + 'test': [ + 'pytest', + 'pytest-cov', + 'coverage', + 'nbval', + 'testpath', + ] + }, + python_requires='>=3.6', + classifiers=[ + 'Development Status :: 3 - Alpha', + 'Environment :: Console', + 'Intended Audience :: Developers', + 'Intended Audience :: Science/Research', + 'License :: OSI Approved :: BSD License', + 'Operating System :: POSIX :: Linux', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.5', + 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', + 'Topic :: Scientific/Engineering :: Information Analysis', + 'Topic :: Scientific/Engineering :: Physics', + ] ) diff --git a/extra_geom/__init__.py b/src/extra_geom/__init__.py similarity index 100% rename from extra_geom/__init__.py rename to src/extra_geom/__init__.py diff --git a/extra_geom/crystfel_fmt.py b/src/extra_geom/crystfel_fmt.py similarity index 100% rename from extra_geom/crystfel_fmt.py rename to src/extra_geom/crystfel_fmt.py diff --git a/extra_geom/detectors.py b/src/extra_geom/detectors.py similarity index 100% rename from extra_geom/detectors.py rename to src/extra_geom/detectors.py diff --git a/extra_geom/lpd_old.py b/src/extra_geom/lpd_old.py similarity index 100% rename from extra_geom/lpd_old.py rename to src/extra_geom/lpd_old.py diff --git a/extra_geom/snapped.py b/src/extra_geom/snapped.py similarity index 100% rename from extra_geom/snapped.py rename to src/extra_geom/snapped.py diff --git a/extra_geom/tests/__init__.py b/tests/__init__.py similarity index 100% rename from extra_geom/tests/__init__.py rename to tests/__init__.py diff --git a/extra_geom/tests/dssc_geo_june19.h5 b/tests/dssc_geo_june19.h5 similarity index 100% rename from extra_geom/tests/dssc_geo_june19.h5 rename to tests/dssc_geo_june19.h5 diff --git a/extra_geom/tests/lpd_mar_18.h5 b/tests/lpd_mar_18.h5 similarity index 100% rename from extra_geom/tests/lpd_mar_18.h5 rename to tests/lpd_mar_18.h5 diff --git a/extra_geom/tests/test_agipd500k2g_geometry.py b/tests/test_agipd500k2g_geometry.py similarity index 100% rename from extra_geom/tests/test_agipd500k2g_geometry.py rename to tests/test_agipd500k2g_geometry.py diff --git a/extra_geom/tests/test_agipd_geometry.py b/tests/test_agipd_geometry.py similarity index 100% rename from extra_geom/tests/test_agipd_geometry.py rename to tests/test_agipd_geometry.py diff --git a/extra_geom/tests/test_dssc_geometry.py b/tests/test_dssc_geometry.py similarity index 100% rename from extra_geom/tests/test_dssc_geometry.py rename to tests/test_dssc_geometry.py diff --git a/extra_geom/tests/test_geometry_old.py b/tests/test_geometry_old.py similarity index 100% rename from extra_geom/tests/test_geometry_old.py rename to tests/test_geometry_old.py diff --git a/extra_geom/tests/test_lpd_geometry.py b/tests/test_lpd_geometry.py similarity index 100% rename from extra_geom/tests/test_lpd_geometry.py rename to tests/test_lpd_geometry.py diff --git a/extra_geom/tests/utils.py b/tests/utils.py similarity index 100% rename from extra_geom/tests/utils.py rename to tests/utils.py