Skip to content

Commit 8937c6c

Browse files
committed
More uv fixes
1 parent a3015da commit 8937c6c

File tree

7 files changed

+67
-22
lines changed

7 files changed

+67
-22
lines changed

.github/dependabot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ updates:
99
directory: "/" # Location of package manifests
1010
schedule:
1111
interval: "weekly"
12-
- package-ecosystem: "poetry" # See documentation for possible values
12+
- package-ecosystem: "uv" # See documentation for possible values
1313
directory: "/" # Location of package manifests
1414
schedule:
1515
interval: "weekly"

.github/workflows/build-and-test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
run: dotnet restore test
3535

3636
- name: Install pytest runner
37-
run: pip install pytest
37+
run: pipx install pytest
3838

3939
- name: Install build dependencies
4040
run: dotnet restore Build.fsproj
@@ -47,8 +47,8 @@ jobs:
4747

4848
- name: Install dependencies
4949
run: |
50-
pip install poetry
51-
poetry install
50+
pipx install uv
51+
uv sync
5252
5353
- name: Test
5454
run: dotnet run Test

Build.fs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ Target.create "Build" (fun _ ->
2323
)
2424

2525
Target.create "Docs" (fun _ ->
26-
run poetry $"run jb build docs-src --path-output {buildPath}/docs" "."
26+
run uv $"run jb build docs-src --path-output {buildPath}/docs" "."
2727
Fake.IO.Shell.copyDir "docs" $"{buildPath}/docs/_build/html" (fun _ -> true)
2828
)
2929

@@ -37,7 +37,7 @@ Target.create "Test" (fun _ ->
3737
"python", dotnet $"fable --lang Python --outDir {buildPath}/tests" testsPath
3838
]
3939
|> runParallel
40-
run poetry $"run pytest {buildPath}/tests" ""
40+
run uv $"run pytest {buildPath}/tests" ""
4141
)
4242

4343
Target.create "Pack" (fun _ ->

Helpers.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ let dotnet = createProcess "dotnet"
7575

7676

7777
let pytest = createProcess "pytest"
78-
let poetry = createProcess "poetry"
78+
let uv = createProcess "uv"
7979
let jupyterBook = createProcess "jb"
8080

8181
let npm =

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,9 @@ It contains example code for using Fable Python with:
8484
- [Typed-BNF](https://github.com/thautwarm/Typed-BNF#readme)
8585
- [Zanaptak.TypedCssClasses](https://github.com/zanaptak/TypedCssClasses)
8686

87-
## Poetry
87+
## Uv
8888

89-
Fable.Python uses [Poetry](https://python-poetry.org/) for package and
89+
Fable.Python uses [Uv](https://docs.astral.sh/uv/) for package and
9090
dependency management. To handle dependencies when adding Fable Python
9191
compatible NuGet packages, you should use
9292
[Femto](https://github.com/Zaid-Ajaj/Femto).
@@ -110,8 +110,8 @@ libraries as long as:
110110
There's not much Python specific documentation yet, but the process of
111111
adding type bindings for Python is similar to JS:
112112

113-
- https://fable.io/docs/communicate/js-from-fable.html
114-
- https://medium.com/@zaid.naom/f-interop-with-javascript-in-fable-the-complete-guide-ccc5b896a59f
113+
- <https://fable.io/docs/communicate/js-from-fable.html>
114+
- <https://medium.com/@zaid.naom/f-interop-with-javascript-in-fable-the-complete-guide-ccc5b896a59f>
115115

116116
## Differences from JS
117117

@@ -145,6 +145,6 @@ Current plan:
145145

146146
- Compile Fable.Library as a published library (done)
147147

148-
- Use poetry for Python references to Fable modules (done)
148+
- Use uv for Python references to Fable modules (done)
149149

150150
- Update docs

src/pyproject.toml

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,13 @@
1-
2-
[tool.poetry]
1+
[project]
32
name = "fable-python"
4-
version = "0.18.0"
3+
version = "0.19.0"
54
description = "Python bindings for Fable"
6-
authors = ["Dag Brattli <[email protected]>"]
5+
authors = [{ name = "Dag Brattli", email = "[email protected]" }]
6+
requires-python = ">= 3.10, < 4.0"
77
license = "MIT"
8-
9-
[tool.poetry.dependencies]
10-
python = ">= 3.10, < 4.0"
11-
fable-library = ">=0.8.0"
8+
dependencies = ["fable-library>=0.8.0"]
129

1310
[build-system]
14-
requires = ["poetry-core>=1.0.0"]
15-
build-backend = "poetry.core.masonry.api"
11+
requires = ["hatchling"]
12+
build-backend = "hatchling.build"
13+

src/uv.lock

Lines changed: 47 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)