Skip to content

Commit 27f836b

Browse files
authored
Merge branch 'apache:master' into master
2 parents d9ddb2f + e44f1ad commit 27f836b

File tree

171 files changed

+11889
-4034
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

171 files changed

+11889
-4034
lines changed

.github/ISSUE_TEMPLATE/question.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
name: Question
3+
about: Ask question about this project
4+
title: ''
5+
labels: question
6+
assignees: ''
7+
8+
---
9+
10+
**Which part is this question about**
11+
Is it code base, library api, documentation or some other part?
12+
13+
**Describe your question**
14+
A clear and concise description of what the question is.
15+
16+
**Additional context**
17+
Add any other context about the problem here.

.github/workflows/dev.yml

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -32,25 +32,13 @@ jobs:
3232
name: Release Audit Tool (RAT)
3333
runs-on: ubuntu-latest
3434
steps:
35-
- name: Checkout Arrow
36-
uses: actions/checkout@v2
37-
with:
38-
repository: apache/arrow
39-
submodules: true
40-
fetch-depth: 0
41-
- name: Checkout Arrow Rust
42-
uses: actions/checkout@v2
43-
with:
44-
path: rust
45-
fetch-depth: 0
35+
- uses: actions/checkout@v2
4636
- name: Setup Python
4737
uses: actions/setup-python@v1
4838
with:
4939
python-version: 3.8
50-
- name: Setup Archery
51-
run: pip install -e dev/archery[lint]
52-
- name: Lint
53-
run: archery lint --rat
40+
- name: Audit licenses
41+
run: ./dev/release/run-rat.sh .
5442

5543
prettier:
5644
name: Use prettier to check formatting of documents

.github/workflows/dev_pr/labeler.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,6 @@ arrow-flight:
2323

2424
parquet:
2525
- parquet/**/*
26+
27+
parquet-derive:
28+
- parquet_derive/**/*

.github/workflows/integration.yml

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ on:
2323

2424
jobs:
2525

26-
docker:
26+
integration:
2727
name: Integration Test
2828
runs-on: ubuntu-latest
2929
steps:
@@ -46,3 +46,51 @@ jobs:
4646
run: pip install -e dev/archery[docker]
4747
- name: Execute Docker Build
4848
run: archery docker run -e ARCHERY_INTEGRATION_WITH_RUST=1 conda-integration
49+
50+
# test FFI against the C-Data interface exposed by pyarrow
51+
pyarrow-integration-test:
52+
name: Test Pyarrow C Data Interface
53+
runs-on: ubuntu-latest
54+
strategy:
55+
matrix:
56+
rust: [stable]
57+
steps:
58+
- uses: actions/checkout@v2
59+
with:
60+
submodules: true
61+
- name: Setup Rust toolchain
62+
run: |
63+
rustup toolchain install ${{ matrix.rust }}
64+
rustup default ${{ matrix.rust }}
65+
rustup component add rustfmt clippy
66+
- name: Cache Cargo
67+
uses: actions/cache@v2
68+
with:
69+
path: /home/runner/.cargo
70+
key: cargo-maturin-cache-
71+
- name: Cache Rust dependencies
72+
uses: actions/cache@v2
73+
with:
74+
path: /home/runner/target
75+
# this key is not equal because maturin uses different compilation flags.
76+
key: ${{ runner.os }}-${{ matrix.arch }}-target-maturin-cache-${{ matrix.rust }}-
77+
- uses: actions/setup-python@v2
78+
with:
79+
python-version: '3.7'
80+
- name: Upgrade pip and setuptools
81+
run: pip install --upgrade pip setuptools wheel virtualenv
82+
- name: Create virtualenv and install dependencies
83+
run: |
84+
virtualenv venv
85+
source venv/bin/activate
86+
pip install maturin toml pytest pytz pyarrow>=5.0
87+
- name: Run tests
88+
env:
89+
CARGO_HOME: "/home/runner/.cargo"
90+
CARGO_TARGET_DIR: "/home/runner/target"
91+
run: |
92+
source venv/bin/activate
93+
pushd arrow-pyarrow-integration-testing
94+
maturin develop
95+
pytest -v .
96+
popd

