Skip to content

Create scorecards.yml #37

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jul 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .deepsource.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ exclude_patterns = [
"codecov_env",
"*,cover",
".hypothesis/",
"docs/"
"docs/conf.py"
]

[[analyzers]]
Expand Down
69 changes: 38 additions & 31 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,46 +1,53 @@
# Add 'Multicast' label to any root file changes
Multicast:
- setup.py
- multicast/*.py
# Add 'Python Repo' label to any root file changes
Python Repo:
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is unclear if the whitespace here needs quoted from the docs:

- changed-files:
- any-glob-to-any-file: 'setup.py'
- any-glob-to-any-file: 'pythonrepo/*.py'

# Add 'Lint' label to any lint file changes
Linter:
- .stickler.yml
- .hound.yml
- .yamllint.conf
- .flake8.ini
- .deepsource.toml
- tests/check_*
- changed-files:
- any-glob-to-any-file: '.stickler.yml'
- any-glob-to-any-file: '.hound.yml'
- any-glob-to-any-file: '.yamllint.conf'
- any-glob-to-any-file: '.flake8.ini'
- any-glob-to-any-file: '.deepsource.toml'
- any-glob-to-any-file: 'tests/check_*'
Comment on lines +10 to +15
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 Perhaps this could be one entry as an array like [ ..., ..., ] style.


# Add 'Lang' label to any python file changes
Python Lang:
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is unclear if the whitespace here needs quoted from the docs:

- **/*.py
- *.py
- changed-files:
- any-glob-to-any-file: '**/*.py'
- any-glob-to-any-file: '*.py'
Comment on lines +20 to +21
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 Perhaps this could be one entry as an array like [ ..., ..., ] style.


Configs:
- *.yml
- ./**/*.yml
- *.ini
- *.toml
- *.cfg
- requirements.txt
- changed-files:
- any-glob-to-any-file: '*.yml'
- any-glob-to-any-file: './**/*.yml'
- any-glob-to-any-file: '*.ini'
- any-glob-to-any-file: '*.toml'
- any-glob-to-any-file: '*.cfg'
- any-glob-to-any-file: 'requirements.txt'
Comment on lines +25 to +30
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 Perhaps this could be one entry as an array like [ ..., ..., ] style.


# Add 'test' label
Testing:
- tests/**/*.py
- tests/*
- .circleci/*
- changed-files:
- any-glob-to-any-file: 'tests/**/*.py'
- any-glob-to-any-file: 'tests/*'
- any-glob-to-any-file: '.circleci/*'
Comment on lines +35 to +37
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 Perhaps this could be one entry as an array like [ ..., ..., ] style.


CI:
- tests/*.py
- .stickler.yml
- .hound.yml
- .travis.yml
- .appveyor.yml
- .github/workflows/*
- .circleci/*
- changed-files:
- any-glob-to-any-file: 'tests/*.py'
- any-glob-to-any-file: '.stickler.yml'
- any-glob-to-any-file: '.hound.yml'
- any-glob-to-any-file: '.travis.yml'
- any-glob-to-any-file: '.appveyor.yml'
- any-glob-to-any-file: '.github/workflows/*'
- any-glob-to-any-file: '.circleci/*'
Comment on lines +41 to +47
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 Perhaps this could be one entry as an array like [ ..., ..., ] style.


Github:
- .github/**/*
- .github/*
- README.md
- changed-files:
- any-glob-to-any-file: '.github/**/*'
- any-glob-to-any-file: '.github/*'
- any-glob-to-any-file: 'README.md'
Comment on lines +51 to +53
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 Perhaps this could be one entry as an array like [ ..., ..., ] style.

8 changes: 4 additions & 4 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
Expand All @@ -53,7 +53,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1
uses: github/codeql-action/autobuild@v3

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
Expand All @@ -67,4 +67,4 @@ jobs:
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
uses: github/codeql-action/analyze@v3
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ on:
schedule:
- cron: '18 9 * * 5'
push:
branches: [ "master" ]
branches: [ master ]
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 This seems to have fixed issue #38 🎉


# Declare default permissions as read only.
permissions: read-all
Expand All @@ -27,8 +27,8 @@ jobs:
# Needed to publish results and get a badge (see publish_results below).
id-token: write
# Uncomment the permissions below if installing in a private repository.
# contents: read
# actions: read
contents: read
actions: read

steps:
- name: "Checkout code"
Expand All @@ -46,7 +46,6 @@ jobs:
# - you are installing Scorecard on a *private* repository
# To create the PAT, follow the steps in https://github.com/ossf/scorecard-action?tab=readme-ov-file#authentication-with-fine-grained-pat-optional.
repo_token: ${{ secrets.SCORECARD_TOKEN }}

# Public repositories:
# - Publish results to OpenSSF REST API for easy access by consumers
# - Allows the repository to include the Scorecard badge.
Expand Down