Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Maturing linux test #23

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
186 changes: 0 additions & 186 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,142 +10,6 @@ env:
RUSTDOCFLAGS: -D warnings

jobs:
check_all_features:
name: Check --all-features
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: sudo apt-get update && sudo apt-get install libgtk-3-dev
- uses: actions-rs/cargo@v1
with:
command: check
args: --all-features --locked

check_no_features:
name: Check --no-default-features
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: sudo apt-get update && sudo apt-get install libgtk-3-dev
- uses: actions-rs/cargo@v1
with:
command: check
args: --no-default-features --features __ci --lib

check_wasm:
name: Check wasm32
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: sudo apt-get update && sudo apt-get install libgtk-3-dev
- run: rustup target add wasm32-unknown-unknown
- uses: actions-rs/cargo@v1
with:
command: check
args: -p re_viewer --all-features --lib --target wasm32-unknown-unknown

test:
name: Test Suite
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: sudo apt-get install libgtk-3-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libspeechd-dev libxkbcommon-dev libssl-dev
- uses: actions-rs/cargo@v1
with:
command: test
args: --all-features --lib

fmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: sudo apt-get install libgtk-3-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libspeechd-dev libxkbcommon-dev libssl-dev
- run: rustup component add rustfmt
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check

cranky:
name: cargo cranky
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: sudo apt-get update && sudo apt-get install libgtk-3-dev
- run: cargo install cargo-cranky
- uses: actions-rs/cargo@v1
with:
command: cranky
args: --workspace --all-targets --all-features -- -D warnings

cargo-deny:
name: cargo deny
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: cargo install cargo-deny
- run: cargo deny check

# For some reason this causes weird problems:
# https://github.com/rerun-io/rerun/runs/6271778805?check_suite_focus=true
# Error: -03 10:39:38 [ERROR] `cargo metadata` exited with an error: info: syncing channel updates for '1.60.0-x86_64-unknown-linux-musl'
# failed to read `/github/rerun/web_server/Cargo.toml`
# cargo-deny:
# runs-on: ubuntu-20.04
# steps:
# - uses: actions/checkout@v2
# - uses: EmbarkStudios/cargo-deny-action@v1

wasm_bindgen:
name: wasm-bindgen
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.62.0
override: true
- run: rustup target add wasm32-unknown-unknown
- run: ./crates/re_viewer/setup_web.sh
- run: ./crates/re_viewer/wasm_bindgen_check.sh

maturin-linux:
name: Maturin Linux
runs-on: ubuntu-latest
Expand All @@ -162,53 +26,3 @@ jobs:
with:
name: wheels
path: dist

maturin-windows:
name: Maturin Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- uses: messense/maturin-action@v1
with:
maturin-version: "0.12.20"
command: build
args: -m crates/re_sdk_python/Cargo.toml --release --no-sdist -o dist
- name: Upload wheels
uses: actions/upload-artifact@v2
with:
name: wheels
path: dist

maturin-macos:
name: Maturin MacOS
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: messense/maturin-action@v1
with:
maturin-version: "0.12.20"
command: build
args: -m crates/re_sdk_python/Cargo.toml --release --no-sdist -o dist --universal2
- name: Upload wheels
uses: actions/upload-artifact@v2
with:
name: wheels
path: dist

maturin-release:
name: Maturin Release
runs-on: ubuntu-latest
if: "startsWith(github.ref, 'refs/tags/')"
needs: [maturin-macos, maturin-windows, maturin-linux]
steps:
- uses: actions/download-artifact@v2
with:
name: wheels
- name: Publish to PyPI
uses: messense/maturin-action@v1
env:
MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
with:
maturin-version: "0.12.20"
command: upload
args: -m crates/re_sdk_python/Cargo.toml --skip-existing *
7 changes: 5 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions crates/re_sdk_python/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,10 @@ default = ["extension-module"]
[dependencies]
re_log_types = { path = "../re_log_types" }
re_sdk_comms = { path = "../re_sdk_comms", features = ["client"] }
re_viewer = { path = "../re_viewer", optional = true }

bytemuck = { version = "1.11", features = ["extern_crate_alloc"] }
itertools = "0.10"
nohash-hasher = "0.2"
numpy = "0.16"
once_cell = "1.12"
Expand Down
1 change: 1 addition & 0 deletions crates/re_sdk_python/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
maturin
numpy
opencv-python