Skip to content

Commit ed865f7

Browse files
authored
Optimize workflow triggers and block dependabot (#3651)
* Optimize workflow triggers and block dependabot - Add synchronize/reopened to PR triggers for continuous validation - Use specific path triggers (crates/** instead of **) - Preserve all caching (Cargo, Go, npm, gradle) - Keep timeout-minutes for stability * Fix clippy * More clippy! * Local clippy not catching these is frustrating.. * Remove obsolete lib_types rename in Android build - lib_types is bundled into lib_uniffi * Attempt another fix * Build bindings for both
1 parent bc53c2b commit ed865f7

File tree

14 files changed

+83
-15
lines changed

14 files changed

+83
-15
lines changed

.github/workflows/ci-nym-vpn-android.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-android
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- "nym-vpn-core/crates/**"
88
- "nym-vpn-core/Cargo.toml"

.github/workflows/ci-nym-vpn-app-js.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-app-js
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- ".github/workflows/ci-nym-vpn-app-js.yml"
88
- "nym-vpn-app/**"

.github/workflows/ci-nym-vpn-app-rust.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-app-rust
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- ".github/workflows/ci-nym-vpn-app-rust.yml"
88
- "nym-vpn-app/src-tauri/**"

.github/workflows/ci-nym-vpn-core-android.yml

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-core-android
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- "nym-vpn-core/crates/**"
88
- "nym-vpn-core/Cargo.toml"
@@ -60,6 +60,27 @@ jobs:
6060
version: "21.12" # 3.21.12: the version on ubuntu 24.04. Don't change this!
6161
repo-token: ${{ secrets.GITHUB_TOKEN }}
6262

63+
- name: Cache Cargo registry
64+
uses: actions/cache@v4
65+
with:
66+
path: |
67+
~/.cargo/bin/
68+
~/.cargo/registry/index/
69+
~/.cargo/registry/cache/
70+
~/.cargo/git/db/
71+
key: ${{ runner.os }}-cargo-${{ hashFiles('nym-vpn-core/Cargo.lock') }}
72+
restore-keys: |
73+
${{ runner.os }}-cargo-
74+
75+
- name: Cache Cargo build
76+
uses: actions/cache@v4
77+
with:
78+
path: nym-vpn-core/target/
79+
key: ${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}-${{ hashFiles('nym-vpn-core/**/*.rs') }}
80+
restore-keys: |
81+
${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}-
82+
${{ runner.os }}-cargo-build-
83+
6384
- name: Download artifacts
6485
uses: actions/download-artifact@v5
6586
with:

.github/workflows/ci-nym-vpn-core-cargo-deny.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: ci-nym-vpn-core-cargo-deny
22
on:
33
pull_request:
4-
types: [opened]
4+
types: [opened, synchronize, reopened]
55
paths:
66
- "nym-vpn-core/**/Cargo.lock"
77
- "nym-vpn-core/**/Cargo.toml"

.github/workflows/ci-nym-vpn-core-ios.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-core-ios
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- "nym-vpn-core/crates/**"
88
- "nym-vpn-core/Cargo.toml"

.github/workflows/ci-nym-vpn-core-linux.yml

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-core-linux
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- "nym-vpn-core/crates/**"
88
- "nym-vpn-core/Cargo.toml"
@@ -41,6 +41,27 @@ jobs:
4141
version: "21.12" # 3.21.12: the version on ubuntu 24.04. Don't change this!
4242
repo-token: ${{ secrets.GITHUB_TOKEN }}
4343

44+
- name: Cache Cargo registry
45+
uses: actions/cache@v4
46+
with:
47+
path: |
48+
~/.cargo/bin/
49+
~/.cargo/registry/index/
50+
~/.cargo/registry/cache/
51+
~/.cargo/git/db/
52+
key: ${{ runner.os }}-cargo-${{ hashFiles('nym-vpn-core/Cargo.lock') }}
53+
restore-keys: |
54+
${{ runner.os }}-cargo-
55+
56+
- name: Cache Cargo build
57+
uses: actions/cache@v4
58+
with:
59+
path: nym-vpn-core/target/
60+
key: ${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}-${{ hashFiles('nym-vpn-core/**/*.rs') }}
61+
restore-keys: |
62+
${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}-
63+
${{ runner.os }}-cargo-build-
64+
4465
# To avoid running out of disk space, skip generating debug symbols
4566
- name: Set debug to false
4667
working-directory: nym-vpn-core

.github/workflows/ci-nym-vpn-core-macos.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-core-macos
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- "nym-vpn-core/crates/**"
88
- "nym-vpn-core/Cargo.toml"

.github/workflows/ci-nym-vpn-core-windows.yml

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: ci-nym-vpn-core-windows
22

33
on:
44
pull_request:
5-
types: [opened]
5+
types: [opened, synchronize, reopened]
66
paths:
77
- "nym-vpn-core/crates/**"
88
- "nym-vpn-core/Cargo.toml"
@@ -59,6 +59,27 @@ jobs:
5959
version: "21.12" # 3.21.12: the version on ubuntu 24.04. Don't change this!
6060
repo-token: ${{ secrets.GITHUB_TOKEN }}
6161

62+
- name: Cache Cargo registry
63+
uses: actions/cache@v4
64+
with:
65+
path: |
66+
~/.cargo/bin/
67+
~/.cargo/registry/index/
68+
~/.cargo/registry/cache/
69+
~/.cargo/git/db/
70+
key: ${{ runner.os }}-cargo-${{ hashFiles('nym-vpn-core/Cargo.lock') }}
71+
restore-keys: |
72+
${{ runner.os }}-cargo-
73+
74+
- name: Cache Cargo build
75+
uses: actions/cache@v4
76+
with:
77+
path: nym-vpn-core/target/
78+
key: ${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}-${{ hashFiles('nym-vpn-core/**/*.rs') }}
79+
restore-keys: |
80+
${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}-
81+
${{ runner.os }}-cargo-build-
82+
6283
- name: Install GNU make
6384
run: |
6485
winget list GnuWin32.Make || winget install --disable-interactivity --accept-source-agreements --id GnuWin32.Make

nym-vpn-app/src-tauri/src/grpc/account_error.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ impl From<VpnApiError> for BackendError {
1717
VpnApiErrorDetail::Timeout(_) => BackendError::internal("nym-vpn-api timeout", None),
1818
VpnApiErrorDetail::StatusCode(code) => BackendError::internal_with_detail(
1919
"nym-vpn-api error",
20-
format!("nym-vpn-api returned: {code}"),
20+
format!("nym-vpn-api returned: {code:?}"),
2121
),
2222
VpnApiErrorDetail::Response(response) => BackendError::from(response),
2323
}

0 commit comments

Comments
 (0)