Skip to content

Commit

Permalink
Merge branch 'main' into renovate/nuget-armonik-utils
Browse files Browse the repository at this point in the history
  • Loading branch information
ngruelaneo authored Dec 10, 2024
2 parents 8d3d992 + e0f61b9 commit e3827bd
Show file tree
Hide file tree
Showing 266 changed files with 23,025 additions and 15,034 deletions.
29 changes: 29 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Motivation

[Include the reason behind these changes and any relevant context.]

# Description

[Provide a detailled explanation of the modifications you have made. Link any related issues.]

# Testing

[When applicable, detail the testing you have performed to ensure that these changes function as intended. Include information about any added tests.]

# Impact

[Discuss the impact of your modifications on ArmoniK. This might include effects on performance, configuration, documentation, new dependencies, or changes in behaviour.]

# Additional Information

[Any additional information that reviewers should be aware of.]

# Checklist

- [ ] My code adheres to the coding and style guidelines of the project.
- [ ] I have performed a self-review of my code.
- [ ] I have commented my code, particularly in hard-to-understand areas.
- [ ] I have made corresponding changes to the documentation.
- [ ] I have thoroughly tested my modifications and added tests when necessary.
- [ ] Tests pass locally and in the CI.
- [ ] I have assessed the performance impact of my modifications.
124 changes: 58 additions & 66 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
fetch-depth: 0

- run: npm i -g pnpm @antfu/ni

- name: Setup Node.js
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
with:
node-version: 18.x
cache: pnpm
Expand All @@ -37,14 +37,14 @@ jobs:
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
ref: ${{ github.ref }}
fetch-depth: 0
submodules: true

- name: Install .NET Core
uses: actions/setup-dotnet@4d6c8fcf3c8f7a60068d26b594648e99df24cee3 # v4
uses: actions/setup-dotnet@6bd8b7f7774af54e05809fcc5431931b3eb1ddee # v4
with:
dotnet-version: 6.x

Expand Down Expand Up @@ -83,7 +83,7 @@ jobs:
run:
working-directory: packages/python
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
fetch-depth: 0

Expand Down Expand Up @@ -132,7 +132,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
ref: ${{ github.ref }}
fetch-depth: 0
Expand Down Expand Up @@ -163,7 +163,7 @@ jobs:
if: ${{ failure() && steps.check-diff.conclusion == 'failure' }}
run: |
git diff > patch-cpp.diff
- uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4
- uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a
if: ${{ failure() && steps.check-diff.conclusion == 'failure' }}
with:
name: patch-cpp
Expand All @@ -175,7 +175,7 @@ jobs:
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
ref: ${{ github.ref }}
fetch-depth: 0
Expand All @@ -184,16 +184,53 @@ jobs:
- name: Check Diff
run: docker run --rm --volume "$(pwd)/Protos/V1:/workspace" --workdir /workspace bufbuild/buf:1.8.0 format -d --exit-code

format-rust:
name: Format and check Rust
strategy:
fail-fast: false
matrix:
toolchain:
- stable
- nightly
runs-on: ubuntu-latest
defaults:
run:
working-directory: packages/rust/armonik
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
fetch-depth: 0
- uses: taiki-e/install-action@v2
with:
tool: protoc,sccache
- name: Install toolchain
if: ${{ !contains(matrix.toolchain, 'nightly') }}
uses: dtolnay/rust-toolchain@stable
with:
components: rust-src,rust-docs,rustfmt,clippy
- name: Build
run: |
cargo build --all --locked
- name: Format
run: |
cargo fmt --all --check
- name: Doc
run: |
RUSTDOCFLAGS="-Dwarnings" cargo doc
- name: Clippy
run: |
cargo clippy --all --no-deps -- -Dwarnings -Dunused-crate-dependencies
lint-js:
name: Lint JS
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
fetch-depth: 0
- run: npm install -g [email protected]
- run: corepack enable
- uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
with:
node-version: 20
cache: pnpm
Expand All @@ -209,14 +246,14 @@ jobs:
run:
working-directory: packages/web
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
fetch-depth: 0

