Skip to content

Commit

Permalink
pre-installing deps in workflows (#17)
Browse files Browse the repository at this point in the history
* workflow cleanup and correction
  • Loading branch information
flowstate authored Feb 6, 2025
1 parent 86bba2d commit adc2470
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 28 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/pr-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ jobs:
with:
python-version: '3.12'

# Install all dependencies from pyproject.toml
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install requests
pip install -e .
- name: Set preview version
run: |
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ jobs:
with:
python-version: '3.12'

# Install all dependencies from pyproject.toml
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .
- name: Get Version
id: version
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/version-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ jobs:
owner: owner,
repo: repo,
comment_id: versionComment.id,
body: `❌ **Version Check Failed**\n\nPlease increment...`
body: `❌ **Version Check Failed**\n\nPlease increment the version. Current version in main: ${process.env.MAIN_VERSION}, PR version: ${process.env.PR_VERSION}`
});
}
} else if (!success) {
Expand All @@ -94,6 +94,6 @@ jobs:
owner: owner,
repo: repo,
issue_number: prNumber,
body: `❌ **Version Check Failed**\n\nPlease increment...`
body: `❌ **Version Check Failed**\n\nPlease increment the version. Current version in main: ${process.env.MAIN_VERSION}, PR version: ${process.env.PR_VERSION}`
});
}
33 changes: 9 additions & 24 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
[build-system]
requires = [
"setuptools >= 61.0",
"requests"
"setuptools >= 61.0"
]
build-backend = "setuptools.build_meta"

Expand Down Expand Up @@ -38,34 +37,20 @@ classifiers = [
[project.optional-dependencies]
dev = [
"ruff>=0.3.0",
"twine",
"wheel",
"build",
"twine>=4.0.0",
"wheel>=0.40.0",
"build>=1.0.0"
]
test = [
"pytest>=7.0.0",
"pytest-cov>=4.0.0"
]

[project.urls]
Homepage = "https://github.com/socketdev/socket-sdk-python"

[tool.setuptools.packages.find]
include = [
"socketdev",
"socketdev.core",
"socketdev.dependencies",
"socketdev.export",
"socketdev.fullscans",
"socketdev.npm",
"socketdev.openapi",
"socketdev.org",
"socketdev.purl",
"socketdev.quota",
"socketdev.report",
"socketdev.repos",
"socketdev.repositories",
"socketdev.sbom",
"socketdev.settings",
"socketdev.tools",
"socketdev.utils",
]
include = ["socketdev", "socketdev.*"]

[tool.setuptools.dynamic]
version = {attr = "socketdev.version.__version__"}
Expand Down
2 changes: 1 addition & 1 deletion socketdev/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "2.0.0"
__version__ = "2.0.1"

0 comments on commit adc2470

Please sign in to comment.