Skip to content

Commit

Permalink
Revert "feat: make seisbench dependency optional (#578)"
Browse files Browse the repository at this point in the history
This reverts commit a4ced3a.
  • Loading branch information
Jinxin Ma authored and Jinxin Ma committed Nov 15, 2024
1 parent a4ced3a commit 67d6d43
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 16 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
echo "/opt/spark-3.0.0-bin-hadoop2.7/bin" >> $GITHUB_PATH
python -m pip install --upgrade --upgrade-strategy eager pyspark pytest-spark
- name: Install
run: python -m pip install -C--global-option=build -C--global-option=--debug -v '.[seisbench]'
run: python -m pip install -C--global-option=build -C--global-option=--debug -v .
- name: Test with pytest
run: |
export MSPASS_HOME=$(pwd)
Expand Down
14 changes: 12 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ authors = [
{name = "Ian Wang", email = "[email protected]"},
{name = "Gary Pavlis", email = "[email protected]"},
]
dynamic = ["dependencies", "scripts", "version", "optional-dependencies"]
requires-python = ">=3.8"
dynamic = ["dependencies", "scripts", "version"]

[build-system]
requires = ["setuptools>=64", "setuptools_scm>=8", "wheel", "numpy"]
Expand All @@ -19,5 +18,16 @@ dependencies = {file = ["requirements.txt"]}
cmake-extension = "setup:CMakeExtension"
cmake-build = "setup:CMakeBuild"

[tool.poetry.dependencies]
python = "^3.8"

[tool.poetry.extras]
complete = ["numpy", "pandas", "scipy", "matplotlib"]

[tool.poetry.scripts]
mspass-dbclean = "mspasspy.db.script.dbclean:main"
mspass-dbverify = "mspasspy.db.script.dbverify:main"
mspass-normalize_mseed = "mspasspy.db.script.normalize_mseed:main"

[tool.setuptools_scm]

4 changes: 3 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,6 @@ zarr
pandas==1.5.3
numba
multitaper
ipympl
ipympl
seisbench==0.4.1; python_version < '3.9'
seisbench>0.4.1; python_version >= '3.9'
13 changes: 1 addition & 12 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,6 @@ def build_extension(self, ext):
],
}

complete_deps = ["numpy", "pandas", "scipy", "matplotlib"]
seisbench_deps = [
"seisbench==0.4.1; python_version < '3.9'",
"seisbench>0.4.1; python_version >= '3.9'",
]

setup(
name="mspasspy",
ext_modules=[CMakeExtension("mspasspy.ccore")],
Expand All @@ -104,10 +98,5 @@ def build_extension(self, ext):
),
package_data={"": ["*.yaml", "*.pf"]},
include_package_data=True,
install_requires=[],
python_requires=">=3.8",
extras_require={
"complete": complete_deps,
"seisbench": complete_deps + seisbench_deps,
}
install_requires=["pyyaml"],
)

0 comments on commit 67d6d43

Please sign in to comment.