Skip to content

Commit e5f0095

Browse files
committed
fix(ci): fix MinIO startup and rustdoc warnings
- Remove GitHub Actions services for MinIO (doesn't support custom commands) - Use docker run with explicit 'server /data' command instead - Fix rustdoc warning: wrap Result<T> in backticks in retry.rs
1 parent 95134b3 commit e5f0095

3 files changed

Lines changed: 29 additions & 33 deletions

File tree

.github/workflows/ci.yml

Lines changed: 27 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -77,30 +77,26 @@ jobs:
7777
integration:
7878
name: Integration Tests
7979
runs-on: ubuntu-latest
80-
services:
81-
minio:
82-
image: minio/minio:latest
83-
ports:
84-
- 9000:9000
85-
- 9001:9001
86-
env:
87-
MINIO_ROOT_USER: minioadmin
88-
MINIO_ROOT_PASSWORD: minioadmin
89-
options: >-
90-
--health-cmd "curl -f http://localhost:9000/minio/health/live"
91-
--health-interval 10s
92-
--health-timeout 5s
93-
--health-retries 5
9480
steps:
9581
- uses: actions/checkout@v6
9682
- uses: dtolnay/rust-toolchain@stable
9783
- uses: Swatinem/rust-cache@v2
84+
- name: Start MinIO
85+
run: |
86+
docker run -d --name minio \
87+
-p 9000:9000 -p 9001:9001 \
88+
-e MINIO_ROOT_USER=minioadmin \
89+
-e MINIO_ROOT_PASSWORD=minioadmin \
90+
quay.io/minio/minio:latest \
91+
server /data --console-address :9001
9892
- name: Wait for MinIO
9993
run: |
10094
for i in {1..30}; do
10195
curl -sf http://localhost:9000/minio/health/live && break
102-
sleep 1
96+
echo "Waiting for MinIO... ($i/30)"
97+
sleep 2
10398
done
99+
curl -sf http://localhost:9000/minio/health/live || exit 1
104100
- name: Run integration tests
105101
run: cargo test --workspace --features integration
106102
env:
@@ -112,23 +108,26 @@ jobs:
112108
golden:
113109
name: Golden Tests
114110
runs-on: ubuntu-latest
115-
services:
116-
minio:
117-
image: minio/minio:latest
118-
ports:
119-
- 9000:9000
120-
env:
121-
MINIO_ROOT_USER: minioadmin
122-
MINIO_ROOT_PASSWORD: minioadmin
123-
options: >-
124-
--health-cmd "curl -f http://localhost:9000/minio/health/live"
125-
--health-interval 10s
126-
--health-timeout 5s
127-
--health-retries 5
128111
steps:
129112
- uses: actions/checkout@v6
130113
- uses: dtolnay/rust-toolchain@stable
131114
- uses: Swatinem/rust-cache@v2
115+
- name: Start MinIO
116+
run: |
117+
docker run -d --name minio \
118+
-p 9000:9000 \
119+
-e MINIO_ROOT_USER=minioadmin \
120+
-e MINIO_ROOT_PASSWORD=minioadmin \
121+
quay.io/minio/minio:latest \
122+
server /data
123+
- name: Wait for MinIO
124+
run: |
125+
for i in {1..30}; do
126+
curl -sf http://localhost:9000/minio/health/live && break
127+
echo "Waiting for MinIO... ($i/30)"
128+
sleep 2
129+
done
130+
curl -sf http://localhost:9000/minio/health/live || exit 1
132131
- name: Run golden tests
133132
run: cargo test --workspace --features golden
134133
env:
@@ -180,4 +179,3 @@ jobs:
180179
- uses: Swatinem/rust-cache@v2
181180
- name: Build with MSRV
182181
run: cargo build --workspace
183-

crates/cli/src/commands/find.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -226,9 +226,7 @@ fn parse_size(s: &str) -> Result<i64, String> {
226226
}
227227

228228
// Find where the numeric part ends
229-
let suffix_start = s
230-
.find(|c: char| c.is_ascii_alphabetic())
231-
.unwrap_or(s.len());
229+
let suffix_start = s.find(|c: char| c.is_ascii_alphabetic()).unwrap_or(s.len());
232230

233231
let num_str = &s[..suffix_start];
234232
let suffix = &s[suffix_start..];

crates/core/src/retry.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use crate::error::{Error, Result};
1111
///
1212
/// # Arguments
1313
/// * `config` - Retry configuration
14-
/// * `operation` - Async closure that returns Result<T>
14+
/// * `operation` - Async closure that returns `Result<T>`
1515
/// * `is_retryable` - Closure that determines if an error should trigger retry
1616
///
1717
/// # Example

0 commit comments

Comments
 (0)