Skip to content

Commit

Permalink
fix: migrate from poetry to uv
Browse files Browse the repository at this point in the history
  • Loading branch information
mirkolenz committed Feb 13, 2025
1 parent a66aeae commit f9128c2
Show file tree
Hide file tree
Showing 7 changed files with 148 additions and 175 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BUF_TOKEN: ${{ secrets.BUF_TOKEN }}
with:
semantic_version: ^23
semantic_version: ^24
extra_plugins: |
@semantic-release/git@^10
@semantic-release/changelog@^6
@semantic-release/exec@^6
conventional-changelog-conventionalcommits@^7
@cihelper/semanticrelease-plugin-poetry@^2
@semantic-release/exec@^7
conventional-changelog-conventionalcommits@^8
@cihelper/semanticrelease-plugin-uv@^1
- uses: pypa/gh-action-pypi-publish@release/v1
if: ${{ steps.semanticrelease.outputs.new_release_published == 'true' }}
8 changes: 4 additions & 4 deletions .releaserc.js → .releaserc.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module.exports = {
export default {
branches: [
{ name: "main" },
{ name: "next" },
Expand Down Expand Up @@ -34,9 +34,9 @@ module.exports = {
},
],
[
"@cihelper/semanticrelease-plugin-poetry",
"@cihelper/semanticrelease-plugin-uv",
{
publishPoetry: true,
uvPublish: false,
},
],
[
Expand All @@ -55,7 +55,7 @@ module.exports = {
"@semantic-release/git",
{
message: "chore(release): ${nextRelease.version}",
assets: ["pyproject.toml", "*/__init__.py", "CHANGELOG.md"],
assets: ["pyproject.toml", "uv.lock", "*/__init__.py", "CHANGELOG.md"],
},
],
],
Expand Down
20 changes: 10 additions & 10 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 4 additions & 5 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@
...
}:
let
poetry = pkgs.poetry;
uv = pkgs.uv;
python = pkgs.python312;
packages = [
poetry
uv
python
config.packages.buf-generate
];
Expand All @@ -49,11 +49,10 @@
};
devShells.default = pkgs.mkShell {
inherit packages;
POETRY_VIRTUALENVS_IN_PROJECT = true;
LD_LIBRARY_PATH = lib.makeLibraryPath (with pkgs; [ stdenv.cc.cc ]);
UV_PYTHON = python;
shellHook = ''
${lib.getExe poetry} env use ${lib.getExe python}
${lib.getExe poetry} install --all-extras --no-root
uv sync --all-extras --locked
'';
};
};
Expand Down
133 changes: 0 additions & 133 deletions poetry.lock

This file was deleted.

30 changes: 11 additions & 19 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,26 +1,18 @@
[tool.poetry]
[project]
name = "arg-services"
version = "1.7.5"
description = "gRPC definitions for microservice-based argumentation machines"
authors = ["Mirko Lenz <[email protected]>"]
license = "MIT"
authors = [{ name = "Mirko Lenz", email = "[email protected]" }]
readme = "README.md"
homepage = "http://recap.uni-trier.de"
repository = "https://github.com/recap-utr/arg-services-python"
include = ["src/**/*"]
packages = [
{ include = "arg_services", from = "src" },
{ include = "google/api", from = "src" },
requires-python = ">=3.10"
dependencies = [
"grpc-stubs>=1,<2",
"grpcio>=1,<2",
"grpcio-reflection>=1,<2",
"protobuf>=4,<6",
"types-protobuf>=4,<6",
]

[tool.poetry.dependencies]
python = "^3.10"
grpc-stubs = "^1"
grpcio = "^1"
grpcio-reflection = "^1"
protobuf = "^5"
types-protobuf = "^5"

[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
requires = ["setuptools>=61"]
build-backend = "setuptools.build_meta"
Loading

0 comments on commit f9128c2

Please sign in to comment.