This is an automated email from the ASF dual-hosted git repository.

yhu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git


The following commit(s) were added to refs/heads/master by this push:
     new 50392e97e8a Add Python PVR Flink action (#28222)
50392e97e8a is described below

commit 50392e97e8ae96ab4157524079034f5bd548be84
Author: Vitaly Terentyev <vitaly.terent...@akvelon.com>
AuthorDate: Thu Aug 31 21:40:36 2023 +0400

    Add Python PVR Flink action (#28222)
    
    * Add Python PVR Flink action
    
    * Add main tag
---
 .github/workflows/README.md                        |   1 +
 .../workflows/beam_PreCommit_Python_PVR_Flink.yml  | 116 +++++++++++++++++++++
 2 files changed, 117 insertions(+)

diff --git a/.github/workflows/README.md b/.github/workflows/README.md
index c10eebd7afd..9f2ffea1049 100644
--- a/.github/workflows/README.md
+++ b/.github/workflows/README.md
@@ -226,6 +226,7 @@ Please note that jobs with matrix need to have matrix 
element in the comment. Ex
 | [ PreCommit Python Formatter 
](https://github.com/apache/beam/actions/workflows/beam_PreCommit_PythonFormatter.yml)
 | N/A | `Run PythonFormatter PreCommit`| 
[![.github/workflows/beam_PreCommit_PythonFormatter.yml](https://github.com/apache/beam/actions/workflows/beam_PreCommit_PythonFormatter.yml/badge.svg?event=schedule)](https://github.com/apache/beam/actions/workflows/beam_PreCommit_PythonFormatter.yml)
 |
 | [ PreCommit Python 
Integration](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Integration.yml)
 | ['3.8','3.11'] | `Run Python_Integration PreCommit (matrix_element)` | 
[![.github/workflows/beam_PreCommit_Python_Integration.yml](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Integration.yml/badge.svg?event=schedule)](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Integration.yml)
 |
 | [ PreCommit Python Lint 
](https://github.com/apache/beam/actions/workflows/beam_PreCommit_PythonLint.yml)
 | N/A | `Run PythonLint PreCommit` | 
[![.github/workflows/beam_PreCommit_PythonLint.yml](https://github.com/apache/beam/actions/workflows/beam_PreCommit_PythonLint.yml/badge.svg?event=schedule)](https://github.com/apache/beam/actions/workflows/beam_PreCommit_PythonLint.yml)
 |
+| [ PreCommit Python PVR Flink 
](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_PVR_Flink.yml)
 | N/A | `Run Python_PVR_Flink PreCommit` | 
[![.github/workflows/beam_PreCommit_Python_PVR_Flink.yml](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_PVR_Flink.yml/badge.svg?event=schedule)](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_PVR_Flink.yml)
 |
 | [ PreCommit Python Runners 
](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Runners.yml)
 | ['3.8','3.9','3.10','3.11'] | `Run Python_Runners PreCommit 
(matrix_element)`| 
[![.github/workflows/beam_PreCommit_Python_Runners.yml](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Runners.yml/badge.svg?event=schedule)](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Runners.yml)
 |
 | [ PreCommit Python Transforms 
](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Transforms.yml)
 | ['3.8','3.9','3.10','3.11'] | `Run Python_Transforms PreCommit 
(matrix_element)`| 
[![.github/workflows/beam_PreCommit_Python_Transforms.yml](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Transforms.yml/badge.svg?event=schedule)](https://github.com/apache/beam/actions/workflows/beam_PreCommit_Python_Transforms.yml)
 |
 | [ PreCommit RAT 
](https://github.com/apache/beam/actions/workflows/beam_PreCommit_RAT.yml) | 
N/A | `Run RAT PreCommit` | 
[![.github/workflows/beam_PreCommit_RAT.yml](https://github.com/apache/beam/actions/workflows/beam_PreCommit_RAT.yml/badge.svg?event=schedule)](https://github.com/apache/beam/actions/workflows/beam_PreCommit_RAT.yml)
 |
diff --git a/.github/workflows/beam_PreCommit_Python_PVR_Flink.yml 
b/.github/workflows/beam_PreCommit_Python_PVR_Flink.yml
new file mode 100644
index 00000000000..38ca40f3606
--- /dev/null
+++ b/.github/workflows/beam_PreCommit_Python_PVR_Flink.yml
@@ -0,0 +1,116 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+name: PreCommit Python PVR Flink
+
+on:
+  pull_request_target:
+    branches: ['master', 'release-*']
+    paths:
+      - 'model/**'
+      - 'sdks/python/**'
+      - 'release/**'
+      - 'sdks/java/io/kafka/**'
+      - 'runners/core-construction-java/**'
+      - 'runners/core-java/**'
+      - 'runners/extensions-java/**'
+      - 'runners/flink/**'
+      - 'runners/java-fn-execution/**'
+      - 'runners/reference/**'
+  issue_comment:
+    types: [created]
+  push:
+    tags: ['v*']
+    branches: ['master', 'release-*']
+    paths:
+      - 'model/**'
+      - 'sdks/python/**'
+      - 'release/**'
+      - 'sdks/java/io/kafka/**'
+      - 'runners/core-construction-java/**'
+      - 'runners/core-java/**'
+      - 'runners/extensions-java/**'
+      - 'runners/flink/**'
+      - 'runners/java-fn-execution/**'
+      - 'runners/reference/**'
+      - '.github/workflows/beam_PreCommit_Python_PVR_Flink.yml'
+  schedule:
+    - cron: '* */6 * * *'
+  workflow_dispatch:
+
+#Setting explicit permissions for the action to avoid the default permissions 
which are `write-all` in case of pull_request_target event
+permissions:
+  actions: write
+  pull-requests: read
+  checks: read
+  contents: read
+  deployments: read
+  id-token: none
+  issues: read
+  discussions: read
+  packages: read
+  pages: read
+  repository-projects: read
+  security-events: read
+  statuses: read
+
+# This allows a subsequently queued workflow run to interrupt previous runs
+concurrency:
+  group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || 
github.sha || github.head_ref || github.ref }}-${{ github.event.sender.login 
}}-${{ github.event.schedule }}'
+  cancel-in-progress: true
+
+jobs:
+  beam_PreCommit_Python_PVR_Flink:
+    name: ${{ matrix.job_name }} (${{ matrix.job_phrase }})
+    strategy:
+      matrix:
+        job_name: ["beam_PreCommit_Python_PVR_Flink"]
+        job_phrase: ["Run Python_PVR_Flink PreCommit"]
+    timeout-minutes: 120
+    if: |
+      github.event_name == 'push' || 
+      github.event_name == 'pull_request_target' || 
+      github.event_name == 'schedule' ||
+      github.event_name == 'workflow_dispatch' ||
+      github.event.comment.body == 'Run Python_PVR_Flink PreCommit'
+    runs-on: [self-hosted, ubuntu-20.04, main]
+    steps:
+      - uses: actions/checkout@v3
+      - name: Setup repository
+        uses: ./.github/actions/setup-action
+        with:
+          comment_phrase: ${{ matrix.job_phrase }}
+          github_token: ${{ secrets.GITHUB_TOKEN }}
+          github_job: ${{ matrix.job_name }} (${{ matrix.job_phrase }})
+      - name: Install Python
+        uses: actions/setup-python@v4
+        with:
+          python-version: 3.11
+      - name: Configure passenv for tox
+        run: |
+          sed -i '/^\[testenv\]$/,/^\[/ 
s/^passenv=TERM/passenv=TERM,CLOUDSDK_CONFIG/' sdks/python/tox.ini
+      - name: run Python PVR Flink PreCommit script
+        uses: ./.github/actions/gradle-command-self-hosted-action
+        env:
+          CLOUDSDK_CONFIG: ${{ env.KUBELET_GCLOUD_CONFIG_PATH}}
+        with:
+          gradle-command: 
:sdks:python:test-suites:portable:py311:flinkValidatesRunner
+          arguments: |
+            -PpythonVersion=3.11 \
+      - name: Archive code coverage results
+        uses: actions/upload-artifact@v3
+        with:
+          name: python-code-coverage-report
+          path: '**/pytest*.xml'

Reply via email to