- run: npm i -g pnpm @antfu/ni

- name: Setup Node.js
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
with:
node-version: 18.x
cache: pnpm
Expand All @@ -240,14 +277,14 @@ jobs:
run:
working-directory: packages/angular
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
fetch-depth: 0

- run: npm i -g pnpm @antfu/ni

- name: Setup Node.js
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
with:
node-version: 18.x
cache: pnpm
Expand All @@ -264,55 +301,6 @@ jobs:
- name: Build
run: nr build

build-test-python:
name: Build and test Python
runs-on: ubuntu-latest
defaults:
run:
working-directory: packages/python
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 0

- name: pip update and add build package
run: bash proto2python.sh ~/pyvenv

- name: Install dependencies
run: pip install "$(echo pkg/armonik*.whl)[tests]"

- name: Install .NET Core
uses: actions/setup-dotnet@4d6c8fcf3c8f7a60068d26b594648e99df24cee3 # v4
with:
dotnet-version: 6.x

- name: Start Mock server
run: |
cd ../csharp/ArmoniK.Api.Mock
nohup dotnet run > /dev/null 2>&1 &
sleep 60
- name: Run tests
run: python -m pytest tests --cov=armonik --cov-config=.coveragerc --cov-report=term-missing --cov-report xml:coverage.xml --cov-report html:coverage_report

- name: Get Cover
uses: orgoro/coverage@6d7a2607343d2abeab89ef40b54ec9785134e313
with:
coverageFile: packages/python/coverage.xml
token: ${{ secrets.GITHUB_TOKEN }}

- name: Archive code coverage results html
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4
with:
name: code-coverage-report-html
path: packages/python/coverage_report

- name: Archive code coverage results xml
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4
with:
name: code-coverage-report-xml
path: packages/python/coverage.xml

build-cpp-packages:
strategy:
fail-fast: false
Expand All @@ -322,7 +310,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
ref: ${{ github.ref }}

Expand All @@ -331,7 +319,7 @@ jobs:
cd packages/cpp/tools/packaging
./make-${{ matrix.type }}.sh
- name: Publish package as artefact
uses: actions/upload-artifact@65d862660abb392b8c4a3d1195a2108db131dd05
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a
with:
if-no-files-found: error
path: packages/cpp/tools/packaging/*.${{ matrix.type }}
Expand All @@ -345,7 +333,7 @@ jobs:
working-directory: packages/java
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
fetch-depth: 0
- name: Set up java 17
Expand All @@ -354,5 +342,9 @@ jobs:
distribution: oracle
java-version: 17
cache: maven
gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE
- name: Build the package
run: mvn clean install -DskipTests
env:
MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_SIGNING_KEY_PASSWORD }}
14 changes: 7 additions & 7 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4

- run: npm i -g pnpm @antfu/ni

- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
with:
node-version: '18'
cache: pnpm
Expand All @@ -37,7 +37,7 @@ jobs:
# This will be used to avoid the use of the docker image to generate the documentation if the proto files have not changed
- name: Cache Generated Docs from Protos
id: proto-cache
uses: actions/cache@13aacd865c20de90d75de3b17ebe84f7a17d57d2 # v4
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4
with:
path: .docs/content/api/*.md
key: proto-v1-${{ hashFiles('Protos/V1/**.proto') }}
Expand Down Expand Up @@ -65,20 +65,20 @@ jobs:
needs: [generate-proto-docs]
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4

# Restore API proto documentation
- name: Cache Generated Docs from Protos
id: proto-cache
uses: actions/cache@13aacd865c20de90d75de3b17ebe84f7a17d57d2 # v4
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4
with:
path: .docs/content/api/*.md
key: proto-v1-${{ hashFiles('Protos/V1/**.proto') }}

- run: npm i -g pnpm @antfu/ni

- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4
with:
node-version: '18'
cache: pnpm
Expand Down Expand Up @@ -110,4 +110,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@decdde0ac072f6dcbe43649d82d9c635fff5b4e4 # v4
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4
Loading

0 comments on commit e3827bd

Please sign in to comment.