Skip to content

Commit afb9841

Browse files
Add LV cables to the catalogue (#434)
Resolves #422 --------- Co-authored-by: Benoît Vinot <benoit.vinot@roseautechnologies.com>
1 parent 146460a commit afb9841

19 files changed

+573
-54
lines changed

.github/workflows/pre-commit.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,28 @@ jobs:
2626
with:
2727
lfs: false
2828
persist-credentials: false
29+
30+
- name: Create LFS file list
31+
run: git lfs ls-files -l | cut -d' ' -f1 | sort > .lfs-assets-id
32+
33+
- name: Cache git LFS
34+
uses: actions/cache@v5
35+
with:
36+
path: .git/lfs
37+
key: git-lfs-v1-${{ matrix.python-version }}-${{ hashFiles('.lfs-assets-id') }}
38+
restore-keys: |
39+
git-lfs-v1-${{ matrix.python-version }}
40+
git-lfs-v1
41+
git-lfs
42+
43+
- name: Git LFS
44+
run: |
45+
git lfs checkout
46+
git lfs pull
47+
git lfs prune --verify-remote
48+
2949
- uses: actions/setup-python@v6
3050
with:
3151
python-version: "3.13"
52+
3253
- uses: pre-commit/action@v3.0.1

.pre-commit-config.yaml

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,28 +11,28 @@ repos:
1111
- id: end-of-file-fixer
1212
- id: trailing-whitespace
1313
- repo: https://github.com/astral-sh/uv-pre-commit
14-
rev: 0.9.14
14+
rev: 0.9.22
1515
hooks:
1616
- id: uv-lock
1717
- repo: https://github.com/python-jsonschema/check-jsonschema
18-
rev: 0.35.0
18+
rev: 0.36.0
1919
hooks:
2020
- id: check-github-workflows
2121
- id: check-dependabot
2222
- id: check-readthedocs
2323
- repo: https://github.com/adhtruong/mirrors-typos
2424
# See https://github.com/crate-ci/typos/issues/390
2525
# repo: https://github.com/crate-ci/typos
26-
rev: v1.40.0
26+
rev: v1.41.0
2727
hooks:
2828
- id: typos
2929
args: [--force-exclude]
3030
- repo: https://github.com/woodruffw/zizmor-pre-commit
31-
rev: v1.18.0
31+
rev: v1.20.0
3232
hooks:
3333
- id: zizmor
3434
- repo: https://github.com/astral-sh/ruff-pre-commit
35-
rev: v0.14.7
35+
rev: v0.14.10
3636
hooks:
3737
- id: ruff-check
3838
args: [--fix]
@@ -44,20 +44,20 @@ repos:
4444
files: ^doc/.*\.md$
4545
args: [-l 90]
4646
- repo: https://github.com/executablebooks/mdformat
47-
rev: 0.7.22 # https://github.com/KyleKing/mdformat-front-matters/issues/11
47+
rev: 1.0.0
4848
hooks:
4949
- id: mdformat
5050
additional_dependencies:
5151
- mdformat-pyproject
52-
- mdformat-myst==0.2.2 # https://github.com/KyleKing/mdformat-front-matters/issues/11
52+
- mdformat-myst
5353
- mdformat-gfm
5454
- mdformat-gfm-alerts
5555
# - mdformat-ruff
5656
- mdformat-config
5757
- mdformat-deflist
5858
exclude: ^.github/.*\.md$
5959
- repo: https://github.com/rbubley/mirrors-prettier
60-
rev: v3.7.3
60+
rev: v3.7.4
6161
hooks:
6262
- id: prettier
6363
args: ["--print-width", "120"]
@@ -69,13 +69,18 @@ repos:
6969
- id: latexindent
7070
args: [-l, -m, -s, -wd]
7171
- repo: https://github.com/biomejs/pre-commit
72-
rev: v2.3.8
72+
rev: v2.3.11
7373
hooks:
7474
- id: biome-check
7575
types_or: [json, html, css]
7676
files: ".*" # Override default files regex that excludes html, rely on `types_or` instead
7777
- repo: https://github.com/tombi-toml/tombi-pre-commit
78-
rev: v0.7.0
78+
rev: v0.7.14
7979
hooks:
8080
- id: tombi-format
8181
- id: tombi-lint
82+
- repo: https://github.com/oxipng/oxipng
83+
rev: v10.0.0
84+
hooks:
85+
- id: oxipng
86+
args: ["-o", "4", "--strip", "safe", "--alpha"]

biome.jsonc

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,13 @@
11
{
2-
"$schema": "https://biomejs.dev/schemas/2.3.8/schema.json",
2+
"$schema": "https://biomejs.dev/schemas/2.3.11/schema.json",
33
"vcs": {
44
"enabled": false,
55
"clientKind": "git",
66
"useIgnoreFile": false
77
},
88
"files": {
99
"ignoreUnknown": false,
10-
"includes": [
11-
"**",
12-
"!doc/_static/**/*.html"
13-
],
14-
"maxSize": 2097152
15-
// 2 MiB to accommodate the networks Catalogue.html file (1.6 MiB)
10+
"includes": ["**", "!doc/_static/**/*.html"]
1611
},
1712
"formatter": {
1813
"enabled": true,

doc/Changelog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ og:description: See what's new in the latest release of Roseau Load Flow !
2121

2222
## Unreleased
2323

24+
- {gh-pr}`434` {gh-issue}`422` Add LV line parameters to the catalogue (e.g. `U_AL_3x150+70`). You can get all added LV
25+
lines with `rlf.LineParameters.get_catalogue(r"^[UOT]_[A-Z]+_3x(\d+)\+(\d+(?:\.\d+)?)$")`.
26+
2427
- {gh-pr}`429` {gh-issue}`298` Add `rlf.plotting.voltage_profile` function to plot the voltage profile of a network. The
2528
function returns an object with `plot_matplotlib()` and `plot_plotly()` methods to create plots using Matplotlib or
2629
Plotly respectively.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)