runqd 0.4.10__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- runqd-0.4.10/.github/renovate.json5 +97 -0
- runqd-0.4.10/.github/workflows/cd.yml +22 -0
- runqd-0.4.10/.github/workflows/ci.yml +62 -0
- runqd-0.4.10/.github/workflows/pypi.yml +109 -0
- runqd-0.4.10/.github/workflows/release.yml +182 -0
- runqd-0.4.10/.gitignore +8 -0
- runqd-0.4.10/.pre-commit-config.yaml +22 -0
- runqd-0.4.10/CHANGELOG.md +158 -0
- runqd-0.4.10/CODE_OF_CONDUCT.md +122 -0
- runqd-0.4.10/CONTRIBUTING.md +51 -0
- runqd-0.4.10/Cargo.lock +3641 -0
- runqd-0.4.10/Cargo.toml +142 -0
- runqd-0.4.10/LICENSE +21 -0
- runqd-0.4.10/PKG-INFO +258 -0
- runqd-0.4.10/README.md +232 -0
- runqd-0.4.10/README_CN.md +203 -0
- runqd-0.4.10/assets/Sniapaste.png +0 -0
- runqd-0.4.10/build.rs +13 -0
- runqd-0.4.10/bun.lock +749 -0
- runqd-0.4.10/docs/.vitepress/config.ts +251 -0
- runqd-0.4.10/docs/.vitepress/theme/index.ts +11 -0
- runqd-0.4.10/docs/README.md +29 -0
- runqd-0.4.10/docs/src/getting-started/installation.md +265 -0
- runqd-0.4.10/docs/src/getting-started/quick-start.md +331 -0
- runqd-0.4.10/docs/src/index.md +38 -0
- runqd-0.4.10/docs/src/public/logo.svg +65 -0
- runqd-0.4.10/docs/src/reference/gbatch-reference.md +753 -0
- runqd-0.4.10/docs/src/reference/gcancel-reference.md +557 -0
- runqd-0.4.10/docs/src/reference/ginfo-reference.md +84 -0
- runqd-0.4.10/docs/src/reference/gqueue-reference.md +626 -0
- runqd-0.4.10/docs/src/reference/quick-reference.md +393 -0
- runqd-0.4.10/docs/src/user-guide/configuration.md +271 -0
- runqd-0.4.10/docs/src/user-guide/gpu-management.md +594 -0
- runqd-0.4.10/docs/src/user-guide/job-dependencies.md +691 -0
- runqd-0.4.10/docs/src/user-guide/job-lifecycle.md +137 -0
- runqd-0.4.10/docs/src/user-guide/job-submission.md +731 -0
- runqd-0.4.10/docs/src/user-guide/time-limits.md +594 -0
- runqd-0.4.10/docs/src/zh-CN/getting-started/installation.md +265 -0
- runqd-0.4.10/docs/src/zh-CN/getting-started/quick-start.md +331 -0
- runqd-0.4.10/docs/src/zh-CN/index.md +38 -0
- runqd-0.4.10/docs/src/zh-CN/reference/gbatch-reference.md +753 -0
- runqd-0.4.10/docs/src/zh-CN/reference/gcancel-reference.md +557 -0
- runqd-0.4.10/docs/src/zh-CN/reference/ginfo-reference.md +84 -0
- runqd-0.4.10/docs/src/zh-CN/reference/gqueue-reference.md +626 -0
- runqd-0.4.10/docs/src/zh-CN/reference/quick-reference.md +393 -0
- runqd-0.4.10/docs/src/zh-CN/user-guide/configuration.md +271 -0
- runqd-0.4.10/docs/src/zh-CN/user-guide/gpu-management.md +594 -0
- runqd-0.4.10/docs/src/zh-CN/user-guide/job-dependencies.md +653 -0
- runqd-0.4.10/docs/src/zh-CN/user-guide/job-lifecycle.md +137 -0
- runqd-0.4.10/docs/src/zh-CN/user-guide/job-submission.md +731 -0
- runqd-0.4.10/docs/src/zh-CN/user-guide/time-limits.md +594 -0
- runqd-0.4.10/install.sh +251 -0
- runqd-0.4.10/justfile +14 -0
- runqd-0.4.10/package.json +14 -0
- runqd-0.4.10/pyproject.toml +43 -0
- runqd-0.4.10/src/bin/gbatch/cli.rs +114 -0
- runqd-0.4.10/src/bin/gbatch/commands/add.rs +1025 -0
- runqd-0.4.10/src/bin/gbatch/commands/new.rs +157 -0
- runqd-0.4.10/src/bin/gbatch/commands.rs +17 -0
- runqd-0.4.10/src/bin/gbatch/main.rs +40 -0
- runqd-0.4.10/src/bin/gcancel/cli.rs +75 -0
- runqd-0.4.10/src/bin/gcancel/commands/cancel.rs +128 -0
- runqd-0.4.10/src/bin/gcancel/commands/fail.rs +8 -0
- runqd-0.4.10/src/bin/gcancel/commands/finish.rs +8 -0
- runqd-0.4.10/src/bin/gcancel/commands.rs +26 -0
- runqd-0.4.10/src/bin/gcancel/main.rs +29 -0
- runqd-0.4.10/src/bin/gctl/cli.rs +47 -0
- runqd-0.4.10/src/bin/gctl/commands/mod.rs +38 -0
- runqd-0.4.10/src/bin/gctl/commands/set_gpus.rs +24 -0
- runqd-0.4.10/src/bin/gctl/commands/set_group_max_concurrency.rs +39 -0
- runqd-0.4.10/src/bin/gctl/commands/show_gpus.rs +34 -0
- runqd-0.4.10/src/bin/gctl/main.rs +23 -0
- runqd-0.4.10/src/bin/gflowd/cli.rs +60 -0
- runqd-0.4.10/src/bin/gflowd/commands/down.rs +13 -0
- runqd-0.4.10/src/bin/gflowd/commands/reload.rs +323 -0
- runqd-0.4.10/src/bin/gflowd/commands/status.rs +35 -0
- runqd-0.4.10/src/bin/gflowd/commands/up.rs +15 -0
- runqd-0.4.10/src/bin/gflowd/commands.rs +40 -0
- runqd-0.4.10/src/bin/gflowd/events.rs +153 -0
- runqd-0.4.10/src/bin/gflowd/executor.rs +223 -0
- runqd-0.4.10/src/bin/gflowd/main.rs +33 -0
- runqd-0.4.10/src/bin/gflowd/scheduler_runtime.rs +1031 -0
- runqd-0.4.10/src/bin/gflowd/server.rs +989 -0
- runqd-0.4.10/src/bin/gflowd/state_saver.rs +171 -0
- runqd-0.4.10/src/bin/ginfo/cli.rs +32 -0
- runqd-0.4.10/src/bin/ginfo/commands/info.rs +160 -0
- runqd-0.4.10/src/bin/ginfo/commands.rs +1 -0
- runqd-0.4.10/src/bin/ginfo/main.rs +27 -0
- runqd-0.4.10/src/bin/gjob/cli.rs +226 -0
- runqd-0.4.10/src/bin/gjob/commands/attach.rs +58 -0
- runqd-0.4.10/src/bin/gjob/commands/close_sessions.rs +82 -0
- runqd-0.4.10/src/bin/gjob/commands/hold.rs +42 -0
- runqd-0.4.10/src/bin/gjob/commands/log.rs +34 -0
- runqd-0.4.10/src/bin/gjob/commands/redo.rs +336 -0
- runqd-0.4.10/src/bin/gjob/commands/release.rs +42 -0
- runqd-0.4.10/src/bin/gjob/commands/show.rs +117 -0
- runqd-0.4.10/src/bin/gjob/commands/update.rs +181 -0
- runqd-0.4.10/src/bin/gjob/commands.rs +119 -0
- runqd-0.4.10/src/bin/gjob/main.rs +18 -0
- runqd-0.4.10/src/bin/gjob/utils.rs +48 -0
- runqd-0.4.10/src/bin/gqueue/cli.rs +121 -0
- runqd-0.4.10/src/bin/gqueue/commands/list.rs +1057 -0
- runqd-0.4.10/src/bin/gqueue/commands.rs +27 -0
- runqd-0.4.10/src/bin/gqueue/main.rs +27 -0
- runqd-0.4.10/src/client.rs +503 -0
- runqd-0.4.10/src/config.rs +68 -0
- runqd-0.4.10/src/core/executor.rs +6 -0
- runqd-0.4.10/src/core/info.rs +15 -0
- runqd-0.4.10/src/core/job.rs +620 -0
- runqd-0.4.10/src/core/migrations.rs +120 -0
- runqd-0.4.10/src/core/mod.rs +78 -0
- runqd-0.4.10/src/core/scheduler.rs +1227 -0
- runqd-0.4.10/src/debug.rs +64 -0
- runqd-0.4.10/src/lib.rs +7 -0
- runqd-0.4.10/src/metrics.rs +128 -0
- runqd-0.4.10/src/tmux.rs +233 -0
- runqd-0.4.10/src/utils.rs +547 -0
- runqd-0.4.10/tests/cancel_during_execution_test.rs +186 -0
- runqd-0.4.10/tests/integration_test.rs +745 -0
- runqd-0.4.10/vercel.json +13 -0
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
{
|
|
2
|
+
semanticCommits: 'enabled',
|
|
3
|
+
commitMessageLowerCase: 'never',
|
|
4
|
+
configMigration: true,
|
|
5
|
+
dependencyDashboard: true,
|
|
6
|
+
customManagers: [
|
|
7
|
+
{
|
|
8
|
+
customType: 'regex',
|
|
9
|
+
managerFilePatterns: [
|
|
10
|
+
'/Cargo.toml$/',
|
|
11
|
+
'/^\\.github/workflows/ci.yml$/',
|
|
12
|
+
'/^\\.github/workflows/cd.yml$/',
|
|
13
|
+
],
|
|
14
|
+
matchStrings: [
|
|
15
|
+
'STABLE.*?(?<currentValue>\\d+\\.\\d+(\\.\\d+)?)',
|
|
16
|
+
'(?<currentValue>\\d+\\.\\d+(\\.\\d+)?).*?STABLE',
|
|
17
|
+
],
|
|
18
|
+
depNameTemplate: 'STABLE',
|
|
19
|
+
packageNameTemplate: 'rust-lang/rust',
|
|
20
|
+
datasourceTemplate: 'github-releases',
|
|
21
|
+
},
|
|
22
|
+
],
|
|
23
|
+
packageRules: [
|
|
24
|
+
{
|
|
25
|
+
commitMessageTopic: 'Rust Stable',
|
|
26
|
+
matchManagers: [
|
|
27
|
+
'custom.regex',
|
|
28
|
+
],
|
|
29
|
+
matchPackageNames: [
|
|
30
|
+
'STABLE',
|
|
31
|
+
],
|
|
32
|
+
extractVersion: '^(?<version>\\d+\\.\\d+)',
|
|
33
|
+
schedule: [
|
|
34
|
+
'* * * * *',
|
|
35
|
+
],
|
|
36
|
+
automerge: true,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
matchManagers: [
|
|
40
|
+
'cargo',
|
|
41
|
+
],
|
|
42
|
+
matchDepTypes: [
|
|
43
|
+
'build-dependencies',
|
|
44
|
+
'dependencies',
|
|
45
|
+
],
|
|
46
|
+
matchCurrentVersion: '>=0.1.0',
|
|
47
|
+
matchUpdateTypes: [
|
|
48
|
+
'patch',
|
|
49
|
+
],
|
|
50
|
+
enabled: false,
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
matchManagers: [
|
|
54
|
+
'cargo',
|
|
55
|
+
],
|
|
56
|
+
matchDepTypes: [
|
|
57
|
+
'build-dependencies',
|
|
58
|
+
'dependencies',
|
|
59
|
+
],
|
|
60
|
+
matchCurrentVersion: '>=1.0.0',
|
|
61
|
+
matchUpdateTypes: [
|
|
62
|
+
'minor',
|
|
63
|
+
'patch',
|
|
64
|
+
],
|
|
65
|
+
enabled: false,
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
matchManagers: [
|
|
69
|
+
'cargo',
|
|
70
|
+
],
|
|
71
|
+
matchDepTypes: [
|
|
72
|
+
'dev-dependencies',
|
|
73
|
+
],
|
|
74
|
+
matchCurrentVersion: '>=0.1.0',
|
|
75
|
+
matchUpdateTypes: [
|
|
76
|
+
'patch',
|
|
77
|
+
],
|
|
78
|
+
automerge: true,
|
|
79
|
+
groupName: 'compatible (dev)',
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
matchManagers: [
|
|
83
|
+
'cargo',
|
|
84
|
+
],
|
|
85
|
+
matchDepTypes: [
|
|
86
|
+
'dev-dependencies',
|
|
87
|
+
],
|
|
88
|
+
matchCurrentVersion: '>=1.0.0',
|
|
89
|
+
matchUpdateTypes: [
|
|
90
|
+
'minor',
|
|
91
|
+
'patch',
|
|
92
|
+
],
|
|
93
|
+
automerge: true,
|
|
94
|
+
groupName: 'compatible (dev)',
|
|
95
|
+
},
|
|
96
|
+
],
|
|
97
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
name: Continuous Deployment
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- '[v]?[0-9]+.[0-9]+.[0-9]+'
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: write
|
|
10
|
+
packages: write
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
publish-cargo:
|
|
14
|
+
name: Publish to crates.io
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v6
|
|
18
|
+
- uses: dtolnay/rust-toolchain@stable
|
|
19
|
+
- uses: Swatinem/rust-cache@v2
|
|
20
|
+
- run: cargo publish
|
|
21
|
+
env:
|
|
22
|
+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
name: Continuous Integration
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
pull_request:
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
test:
|
|
11
|
+
name: Test Suite
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
steps:
|
|
14
|
+
- name: Checkout repository
|
|
15
|
+
uses: actions/checkout@v6
|
|
16
|
+
- name: Install Rust toolchain
|
|
17
|
+
uses: dtolnay/rust-toolchain@nightly
|
|
18
|
+
- uses: Swatinem/rust-cache@v2
|
|
19
|
+
- name: Run tests
|
|
20
|
+
run: cargo test --locked --all-features --workspace
|
|
21
|
+
|
|
22
|
+
rustfmt:
|
|
23
|
+
name: Rustfmt
|
|
24
|
+
runs-on: ubuntu-latest
|
|
25
|
+
steps:
|
|
26
|
+
- name: Checkout repository
|
|
27
|
+
uses: actions/checkout@v6
|
|
28
|
+
- name: Install Rust toolchain
|
|
29
|
+
uses: dtolnay/rust-toolchain@nightly
|
|
30
|
+
with:
|
|
31
|
+
components: rustfmt
|
|
32
|
+
- uses: Swatinem/rust-cache@v2
|
|
33
|
+
- name: Check formatting
|
|
34
|
+
run: cargo fmt --all --check
|
|
35
|
+
|
|
36
|
+
clippy:
|
|
37
|
+
name: Clippy
|
|
38
|
+
runs-on: ubuntu-latest
|
|
39
|
+
steps:
|
|
40
|
+
- name: Checkout repository
|
|
41
|
+
uses: actions/checkout@v6
|
|
42
|
+
- name: Install Rust toolchain
|
|
43
|
+
uses: dtolnay/rust-toolchain@nightly
|
|
44
|
+
with:
|
|
45
|
+
components: clippy
|
|
46
|
+
- uses: Swatinem/rust-cache@v2
|
|
47
|
+
- name: Clippy check
|
|
48
|
+
run: cargo clippy --all-targets --all-features --workspace -- -D warnings
|
|
49
|
+
|
|
50
|
+
docs:
|
|
51
|
+
name: Docs
|
|
52
|
+
runs-on: ubuntu-latest
|
|
53
|
+
steps:
|
|
54
|
+
- name: Checkout repository
|
|
55
|
+
uses: actions/checkout@v6
|
|
56
|
+
- name: Install Rust toolchain
|
|
57
|
+
uses: dtolnay/rust-toolchain@nightly
|
|
58
|
+
- uses: Swatinem/rust-cache@v2
|
|
59
|
+
- name: Check documentation
|
|
60
|
+
env:
|
|
61
|
+
RUSTDOCFLAGS: -D warnings
|
|
62
|
+
run: cargo doc --no-deps --document-private-items --all-features --workspace --examples
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
name: PyPI Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
tags:
|
|
8
|
+
- '*'
|
|
9
|
+
pull_request:
|
|
10
|
+
workflow_dispatch:
|
|
11
|
+
|
|
12
|
+
permissions:
|
|
13
|
+
contents: read
|
|
14
|
+
|
|
15
|
+
jobs:
|
|
16
|
+
linux:
|
|
17
|
+
runs-on: ${{ matrix.platform.runner }}
|
|
18
|
+
strategy:
|
|
19
|
+
matrix:
|
|
20
|
+
platform:
|
|
21
|
+
- runner: ubuntu-22.04
|
|
22
|
+
target: x86_64
|
|
23
|
+
- runner: ubuntu-22.04
|
|
24
|
+
target: x86
|
|
25
|
+
- runner: ubuntu-22.04
|
|
26
|
+
target: aarch64
|
|
27
|
+
- runner: ubuntu-22.04
|
|
28
|
+
target: armv7
|
|
29
|
+
steps:
|
|
30
|
+
- uses: actions/checkout@v6
|
|
31
|
+
- name: Build wheels
|
|
32
|
+
uses: PyO3/maturin-action@v1
|
|
33
|
+
with:
|
|
34
|
+
target: ${{ matrix.platform.target }}
|
|
35
|
+
args: --release --out dist
|
|
36
|
+
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
|
37
|
+
manylinux: auto
|
|
38
|
+
- name: Upload wheels
|
|
39
|
+
uses: actions/upload-artifact@v5
|
|
40
|
+
with:
|
|
41
|
+
name: wheels-linux-${{ matrix.platform.target }}
|
|
42
|
+
path: dist
|
|
43
|
+
|
|
44
|
+
musllinux:
|
|
45
|
+
runs-on: ${{ matrix.platform.runner }}
|
|
46
|
+
strategy:
|
|
47
|
+
matrix:
|
|
48
|
+
platform:
|
|
49
|
+
- runner: ubuntu-22.04
|
|
50
|
+
target: x86_64
|
|
51
|
+
- runner: ubuntu-22.04
|
|
52
|
+
target: x86
|
|
53
|
+
- runner: ubuntu-22.04
|
|
54
|
+
target: aarch64
|
|
55
|
+
- runner: ubuntu-22.04
|
|
56
|
+
target: armv7
|
|
57
|
+
steps:
|
|
58
|
+
- uses: actions/checkout@v6
|
|
59
|
+
- name: Build wheels
|
|
60
|
+
uses: PyO3/maturin-action@v1
|
|
61
|
+
with:
|
|
62
|
+
target: ${{ matrix.platform.target }}
|
|
63
|
+
args: --release --out dist
|
|
64
|
+
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
|
|
65
|
+
manylinux: musllinux_1_2
|
|
66
|
+
- name: Upload wheels
|
|
67
|
+
uses: actions/upload-artifact@v5
|
|
68
|
+
with:
|
|
69
|
+
name: wheels-musllinux-${{ matrix.platform.target }}
|
|
70
|
+
path: dist
|
|
71
|
+
sdist:
|
|
72
|
+
runs-on: ubuntu-latest
|
|
73
|
+
steps:
|
|
74
|
+
- uses: actions/checkout@v6
|
|
75
|
+
- name: Build sdist
|
|
76
|
+
uses: PyO3/maturin-action@v1
|
|
77
|
+
with:
|
|
78
|
+
command: sdist
|
|
79
|
+
args: --out dist
|
|
80
|
+
- name: Upload sdist
|
|
81
|
+
uses: actions/upload-artifact@v5
|
|
82
|
+
with:
|
|
83
|
+
name: wheels-sdist
|
|
84
|
+
path: dist
|
|
85
|
+
|
|
86
|
+
release:
|
|
87
|
+
name: Release
|
|
88
|
+
runs-on: ubuntu-latest
|
|
89
|
+
if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
|
|
90
|
+
needs: [linux, musllinux, sdist]
|
|
91
|
+
permissions:
|
|
92
|
+
# Use to sign the release artifacts
|
|
93
|
+
id-token: write
|
|
94
|
+
# Used to upload release artifacts
|
|
95
|
+
contents: write
|
|
96
|
+
# Used to generate artifact attestation
|
|
97
|
+
attestations: write
|
|
98
|
+
steps:
|
|
99
|
+
- uses: actions/download-artifact@v6
|
|
100
|
+
- name: Generate artifact attestation
|
|
101
|
+
uses: actions/attest-build-provenance@v3
|
|
102
|
+
with:
|
|
103
|
+
subject-path: 'wheels-*/*'
|
|
104
|
+
- name: Install uv
|
|
105
|
+
if: ${{ startsWith(github.ref, 'refs/tags/') }}
|
|
106
|
+
uses: astral-sh/setup-uv@v7
|
|
107
|
+
- name: Publish to PyPI
|
|
108
|
+
if: ${{ startsWith(github.ref, 'refs/tags/') }}
|
|
109
|
+
run: uv publish 'wheels-*/*'
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- 'v[0-9]+.[0-9]+.[0-9]+'
|
|
7
|
+
workflow_dispatch:
|
|
8
|
+
|
|
9
|
+
permissions:
|
|
10
|
+
contents: write
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
create-release:
|
|
14
|
+
name: Create GitHub Release
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
outputs:
|
|
17
|
+
version: ${{ steps.extract_version.outputs.version }}
|
|
18
|
+
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v6
|
|
21
|
+
with:
|
|
22
|
+
fetch-depth: 0
|
|
23
|
+
|
|
24
|
+
- name: Extract version from tag
|
|
25
|
+
id: extract_version
|
|
26
|
+
run: |
|
|
27
|
+
VERSION=${GITHUB_REF#refs/tags/}
|
|
28
|
+
echo "version=$VERSION" >> $GITHUB_OUTPUT
|
|
29
|
+
echo "Version: $VERSION"
|
|
30
|
+
|
|
31
|
+
- name: Generate changelog
|
|
32
|
+
id: changelog
|
|
33
|
+
run: |
|
|
34
|
+
PREV_TAG=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "")
|
|
35
|
+
if [ -n "$PREV_TAG" ]; then
|
|
36
|
+
CHANGES=$(git log --oneline --pretty=format:"* %s" $PREV_TAG..HEAD)
|
|
37
|
+
else
|
|
38
|
+
CHANGES=$(git log --oneline --pretty=format:"* %s")
|
|
39
|
+
fi
|
|
40
|
+
|
|
41
|
+
cat << 'EOF' > release_notes.md
|
|
42
|
+
## What's Changed
|
|
43
|
+
|
|
44
|
+
EOF
|
|
45
|
+
echo "$CHANGES" >> release_notes.md
|
|
46
|
+
cat << 'EOF' >> release_notes.md
|
|
47
|
+
|
|
48
|
+
## Installation
|
|
49
|
+
|
|
50
|
+
### Quick Install (Linux x86_64) - Recommended
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
curl -fsSL https://gflow-releases.puqing.work/install.sh | sh
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Or from GitHub:
|
|
57
|
+
```bash
|
|
58
|
+
curl -fsSL https://raw.githubusercontent.com/AndPuQing/gflow/main/install.sh | sh
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### Alternative: Cargo
|
|
62
|
+
```bash
|
|
63
|
+
cargo install gflow
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
EOF
|
|
67
|
+
|
|
68
|
+
if [ -n "$PREV_TAG" ]; then
|
|
69
|
+
echo "" >> release_notes.md
|
|
70
|
+
echo "**Full Changelog**: https://github.com/AndPuQing/gflow/compare/$PREV_TAG...${{ steps.extract_version.outputs.version }}" >> release_notes.md
|
|
71
|
+
fi
|
|
72
|
+
|
|
73
|
+
cat release_notes.md
|
|
74
|
+
|
|
75
|
+
- name: Create Release
|
|
76
|
+
id: create_release
|
|
77
|
+
uses: softprops/action-gh-release@v2
|
|
78
|
+
with:
|
|
79
|
+
tag_name: ${{ steps.extract_version.outputs.version }}
|
|
80
|
+
name: Release ${{ steps.extract_version.outputs.version }}
|
|
81
|
+
body_path: release_notes.md
|
|
82
|
+
draft: false
|
|
83
|
+
prerelease: false
|
|
84
|
+
env:
|
|
85
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
86
|
+
|
|
87
|
+
build-and-upload:
|
|
88
|
+
name: Build and Upload Binaries
|
|
89
|
+
needs: create-release
|
|
90
|
+
runs-on: ubuntu-latest
|
|
91
|
+
strategy:
|
|
92
|
+
fail-fast: false
|
|
93
|
+
matrix:
|
|
94
|
+
include:
|
|
95
|
+
- target: x86_64-unknown-linux-musl
|
|
96
|
+
archive: tar.gz tar.xz tar.zst
|
|
97
|
+
steps:
|
|
98
|
+
- uses: actions/checkout@v6
|
|
99
|
+
|
|
100
|
+
- name: Build binaries with rust-build
|
|
101
|
+
uses: rust-build/rust-build.action@v1.4.5
|
|
102
|
+
id: build
|
|
103
|
+
env:
|
|
104
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
105
|
+
with:
|
|
106
|
+
TOOLCHAIN_VERSION: stable
|
|
107
|
+
RUSTTARGET: ${{ matrix.target }}
|
|
108
|
+
ARCHIVE_TYPES: ${{ matrix.archive }}
|
|
109
|
+
UPLOAD_MODE: none
|
|
110
|
+
|
|
111
|
+
- name: Upload to GitHub Release
|
|
112
|
+
uses: softprops/action-gh-release@v2
|
|
113
|
+
with:
|
|
114
|
+
tag_name: ${{ needs.create-release.outputs.version }}
|
|
115
|
+
files: |
|
|
116
|
+
output/*.tar.gz
|
|
117
|
+
output/*.tar.xz
|
|
118
|
+
output/*.tar.zst
|
|
119
|
+
output/*.sha256sum
|
|
120
|
+
env:
|
|
121
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
122
|
+
|
|
123
|
+
- name: Prepare R2 upload (archives only)
|
|
124
|
+
run: |
|
|
125
|
+
mkdir -p r2-upload
|
|
126
|
+
# Copy only archive files and checksums, not individual binaries
|
|
127
|
+
cp output/*.tar.gz r2-upload/ 2>/dev/null || true
|
|
128
|
+
cp output/*.tar.xz r2-upload/ 2>/dev/null || true
|
|
129
|
+
cp output/*.tar.zst r2-upload/ 2>/dev/null || true
|
|
130
|
+
cp output/*.sha256sum r2-upload/ 2>/dev/null || true
|
|
131
|
+
ls -lh r2-upload/
|
|
132
|
+
|
|
133
|
+
- name: Upload binaries to R2 (versioned)
|
|
134
|
+
uses: ryand56/r2-upload-action@latest
|
|
135
|
+
with:
|
|
136
|
+
r2-account-id: ${{ secrets.R2_ACCOUNT_ID }}
|
|
137
|
+
r2-access-key-id: ${{ secrets.R2_ACCESS_KEY_ID }}
|
|
138
|
+
r2-secret-access-key: ${{ secrets.R2_SECRET_ACCESS_KEY }}
|
|
139
|
+
r2-bucket: ${{ secrets.R2_BUCKET_NAME }}
|
|
140
|
+
source-dir: r2-upload
|
|
141
|
+
destination-dir: releases/${{ needs.create-release.outputs.version }}
|
|
142
|
+
multipart-size: 100
|
|
143
|
+
max-retries: 5
|
|
144
|
+
|
|
145
|
+
- name: Upload binaries to R2 (latest)
|
|
146
|
+
uses: ryand56/r2-upload-action@latest
|
|
147
|
+
with:
|
|
148
|
+
r2-account-id: ${{ secrets.R2_ACCOUNT_ID }}
|
|
149
|
+
r2-access-key-id: ${{ secrets.R2_ACCESS_KEY_ID }}
|
|
150
|
+
r2-secret-access-key: ${{ secrets.R2_SECRET_ACCESS_KEY }}
|
|
151
|
+
r2-bucket: ${{ secrets.R2_BUCKET_NAME }}
|
|
152
|
+
source-dir: r2-upload
|
|
153
|
+
destination-dir: releases/latest
|
|
154
|
+
multipart-size: 100
|
|
155
|
+
max-retries: 5
|
|
156
|
+
|
|
157
|
+
upload-installer:
|
|
158
|
+
name: Upload Installer to R2
|
|
159
|
+
needs: create-release
|
|
160
|
+
runs-on: ubuntu-latest
|
|
161
|
+
steps:
|
|
162
|
+
- uses: actions/checkout@v6
|
|
163
|
+
|
|
164
|
+
- name: Create version metadata file
|
|
165
|
+
run: echo "${{ needs.create-release.outputs.version }}" > latest-version.txt
|
|
166
|
+
|
|
167
|
+
- name: Prepare installer files
|
|
168
|
+
run: |
|
|
169
|
+
mkdir -p installer-files
|
|
170
|
+
cp install.sh installer-files/
|
|
171
|
+
cp latest-version.txt installer-files/
|
|
172
|
+
|
|
173
|
+
- name: Upload installer files to R2
|
|
174
|
+
uses: ryand56/r2-upload-action@latest
|
|
175
|
+
with:
|
|
176
|
+
r2-account-id: ${{ secrets.R2_ACCOUNT_ID }}
|
|
177
|
+
r2-access-key-id: ${{ secrets.R2_ACCESS_KEY_ID }}
|
|
178
|
+
r2-secret-access-key: ${{ secrets.R2_SECRET_ACCESS_KEY }}
|
|
179
|
+
r2-bucket: ${{ secrets.R2_BUCKET_NAME }}
|
|
180
|
+
source-dir: installer-files
|
|
181
|
+
destination-dir: .
|
|
182
|
+
max-retries: 5
|
runqd-0.4.10/.gitignore
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
3
|
+
rev: v6.0.0
|
|
4
|
+
hooks:
|
|
5
|
+
- id: fix-byte-order-marker
|
|
6
|
+
- id: check-case-conflict
|
|
7
|
+
- id: check-merge-conflict
|
|
8
|
+
- id: check-symlinks
|
|
9
|
+
- id: check-yaml
|
|
10
|
+
- id: end-of-file-fixer
|
|
11
|
+
- id: mixed-line-ending
|
|
12
|
+
- id: trailing-whitespace
|
|
13
|
+
- repo: https://github.com/doublify/pre-commit-rust
|
|
14
|
+
rev: v1.0
|
|
15
|
+
hooks:
|
|
16
|
+
- id: fmt
|
|
17
|
+
- id: clippy
|
|
18
|
+
- id: cargo-check
|
|
19
|
+
- repo: https://github.com/bnjbvr/cargo-machete
|
|
20
|
+
rev: v0.9.1
|
|
21
|
+
hooks:
|
|
22
|
+
- id: cargo-machete
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to gflow will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- **Job Time Limits**: Comprehensive support for setting maximum runtime for jobs
|
|
12
|
+
- New `--time` / `-t` parameter for `gbatch` command
|
|
13
|
+
- Support for multiple time formats: `HH:MM:SS`, `MM:SS`, and `MM` (minutes)
|
|
14
|
+
- Automatic timeout enforcement by scheduler (checked every 5 seconds)
|
|
15
|
+
- New `Timeout` job state (`TO`) for jobs that exceed their time limit
|
|
16
|
+
- Time limit persistence across daemon restarts
|
|
17
|
+
- `TIMELIMIT` column in `gqueue` output showing job time limits or "UNLIMITED"
|
|
18
|
+
- Graceful job termination via SIGINT when time limit is exceeded
|
|
19
|
+
- Time limits can be specified in job scripts via `# GFLOW --time` directive
|
|
20
|
+
- CLI time limits override script time limits for flexibility
|
|
21
|
+
|
|
22
|
+
- **Automatic Output Logging**: Real-time job output capture via tmux pipe-pane
|
|
23
|
+
- All job output automatically logged to `~/.local/share/gflow/logs/<job_id>.log`
|
|
24
|
+
- Pipe-pane enabled immediately after job session creation
|
|
25
|
+
- Output captured from job start to completion/termination
|
|
26
|
+
- Works for successful, failed, cancelled, and timed-out jobs
|
|
27
|
+
- Automatic cleanup of pipe-pane when sessions are terminated
|
|
28
|
+
- Log directory automatically created if it doesn't exist
|
|
29
|
+
- **Dependency Shorthand**: `gbatch --depends-on` now accepts `@` (last) and `@~N` (Nth from the end) to reference recent submissions without copying job IDs
|
|
30
|
+
|
|
31
|
+
### Changed
|
|
32
|
+
- **Job State Transitions**: Updated to support new `Timeout` state
|
|
33
|
+
- Added `Running → Timeout` transition for time limit violations
|
|
34
|
+
- Updated state transition validation logic
|
|
35
|
+
- Enhanced timestamp handling for timeout state
|
|
36
|
+
|
|
37
|
+
- **Scheduler Logic**: Enhanced job monitoring and lifecycle management
|
|
38
|
+
- Added timeout checking in main scheduler loop
|
|
39
|
+
- Graceful job termination for timed-out jobs (Ctrl-C before state transition)
|
|
40
|
+
- Improved separation of zombie job detection and timeout enforcement
|
|
41
|
+
- Better error logging for timeout-related operations
|
|
42
|
+
|
|
43
|
+
- **Job Display**: Enhanced `gqueue` output options
|
|
44
|
+
- New `TIMELIMIT` field showing job time limits
|
|
45
|
+
- Time limits displayed in standardized `HH:MM:SS` or `D-HH:MM:SS` format
|
|
46
|
+
- "UNLIMITED" displayed for jobs without time limits
|
|
47
|
+
- Added `Timeout` to grouped job state displays
|
|
48
|
+
|
|
49
|
+
### Fixed
|
|
50
|
+
- Pattern matching in `gcancel` to handle new `Timeout` state
|
|
51
|
+
- Job struct serialization to properly persist time limit information
|
|
52
|
+
- Tmux session cleanup to ensure pipe-pane is disabled before session termination
|
|
53
|
+
|
|
54
|
+
### Documentation
|
|
55
|
+
- Added comprehensive `docs/TIME_LIMITS.md` with usage guide, examples, and FAQ
|
|
56
|
+
- Added `docs/QUICK_REFERENCE.md` with command cheat sheet
|
|
57
|
+
- Added `docs/README.md` as documentation index
|
|
58
|
+
- Updated main `README.md` to mention time limits and output logging features
|
|
59
|
+
- Included examples of time limit usage in various scenarios
|
|
60
|
+
- Added troubleshooting guide for timeout-related issues
|
|
61
|
+
|
|
62
|
+
## [0.3.12] - Previous Release
|
|
63
|
+
|
|
64
|
+
### Features
|
|
65
|
+
- Daemon-based job scheduling with persistent state
|
|
66
|
+
- GPU resource management via NVML
|
|
67
|
+
- Job dependencies with `--depends-on`
|
|
68
|
+
- Job arrays with `--array` parameter
|
|
69
|
+
- Priority-based scheduling
|
|
70
|
+
- Tmux integration for job execution
|
|
71
|
+
- RESTful HTTP API for job management
|
|
72
|
+
- Command-line tools: `gflowd`, `ginfo`, `gbatch`, `gqueue`, `gcancel`
|
|
73
|
+
|
|
74
|
+
### Job Management
|
|
75
|
+
- Job state tracking (Queued, Running, Finished, Failed, Cancelled)
|
|
76
|
+
- Job queue filtering and sorting
|
|
77
|
+
- Job dependency visualization with tree view
|
|
78
|
+
- Grouped job display by state
|
|
79
|
+
- Conda environment support
|
|
80
|
+
|
|
81
|
+
### System
|
|
82
|
+
- State persistence to JSON file
|
|
83
|
+
- Zombie job detection and cleanup
|
|
84
|
+
- Automatic GPU assignment and tracking
|
|
85
|
+
- Job logs stored per job ID
|
|
86
|
+
|
|
87
|
+
---
|
|
88
|
+
|
|
89
|
+
## Version History Notes
|
|
90
|
+
|
|
91
|
+
### Time Limit Feature Implementation Details
|
|
92
|
+
|
|
93
|
+
The time limit feature was implemented with the following components:
|
|
94
|
+
|
|
95
|
+
**Core Changes** (`src/core/job.rs`):
|
|
96
|
+
- Added `time_limit: Option<Duration>` field to `Job` struct
|
|
97
|
+
- Added `Timeout` variant to `JobState` enum
|
|
98
|
+
- Implemented `has_exceeded_time_limit()` method for runtime checking
|
|
99
|
+
- Updated `JobBuilder` to support time limit configuration
|
|
100
|
+
|
|
101
|
+
**CLI Integration** (`src/bin/gbatch/`):
|
|
102
|
+
- Added `--time` argument parsing in `cli.rs`
|
|
103
|
+
- Implemented flexible time format parser in `commands/add.rs`
|
|
104
|
+
- Support for script-embedded time limits
|
|
105
|
+
- CLI arguments override script directives
|
|
106
|
+
|
|
107
|
+
**Scheduler Enhancement** (`src/bin/gflowd/scheduler.rs`):
|
|
108
|
+
- Timeout checking integrated into main scheduler loop (5-second interval)
|
|
109
|
+
- Graceful termination via `send_ctrl_c()` before state transition
|
|
110
|
+
- Separate handling of timeout vs zombie job detection
|
|
111
|
+
- Atomic state updates with proper error handling
|
|
112
|
+
|
|
113
|
+
**Display Updates** (`src/bin/gqueue/commands/list.rs`):
|
|
114
|
+
- Added `TIMELIMIT` field to output format options
|
|
115
|
+
- Implemented `format_duration()` helper for consistent time display
|
|
116
|
+
- Updated grouped display to include `Timeout` state
|
|
117
|
+
- Dynamic column width calculation for time limit field
|
|
118
|
+
|
|
119
|
+
**Output Logging** (`src/tmux.rs`, `src/bin/gflowd/executor.rs`):
|
|
120
|
+
- Added `enable_pipe_pane()`, `disable_pipe_pane()`, and `is_pipe_pane_active()` methods
|
|
121
|
+
- Automatic pipe-pane setup during job execution
|
|
122
|
+
- Log file creation with proper directory handling
|
|
123
|
+
- Cleanup integration in session termination
|
|
124
|
+
|
|
125
|
+
### Migration Notes
|
|
126
|
+
|
|
127
|
+
- **Breaking Changes**: None. Time limits are optional and backward compatible.
|
|
128
|
+
- **State File**: Existing state files are compatible. Jobs without time limits show as "UNLIMITED".
|
|
129
|
+
- **Log Files**: Existing jobs will not have historical logs, but new jobs will automatically log output.
|
|
130
|
+
- **API**: Job submission API extended with optional `time_limit` field.
|
|
131
|
+
|
|
132
|
+
### Known Limitations
|
|
133
|
+
|
|
134
|
+
- Time limit enforcement accuracy: ±5 seconds (scheduler check interval)
|
|
135
|
+
- Single number in time format is always interpreted as minutes
|
|
136
|
+
- No built-in checkpoint/resume mechanism (users must implement)
|
|
137
|
+
- Cannot modify time limit after job submission
|
|
138
|
+
- Timeout state is terminal (cannot be restarted)
|
|
139
|
+
|
|
140
|
+
### Future Enhancements
|
|
141
|
+
|
|
142
|
+
Potential improvements for consideration:
|
|
143
|
+
- Configurable scheduler check interval for better timeout accuracy
|
|
144
|
+
- `REMAINING` column showing time left before timeout
|
|
145
|
+
- Job time limit modification for queued jobs
|
|
146
|
+
- Time limit warnings (e.g., 5 minutes before timeout)
|
|
147
|
+
- Historical time usage statistics
|
|
148
|
+
- Automatic checkpoint/resume on timeout
|
|
149
|
+
- Per-user or per-project default time limits
|
|
150
|
+
|
|
151
|
+
---
|
|
152
|
+
|
|
153
|
+
## Links
|
|
154
|
+
|
|
155
|
+
- [GitHub Repository](https://github.com/AndPuQing/gflow)
|
|
156
|
+
- [Issue Tracker](https://github.com/AndPuQing/gflow/issues)
|
|
157
|
+
- [Documentation](./docs/)
|
|
158
|
+
- [Crates.io](https://crates.io/crates/gflow)
|