Skip to content

Commit efeec66

Browse files
authored
First round of CI tweaks (#527)
There's a lot more that can (and should) be done, but this cleanup is a start.
2 parents 780081b + cff2f0b commit efeec66

File tree

2 files changed

+24
-45
lines changed

2 files changed

+24
-45
lines changed

.github/workflows/release.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: CD
22

33
on:
44
push:
5-
tags: [ '*' ]
5+
tags: ["*"]
66
env:
77
RUST_BACKTRACE: 1
88
jobs:
@@ -17,7 +17,7 @@ jobs:
1717
- name: publish crates
1818
uses: katyo/publish-crates@v2
1919
with:
20-
path: './'
20+
path: "./"
2121
args: --no-verify --allow-dirty --all-features
2222
registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}
2323
ignore-unpublished-changes: true

.github/workflows/rust.yaml

Lines changed: 22 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ name: CI
22

33
on:
44
push:
5-
branches: [ main ]
5+
branches: [main]
66
pull_request:
7-
branches: [ main ]
7+
branches: [main]
88
env:
99
RUST_BACKTRACE: 1
1010
jobs:
@@ -14,15 +14,16 @@ jobs:
1414
fail-fast: true
1515
matrix:
1616
include:
17-
- { target: x86_64-pc-windows-msvc, os: windows-latest, duckdb: libduckdb-windows-amd64.zip }
18-
- { target: x86_64-unknown-linux-gnu, os: ubuntu-latest, duckdb: libduckdb-linux-amd64.zip }
19-
#- { target: x86_64-apple-darwin, os: macos-latest }
20-
#- {
21-
#target: x86_64-pc-windows-gnu,
22-
#os: windows-latest,
23-
#host: -x86_64-pc-windows-gnu,
24-
#}
25-
17+
- {
18+
target: x86_64-pc-windows-msvc,
19+
os: windows-latest,
20+
duckdb: libduckdb-windows-amd64.zip,
21+
}
22+
- {
23+
target: x86_64-unknown-linux-gnu,
24+
os: ubuntu-latest,
25+
duckdb: libduckdb-linux-amd64.zip,
26+
}
2627
runs-on: ${{ matrix.os }}
2728
steps:
2829
- uses: actions/checkout@v2
@@ -58,6 +59,15 @@ jobs:
5859
LD_LIBRARY_PATH: ${{ github.workspace }}/libduckdb
5960
run: cargo clippy --all-targets --all-features --locked -- -D warnings
6061

62+
- name: Dry-run release of crates
63+
if: matrix.os == 'ubuntu-latest'
64+
uses: katyo/publish-crates@v2
65+
with:
66+
path: "./"
67+
args: --allow-dirty --all-features
68+
dry-run: true
69+
ignore-unpublished-changes: true
70+
6171
# For windows
6272
- name: Windows extract duckdb
6373
if: matrix.os == 'windows-latest'
@@ -94,35 +104,16 @@ jobs:
94104
DUCKDB_INCLUDE_DIR: ${{ github.workspace }}/libduckdb
95105
LD_LIBRARY_PATH: ${{ github.workspace }}/libduckdb
96106

97-
Windows:
98-
name: Windows build from source
99-
needs: test
100-
runs-on: windows-latest
101-
steps:
102-
- uses: actions/checkout@v2
103-
- uses: actions/cache@v3
104-
with:
105-
path: ~/.cargo/registry/index
106-
key: index-${{ runner.os }}-${{ github.run_number }}
107-
restore-keys: |
108-
index-${{ runner.os }}-
109-
- uses: actions-rust-lang/setup-rust-toolchain@v1
110-
with:
111-
target: x86_64-pc-windows-msvc
112-
113-
- run: cargo install cargo-examples
114-
115107
Sanitizer:
116108
name: Address Sanitizer
117-
needs: test
118109
runs-on: ubuntu-latest
119110
steps:
120111
- uses: actions/checkout@v2
121112
# Need nightly rust.
122113
- uses: actions-rust-lang/setup-rust-toolchain@v1
123114
with:
124115
toolchain: nightly
125-
components: 'rust-src'
116+
components: "rust-src"
126117
# Install LLVM tools
127118
- name: Install LLVM
128119
run: |
@@ -132,21 +123,9 @@ jobs:
132123
RUSTFLAGS: -Zsanitizer=address -C debuginfo=0
133124
RUSTDOCFLAGS: -Zsanitizer=address
134125
ASAN_OPTIONS: "detect_stack_use_after_return=1:detect_leaks=1:symbolize=1"
135-
# Work around https://github.com/rust-lang/rust/issues/59125 by
136-
# disabling backtraces. In an ideal world we'd probably suppress the
137-
# leak sanitization, but we don't care about backtraces here, so long
138-
# as the other tests have them.
139-
RUST_BACKTRACE: "0"
140126
# We cannot run "modern-full" with asan as the chrono feature will auto-load relase binaries of
141127
# the ICU-extension, which are not built with ASAN and will cause a crash.
142128
run: |
143129
export ASAN_SYMBOLIZER_PATH=$(which llvm-symbolizer)
144130
echo $ASAN_SYMBOLIZER_PATH
145131
cargo -Z build-std test --features "serde_json url r2d2 uuid polars extensions-full" --target x86_64-unknown-linux-gnu --package duckdb
146-
- name: publish crates --dry-run
147-
uses: katyo/publish-crates@v2
148-
with:
149-
path: './'
150-
args: --allow-dirty --all-features
151-
dry-run: true
152-
ignore-unpublished-changes: true

0 commit comments

Comments
 (0)