Skip to content

Commit

Permalink
Merge pull request #335 from BSd3v/fix-GHA-tests
Browse files Browse the repository at this point in the history
adjusting `setup.py` for GHA
  • Loading branch information
AnnMarieW authored Oct 9, 2024
2 parents 4e03f0c + 3cfde84 commit ba1a452
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
5 changes: 0 additions & 5 deletions .github/workflows/python-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@ on:
jobs:
test-react:
runs-on: ubuntu-latest
strategy:
matrix:
react-version: ["18.2.0"]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
Expand All @@ -40,9 +37,7 @@ jobs:
uv pip install --upgrade pip
uv pip install wheel
uv pip install ".[dev]"
echo "Using React version ${{ matrix.react-version }}"
npm ci
npm install react@${{ matrix.react-version }} react-dom@${{ matrix.react-version }}
npm i
npm run build
timeout-minutes: 20
Expand Down
1 change: 1 addition & 0 deletions requires-install.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
dash>=2
10 changes: 9 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@

package_name = package["name"].replace(" ", "_").replace("-", "_")

def read_req_file(req_type):
with open(f"requires-{req_type}.txt", encoding="utf-8") as fp:
requires = (line.strip() for line in fp)
return [req for req in requires if req and not req.startswith("#")]

setup(
name=package_name,
url=package["homepage"],
Expand All @@ -18,7 +23,10 @@
include_package_data=True,
license=package["license"],
description=package.get("description", package_name),
install_requires=[],
install_requires=read_req_file("install"),
extras_require={
"dev": read_req_file("dev"),
},
classifiers=[
"Framework :: Dash",
"Framework :: Flask",
Expand Down

0 comments on commit ba1a452

Please sign in to comment.