Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
OlivierHecart authored Jun 9, 2023
1 parent 33d28cf commit 1de6e2f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 7 deletions.
22 changes: 16 additions & 6 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,15 @@ on:
runtests:
description: 'run tests'
type: boolean
dockerhub:
description: 'publish to dockerhub'
type: boolean
doc:
description: 'generate doc'
type: boolean
features:
description: 'build with specified features (comma separated, no space)'
type: string

jobs:
checks:
Expand All @@ -43,7 +52,7 @@ jobs:
uses: actions-rs/cargo@v1
with:
command: clippy
args: --all-targets -- -D warnings
args: --all-targets --features=${{ github.event.inputs.features}} -- -D warnings
- name: Clippy unstable check
uses: actions-rs/cargo@v1
with:
Expand Down Expand Up @@ -111,19 +120,20 @@ jobs:
uses: actions-rs/cargo@v1
with:
command: nextest
args: run --release --verbose
args: run --release --features=${{ github.event.inputs.features}} --verbose
env:
ASYNC_STD_THREAD_COUNT: 4
- name: Run doctests
uses: actions-rs/cargo@v1
with:
command: test
args: --release --doc
args: --release --features=${{ github.event.inputs.features}} --doc
env:
ASYNC_STD_THREAD_COUNT: 4

doc:
name: Doc generation
if: ${{ !(github.event.inputs.doc == 'false') }}
needs: checks
runs-on: ubuntu-latest
steps:
Expand All @@ -138,7 +148,7 @@ jobs:
uses: actions-rs/cargo@v1
with:
command: doc
args: --no-deps
args: --no-deps --features=${{ github.event.inputs.features}}

builds:
name: Build for ${{ matrix.job.target }} on ${{ matrix.job.os }}
Expand Down Expand Up @@ -232,7 +242,7 @@ jobs:
with:
use-cross: ${{ matrix.job.use-cross }}
command: build
args: --release --bins --lib --target=${{ matrix.job.target }}
args: --release --bins --lib --features=${{ github.event.inputs.features}} --target=${{ matrix.job.target }}

- name: Debian package - zenohd
if: contains(matrix.job.target, '-linux-gnu')
Expand Down Expand Up @@ -357,7 +367,7 @@ jobs:

docker:
name: Docker build and push
if: ${{ !failure() }}
if: ${{ !(github.event.inputs.dockerhub == 'false') && !failure() }}
needs: [checks, builds, tests, doc]
runs-on: ubuntu-latest
steps:
Expand Down
2 changes: 1 addition & 1 deletion zenoh/src/net/runtime/adminspace.rs
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ fn router_data(context: &AdminContext, query: Query) {
});
#[cfg(feature = "stats")]
{
let stats = crate::prelude::Parameters::decode(selector)
let stats = crate::prelude::Parameters::decode(&query.selector())
.any(|(k, v)| k.as_ref() == "_stats" && v != "false");
if stats {
json.as_object_mut().unwrap().insert(
Expand Down

0 comments on commit 1de6e2f

Please sign in to comment.