From 68d72eb51238ead788895b0c462b4aa361bf7683 Mon Sep 17 00:00:00 2001 From: Pun Chaixanien Date: Mon, 6 Nov 2023 20:44:41 -0500 Subject: [PATCH 01/11] workflows folder --- .github/workflows/github-actions-demo.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 .github/workflows/github-actions-demo.yml diff --git a/.github/workflows/github-actions-demo.yml b/.github/workflows/github-actions-demo.yml new file mode 100644 index 000000000..e69de29bb From 488f536e282b65b196bd34ab0a82023dac56d13f Mon Sep 17 00:00:00 2001 From: Pun2341 <67458426+Pun2341@users.noreply.github.com> Date: Mon, 6 Nov 2023 20:48:46 -0500 Subject: [PATCH 02/11] Update github-actions-demo.yml --- .github/workflows/github-actions-demo.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/github-actions-demo.yml b/.github/workflows/github-actions-demo.yml index e69de29bb..0eb7126e9 100644 --- a/.github/workflows/github-actions-demo.yml +++ b/.github/workflows/github-actions-demo.yml @@ -0,0 +1,18 @@ +name: GitHub Actions Demo +run-name: ${{ github.actor }} is testing out GitHub Actions 🚀 +on: [push] +jobs: + Explore-GitHub-Actions: + runs-on: ubuntu-latest + steps: + - run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event." + - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by GitHub!" + - run: echo "🔎 The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}." + - name: Check out repository code + uses: actions/checkout@v4 + - run: echo "💡 The ${{ github.repository }} repository has been cloned to the runner." + - run: echo "🖥️ The workflow is now ready to test your code on the runner." + - name: List files in the repository + run: | + ls ${{ github.workspace }} + - run: echo "🍏 This job's status is ${{ job.status }}." From d9a01f983f592b7001698485f0563e51e1f69c97 Mon Sep 17 00:00:00 2001 From: Pun2341 <67458426+Pun2341@users.noreply.github.com> Date: Mon, 6 Nov 2023 20:55:13 -0500 Subject: [PATCH 03/11] Create pylint.yml --- .github/workflows/pylint.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/workflows/pylint.yml diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml new file mode 100644 index 000000000..3f1d0b502 --- /dev/null +++ b/.github/workflows/pylint.yml @@ -0,0 +1,26 @@ +name: Pylint + +on: [push, pull_request] + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: ["3.8"] + steps: + - uses: actions/checkout@v3 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install pylint + - name: Analysing the code with pylint + run: | + pylint $(git ls-files '*.py') \ + --disable C0116 \ + --disable E1101 \ + --fail-under 7.0 From dac003904957aa35c25b315b9ec3bffd4391224f Mon Sep 17 00:00:00 2001 From: Pun Chaixanien Date: Mon, 6 Nov 2023 20:59:33 -0500 Subject: [PATCH 04/11] testing push --- test-folder/testfile.py | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 test-folder/testfile.py diff --git a/test-folder/testfile.py b/test-folder/testfile.py new file mode 100644 index 000000000..d5a5bdbac --- /dev/null +++ b/test-folder/testfile.py @@ -0,0 +1,6 @@ +def testFunction(): + print("Hello World!") + + +def print_really_long_string(): + print("This is a really long string that will be printed on multiple lines.") From f7d1601c3087a2e26ca580fae4a0f3f78ae8fa89 Mon Sep 17 00:00:00 2001 From: Pun2341 <67458426+Pun2341@users.noreply.github.com> Date: Sat, 11 Nov 2023 11:32:42 -0500 Subject: [PATCH 05/11] Update pylint.yml - disabled some checks and ignore yolov5 --- .github/workflows/pylint.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index 3f1d0b502..84d19c98c 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.8"] + python-version: ["3.9.13"] steps: - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} @@ -21,6 +21,10 @@ jobs: - name: Analysing the code with pylint run: | pylint $(git ls-files '*.py') \ - --disable C0116 \ - --disable E1101 \ - --fail-under 7.0 + --disable C0114 \ # Missing Module Docstring + --disable C0115 \ # Missing Class Docstring + --disable C0116 \ # Missing Function Docstring + --disable E1101 \ # Instance of .. has no .. member' + --disable E0401 \ # Unable to import .. + --fail-under 7.0 \ + --ignore yolov5 From 7328fde3dffb582f5942c53e9113d1808b132bdc Mon Sep 17 00:00:00 2001 From: Pun2341 <67458426+Pun2341@users.noreply.github.com> Date: Sat, 11 Nov 2023 11:59:20 -0500 Subject: [PATCH 06/11] Update pylint.yml - fix ignore yolov5 --- .github/workflows/pylint.yml | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index 84d19c98c..75a7643be 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -1,6 +1,6 @@ name: Pylint -on: [push, pull_request] +on: [push] jobs: build: @@ -21,10 +21,15 @@ jobs: - name: Analysing the code with pylint run: | pylint $(git ls-files '*.py') \ - --disable C0114 \ # Missing Module Docstring - --disable C0115 \ # Missing Class Docstring - --disable C0116 \ # Missing Function Docstring - --disable E1101 \ # Instance of .. has no .. member' - --disable E0401 \ # Unable to import .. + # Missing Module Docstring + --disable C0114 \ + # Missing Class Docstring + --disable C0115 \ + # Missing Function Docstring + --disable C0116 \ + # Instance of .. has no .. member + --disable E1101 \ + # Unable to import .. + --disable E0401 \ --fail-under 7.0 \ - --ignore yolov5 + --ignore-paths re.compile("^/ml-model/yolov5") From 0b781fa57d51cf653024389dace6c3f819e9afd3 Mon Sep 17 00:00:00 2001 From: Pun Chaixanien Date: Sat, 11 Nov 2023 12:01:29 -0500 Subject: [PATCH 07/11] removed github actions demo --- .github/workflows/github-actions-demo.yml | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 .github/workflows/github-actions-demo.yml diff --git a/.github/workflows/github-actions-demo.yml b/.github/workflows/github-actions-demo.yml deleted file mode 100644 index 0eb7126e9..000000000 --- a/.github/workflows/github-actions-demo.yml +++ /dev/null @@ -1,18 +0,0 @@ -name: GitHub Actions Demo -run-name: ${{ github.actor }} is testing out GitHub Actions 🚀 -on: [push] -jobs: - Explore-GitHub-Actions: - runs-on: ubuntu-latest - steps: - - run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event." - - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by GitHub!" - - run: echo "🔎 The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}." - - name: Check out repository code - uses: actions/checkout@v4 - - run: echo "💡 The ${{ github.repository }} repository has been cloned to the runner." - - run: echo "🖥️ The workflow is now ready to test your code on the runner." - - name: List files in the repository - run: | - ls ${{ github.workspace }} - - run: echo "🍏 This job's status is ${{ job.status }}." From dcfa034dafab2423a319ba525521ede0bd9939c5 Mon Sep 17 00:00:00 2001 From: Pun2341 <67458426+Pun2341@users.noreply.github.com> Date: Sat, 18 Nov 2023 10:40:32 -0500 Subject: [PATCH 08/11] Test ignore --- .github/workflows/pylint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index 75a7643be..eaa1fef21 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -32,4 +32,4 @@ jobs: # Unable to import .. --disable E0401 \ --fail-under 7.0 \ - --ignore-paths re.compile("^/ml-model/yolov5") + --ignore yolov5/ From 27938ab3addf5c65eb7f500990a618c7ee831696 Mon Sep 17 00:00:00 2001 From: Pun2341 <67458426+Pun2341@users.noreply.github.com> Date: Sat, 18 Nov 2023 10:50:30 -0500 Subject: [PATCH 09/11] ignore-paths --- .github/workflows/pylint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index eaa1fef21..4511ad4f1 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -32,4 +32,4 @@ jobs: # Unable to import .. --disable E0401 \ --fail-under 7.0 \ - --ignore yolov5/ + --ignore-paths ^ml-model/yolov5/.*$ From d5c504766a09360f70d0ecb89ad5f33dd261388a Mon Sep 17 00:00:00 2001 From: Pun2341 <67458426+Pun2341@users.noreply.github.com> Date: Sat, 18 Nov 2023 11:01:24 -0500 Subject: [PATCH 10/11] Update pylint.yml Don't forget to add new folders here --- .github/workflows/pylint.yml | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index 4511ad4f1..1c2b575d9 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -18,9 +18,9 @@ jobs: run: | python -m pip install --upgrade pip pip install pylint - - name: Analysing the code with pylint + - name: Analysing frontend code with pylint run: | - pylint $(git ls-files '*.py') \ + pylint $(git ls-files 'front-end/*.py') \ # Missing Module Docstring --disable C0114 \ # Missing Class Docstring @@ -31,5 +31,18 @@ jobs: --disable E1101 \ # Unable to import .. --disable E0401 \ - --fail-under 7.0 \ - --ignore-paths ^ml-model/yolov5/.*$ + --fail-under 7.0 + - name: Analysing ml-model/web code with pylint + run: | + pylint $(git ls-files 'ml-model/web/*.py') \ + # Missing Module Docstring + --disable C0114 \ + # Missing Class Docstring + --disable C0115 \ + # Missing Function Docstring + --disable C0116 \ + # Instance of .. has no .. member + --disable E1101 \ + # Unable to import .. + --disable E0401 \ + --fail-under 7.0 From 1f8eafe26ef71ad16f3700dc7b07774f18010d8a Mon Sep 17 00:00:00 2001 From: Pun Chaixanien Date: Sat, 18 Nov 2023 11:31:17 -0500 Subject: [PATCH 11/11] deleted testfile --- test-folder/testfile.py | 6 ------ 1 file changed, 6 deletions(-) delete mode 100644 test-folder/testfile.py diff --git a/test-folder/testfile.py b/test-folder/testfile.py deleted file mode 100644 index d5a5bdbac..000000000 --- a/test-folder/testfile.py +++ /dev/null @@ -1,6 +0,0 @@ -def testFunction(): - print("Hello World!") - - -def print_really_long_string(): - print("This is a really long string that will be printed on multiple lines.")