Skip to content

chore: migrate from rye to uv #833

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/pylint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install the latest version of rye
uses: eifinger/setup-rye@v3
- name: Install uv
uses: astral-sh/setup-uv@v3
- name: Install dependencies
run: rye sync --no-lock
run: uv sync --frozen
- name: Analysing the code with pylint
run: rye run pylint-ci
run: uv run poe pylint-ci
- name: Check Pylint score
run: |
pylint_score=$(rye run pylint-score-ci | grep 'Raw metrics' | awk '{print $4}')
pylint_score=$(uv run poe pylint-score-ci | grep 'Raw metrics' | awk '{print $4}')
if (( $(echo "$pylint_score < 8" | bc -l) )); then
echo "Pylint score is below 8. Blocking commit."
exit 1
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ jobs:
run: |
sudo apt update
sudo apt install -y git
- name: Install the latest version of rye
uses: eifinger/setup-rye@v3
- name: Install uv
uses: astral-sh/setup-uv@v3
- name: Install Node Env
uses: actions/setup-node@v4
with:
Expand All @@ -27,8 +27,8 @@ jobs:
persist-credentials: false
- name: Build app
run: |
rye sync --no-lock
rye build
uv sync --frozen
uv build
id: build_cache
if: success()
- name: Cache build
Expand Down
20 changes: 12 additions & 8 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ other-language-models = [
"langchain-anthropic>=0.1.11",
"langchain-huggingface>=0.0.3",
"langchain-nvidia-ai-endpoints>=0.1.6",
"langchain_together>=1.2.9"
"langchain_together>=0.2.0"
]

# Group 2: More Semantic Options
Expand All @@ -116,17 +116,21 @@ screenshot_scraper = [
requires = ["hatchling"]
build-backend = "hatchling.build"

[tool.rye]
managed = true
[dependency-groups]
dev = [
"burr[start]==0.22.1",
"sphinx==6.0",
"furo==2024.5.6",
]

[tool.uv]
dev-dependencies = [
"poethepoet>=0.31.1",
"pytest==8.0.0",
"pytest-mock==3.14.0",
"-e file:.[burr]",
"-e file:.[docs]",
"pylint>=3.2.5",
]

[tool.rye.scripts]
pylint-local = "pylint scrapegraphai/**/*.py"
[tool.poe.tasks]
pylint-local = "pylint scraperaphai/**/*.py"
pylint-ci = "pylint --disable=C0114,C0115,C0116 --exit-zero scrapegraphai/**/*.py"
update-requirements = "python 'manual deployment/autorequirements.py'"
Loading