.github/workflows/miri.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
strategy:
3131
matrix:
3232
arch: [amd64]
33-
rust: [nightly-2021-03-24]
33+
rust: [nightly-2021-07-04]
3434
steps:
3535
- uses: actions/checkout@v2
3636
with:
@@ -57,4 +57,4 @@ jobs:
5757
cargo clean
5858
# Currently only the arrow crate is tested with miri
5959
# IO related tests and some unsupported tests are skipped
60-
cargo miri test -p arrow -- --skip csv --skip ipc --skip json || true
60+
cargo miri test -p arrow -- --skip csv --skip ipc --skip json

.github/workflows/rust.yml

Lines changed: 47 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
# these represent dependencies downloaded by cargo
4747
# and thus do not depend on the OS, arch nor rust version.
4848
path: /github/home/.cargo
49-
key: cargo-cache-
49+
key: cargo-cache2-
5050
- name: Cache Rust dependencies
5151
uses: actions/cache@v2
5252
with:
@@ -91,7 +91,7 @@ jobs:
9191
with:
9292
path: /github/home/.cargo
9393
# this key equals the ones on `linux-build-lib` for re-use
94-
key: cargo-cache-
94+
key: cargo-cache2-
9595
- name: Cache Rust dependencies
9696
uses: actions/cache@v2
9797
with:
@@ -118,6 +118,11 @@ jobs:
118118
cargo run --example dynamic_types
119119
cargo run --example read_csv
120120
cargo run --example read_csv_infer_schema
121+
# Exit arrow directory
122+
cd ..
123+
(cd parquet && cargo check --no-default-features)
124+
(cd arrow && cargo check --no-default-features)
125+
(cd arrow-flight && cargo check --no-default-features)
121126
122127
# test the --features "simd" of the arrow crate. This requires nightly.
123128
linux-test-simd:
@@ -126,7 +131,7 @@ jobs:
126131
strategy:
127132
matrix:
128133
arch: [amd64]
129-
rust: [nightly-2021-03-24]
134+
rust: [nightly]
130135
container:
131136
image: ${{ matrix.arch }}/rust
132137
env:
@@ -143,7 +148,7 @@ jobs:
143148
with:
144149
path: /github/home/.cargo
145150
# this key equals the ones on `linux-build-lib` for re-use
146-
key: cargo-cache-
151+
key: cargo-cache2-
147152
- name: Cache Rust dependencies
148153
uses: actions/cache@v2
149154
with:
@@ -161,6 +166,12 @@ jobs:
161166
export CARGO_TARGET_DIR="/github/home/target"
162167
cd arrow
163168
cargo test --features "simd"
169+
- name: Check new project build with simd features
170+
run: |
171+
export CARGO_HOME="/github/home/.cargo"
172+
export CARGO_TARGET_DIR="/github/home/target"
173+
cd arrow/test/dependency/simd
174+
cargo check
164175
165176
windows-and-macos:
166177
name: Test on ${{ matrix.os }} Rust ${{ matrix.rust }}
@@ -212,7 +223,7 @@ jobs:
212223
with:
213224
path: /github/home/.cargo
214225
# this key equals the ones on `linux-build-lib` for re-use
215-
key: cargo-cache-
226+
key: cargo-cache2-
216227
- name: Cache Rust dependencies
217228
uses: actions/cache@v2
218229
with:
@@ -228,7 +239,7 @@ jobs:
228239
run: |
229240
export CARGO_HOME="/github/home/.cargo"
230241
export CARGO_TARGET_DIR="/github/home/target"
231-
cargo clippy --all-targets --workspace -- -D warnings -A clippy::redundant_field_names
242+
cargo clippy --features test_common --all-targets --workspace -- -D warnings -A clippy::redundant_field_names
232243
233244
lint:
234245
name: Lint
@@ -244,6 +255,7 @@ jobs:
244255
rustup component add rustfmt
245256
- name: Run
246257
run: cargo fmt --all -- --check
258+
247259
coverage:
248260
name: Coverage
249261
runs-on: ubuntu-latest
@@ -275,68 +287,20 @@ jobs:
275287
export ARROW_TEST_DATA=$(pwd)/testing/data
276288
export PARQUET_TEST_DATA=$(pwd)/parquet-testing/data
277289
278-
# 2020-11-15: There is a cargo-tarpaulin regression in 0.17.0
279-
# see https://github.com/xd009642/tarpaulin/issues/618
280-
cargo install --version 0.16.0 cargo-tarpaulin
281-
cargo tarpaulin --out Xml
290+
cargo install --version 0.18.2 cargo-tarpaulin
291+
cargo tarpaulin --all --out Xml
282292
- name: Report coverage
283293
continue-on-error: true
284294
run: bash <(curl -s https://codecov.io/bash)
285295

286-
# test FFI against the C-Data interface exposed by pyarrow
287-
pyarrow-integration-test:
288-
name: Test Pyarrow C Data Interface
289-
runs-on: ubuntu-latest
290-
strategy:
291-
matrix:
292-
rust: [stable]
293-
steps:
294-
- uses: actions/checkout@v2
295-
with:
296-
submodules: true
297-
- name: Setup Rust toolchain
298-
run: |
299-
rustup toolchain install ${{ matrix.rust }}
300-
rustup default ${{ matrix.rust }}
301-
rustup component add rustfmt clippy
302-
- name: Cache Cargo
303-
uses: actions/cache@v2
304-
with:
305-
path: /home/runner/.cargo
306-
key: cargo-maturin-cache-
307-
- name: Cache Rust dependencies
308-
uses: actions/cache@v2
309-
with:
310-
path: /home/runner/target
311-
# this key is not equal because maturin uses different compilation flags.
312-
key: ${{ runner.os }}-${{ matrix.arch }}-target-maturin-cache-${{ matrix.rust }}-
313-
- uses: actions/setup-python@v2
314-
with:
315-
python-version: '3.7'
316-
- name: Install Python dependencies
317-
run: python -m pip install --upgrade pip setuptools wheel
318-
- name: Run tests
319-
run: |
320-
export CARGO_HOME="/home/runner/.cargo"
321-
export CARGO_TARGET_DIR="/home/runner/target"
322-
323-
cd arrow-pyarrow-integration-testing
324-
325-
python -m venv venv
326-
source venv/bin/activate
327-
328-
pip install maturin==0.8.2 toml==0.10.1 pyarrow==1.0.0
329-
maturin develop
330-
python -m unittest discover tests
331-
332296
# test the arrow crate builds against wasm32 in stable rust
333297
wasm32-build:
334298
name: Build wasm32 on AMD64 Rust ${{ matrix.rust }}
335299
runs-on: ubuntu-latest
336300
strategy:
337301
matrix:
338302
arch: [amd64]
339-
rust: [nightly-2021-03-24]
303+
rust: [nightly]
340304
container:
341305
image: ${{ matrix.arch }}/rust
342306
env:
@@ -354,7 +318,7 @@ jobs:
354318
with:
355319
path: /github/home/.cargo
356320
# this key equals the ones on `linux-build-lib` for re-use
357-
key: cargo-cache-
321+
key: cargo-cache2-
358322
- name: Cache Rust dependencies
359323
uses: actions/cache@v2
360324
with:
@@ -366,16 +330,18 @@ jobs:
366330
rustup override set ${{ matrix.rust }}
367331
rustup component add rustfmt
368332
rustup target add wasm32-unknown-unknown
333+
rustup target add wasm32-wasi
369334
- name: Build arrow crate
370335
run: |
371336
export CARGO_HOME="/github/home/.cargo"
372337
export CARGO_TARGET_DIR="/github/home/target"
373338
cd arrow
374-
cargo build --target wasm32-unknown-unknown
339+
cargo build --no-default-features --features=csv,ipc,simd --target wasm32-unknown-unknown
340+
cargo build --no-default-features --features=csv,ipc,simd --target wasm32-wasi
375341
376-
# test the projects can build without default features
342+
# test builds with various feature flag combinations outside the main workspace
377343
default-build:
378-
name: Check No Defaults on AMD64 Rust ${{ matrix.rust }}
344+
name: Feature Flag Builds ${{ matrix.rust }}
379345
runs-on: ubuntu-latest
380346
strategy:
381347
matrix:
@@ -384,34 +350,42 @@ jobs:
384350
container:
385351
image: ${{ matrix.arch }}/rust
386352
env:
387-
# Disable full debug symbol generation to speed up CI build and keep memory down
388-
# "1" means line tables only, which is useful for panic tracebacks.
389-
RUSTFLAGS: "-C debuginfo=1"
390-
ARROW_TEST_DATA: /__w/arrow-rs/arrow-rs/testing/data
391-
PARQUET_TEST_DATA: /__w/arrow/arrow/parquet-testing/data
353+
# Disable debug symbol generation to speed up CI build and keep memory down
354+
RUSTFLAGS: "-C debuginfo=0"
392355
steps:
393356
- uses: actions/checkout@v2
394-
with:
395-
submodules: true
396357
- name: Cache Cargo
397358
uses: actions/cache@v2
398359
with:
399360
path: /github/home/.cargo
400361
# this key equals the ones on `linux-build-lib` for re-use
401-
key: cargo-cache-
362+
key: cargo-cache2-
402363
- name: Cache Rust dependencies
403364
uses: actions/cache@v2
404365
with:
405366
path: /github/home/target
406-
key: ${{ runner.os }}-${{ matrix.arch }}-target-wasm32-cache-${{ matrix.rust }}
367+
# this key equals the ones on `linux-build-lib` for re-use
368+
key: ${{ runner.os }}-${{ matrix.arch }}-target-cache-${{ matrix.rust }}
407369
- name: Setup Rust toolchain
408370
run: |
409371
rustup toolchain install ${{ matrix.rust }}
410372
rustup override set ${{ matrix.rust }}
411373
rustup component add rustfmt
412-
- name: Build arrow crate
374+
- name: Arrow Build with default features
413375
run: |
414376
export CARGO_HOME="/github/home/.cargo"
415377
export CARGO_TARGET_DIR="/github/home/target"
416-
cd arrow
417-
cargo check --all-targets --no-default-features
378+
cd arrow/test/dependency/default-features
379+
cargo check
380+
- name: Arrow Build with default-features=false
381+
run: |
382+
export CARGO_HOME="/github/home/.cargo"
383+
export CARGO_TARGET_DIR="/github/home/target"
384+
cd arrow/test/dependency/no-default-features
385+
cargo check
386+
- name: Parquet Derive build with default-features
387+
run: |
388+
export CARGO_HOME="/github/home/.cargo"
389+
export CARGO_TARGET_DIR="/github/home/target"
390+
cd parquet_derive/test/dependency/default-features
391+
cargo check

.github_changelog_generator

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,4 @@ add-sections={"documentation":{"prefix":"**Documentation updates:**","labels":["
2727
# so that the component is shown associated with the issue
2828
issue-line-labels=arrow,parquet,arrow-flight
2929
exclude-labels=development-process,invalid
30+
breaking_labels=api-change

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,5 @@ rusty-tags.vi
66
.idea/
77
.vscode
88
venv/*
9+
# created by doctests
10+
parquet/data.parquet

0 commit comments

Comments
 (0)