diff --git a/.github/scripts/use-cla-approved-github-bot.sh b/.github/scripts/use-cla-approved-github-bot.sh index a4c68b0e308e..bcbd71b7f5f1 100755 --- a/.github/scripts/use-cla-approved-github-bot.sh +++ b/.github/scripts/use-cla-approved-github-bot.sh @@ -1,4 +1,4 @@ #!/bin/bash -e -git config user.name opentelemetrybot -git config user.email 107717825+opentelemetrybot@users.noreply.github.com +git config user.name '${{ steps.app-token.outputs.app-slug }}[bot]' +git config user.email '${{ steps.get-user-id.outputs.user-id }}+${{ steps.app-token.outputs.app-slug }}[bot]@users.noreply.github.com' diff --git a/.github/workflows/backport.yml b/.github/workflows/backport.yml index e1828cf17020..9e19337206a5 100644 --- a/.github/workflows/backport.yml +++ b/.github/workflows/backport.yml @@ -15,25 +15,32 @@ jobs: contents: write # for Git to git push runs-on: ubuntu-latest steps: - - run: | - if [[ ! $GITHUB_REF_NAME =~ ^release/v[0-9]+\.[0-9]+\.x$ ]]; then - echo this workflow should only be run against release branches - exit 1 - fi - - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: # history is needed to run git cherry-pick below fetch-depth: 0 - - name: Use CLA approved github bot - run: .github/scripts/use-cla-approved-github-bot.sh + - uses: actions/create-github-app-token@136412a57a7081aa63c935a2cc2918f76c34f514 # v1.11.2 + id: app-token + with: + app-id: ${{ secrets.OPENTELEMETRY_BASIC_AUTOMATION_CLIENT_ID }} + private-key: ${{ secrets.OPENTELEMETRY_BASIC_AUTOMATION_PRIVATE_KEY }} + + - name: Use CLA approved author + env: + GH_TOKEN: ${{ steps.app-token.outputs.token }} + run: | + user_name=${{ steps.app-token.outputs.app-slug }}[bot] + user_id=$(gh api "/users/$user_name" --jq .id) + + git config user.name "$user_name" + git config user.email "${user_id}+${user_name}@users.noreply.github.com" - name: Create pull request env: NUMBER: ${{ github.event.inputs.number }} # not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows - GH_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }} + GH_TOKEN: ${{ steps.app-token.outputs.token }} run: | commit=$(gh pr view $NUMBER --json mergeCommit --jq .mergeCommit.oid) title=$(gh pr view $NUMBER --json title --jq .title) diff --git a/conventions/build.gradle.kts b/conventions/build.gradle.kts index 7b8f4cf7b755..6fe6609e5c28 100644 --- a/conventions/build.gradle.kts +++ b/conventions/build.gradle.kts @@ -74,5 +74,5 @@ dependencies { testImplementation(enforcedPlatform("org.junit:junit-bom:5.11.4")) testImplementation("org.junit.jupiter:junit-jupiter-api") testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine") - testImplementation("org.assertj:assertj-core:3.27.2") + testImplementation("org.assertj:assertj-core:3.27.3") } diff --git a/dependencyManagement/build.gradle.kts b/dependencyManagement/build.gradle.kts index 71a7c0c17667..95409c73d39a 100644 --- a/dependencyManagement/build.gradle.kts +++ b/dependencyManagement/build.gradle.kts @@ -105,7 +105,7 @@ val DEPENDENCIES = listOf( "io.opentelemetry.contrib:opentelemetry-baggage-processor:${otelContribVersion}", "io.opentelemetry.proto:opentelemetry-proto:1.5.0-alpha", "io.opentelemetry:opentelemetry-extension-annotations:1.18.0", // deprecated, no longer part of bom - "org.assertj:assertj-core:3.27.2", + "org.assertj:assertj-core:3.27.3", "org.awaitility:awaitility:4.2.2", "com.google.code.findbugs:annotations:3.0.1u2", "com.google.code.findbugs:jsr305:3.0.2", diff --git a/examples/distro/gradle/instrumentation.gradle b/examples/distro/gradle/instrumentation.gradle index 9399c3d452a1..4f1d672f158f 100644 --- a/examples/distro/gradle/instrumentation.gradle +++ b/examples/distro/gradle/instrumentation.gradle @@ -25,7 +25,7 @@ dependencies { // test dependencies testImplementation("io.opentelemetry.javaagent:opentelemetry-testing-common") testImplementation("io.opentelemetry:opentelemetry-sdk-testing") - testImplementation("org.assertj:assertj-core:3.27.2") + testImplementation("org.assertj:assertj-core:3.27.3") add("codegen", "io.opentelemetry.javaagent:opentelemetry-javaagent-tooling:${versions.opentelemetryJavaagentAlpha}") add("muzzleBootstrap", "io.opentelemetry.instrumentation:opentelemetry-instrumentation-annotations-support:${versions.opentelemetryJavaagentAlpha}") diff --git a/gradle-plugins/build.gradle.kts b/gradle-plugins/build.gradle.kts index 0d4a191a62c1..db55b9027954 100644 --- a/gradle-plugins/build.gradle.kts +++ b/gradle-plugins/build.gradle.kts @@ -42,7 +42,7 @@ dependencies { implementation("com.gradleup.shadow:shadow-gradle-plugin:8.3.5") - testImplementation("org.assertj:assertj-core:3.27.2") + testImplementation("org.assertj:assertj-core:3.27.3") testImplementation(enforcedPlatform("org.junit:junit-bom:5.11.4")) testImplementation("org.junit.jupiter:junit-jupiter-api")