Compare commits

...

6 commits

Author SHA1 Message Date
Alysson Ribeiro
5d71de3d40
Merge 1fc030afe4 into 29ad32e6d0 2024-11-13 18:18:33 +01:00
29ad32e6d0
Merge pull request #366 from wneessen/dependabot/github_actions/sonarsource/sonarqube-scan-action-4.0.0
Bump sonarsource/sonarqube-scan-action from 3.1.0 to 4.0.0
2024-11-13 14:40:23 +01:00
d03c476fb7
Merge pull request #367 from wneessen/dependabot/github_actions/github/codeql-action-3.27.3
Bump github/codeql-action from 3.27.2 to 3.27.3
2024-11-13 14:40:04 +01:00
dependabot[bot]
2f97ebabd3
Bump github/codeql-action from 3.27.2 to 3.27.3
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.27.2 to 3.27.3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](9278e42166...396bb3e453)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-11-13 13:31:52 +00:00
dependabot[bot]
ea70b21c90
Bump sonarsource/sonarqube-scan-action from 3.1.0 to 4.0.0
Bumps [sonarsource/sonarqube-scan-action](https://github.com/sonarsource/sonarqube-scan-action) from 3.1.0 to 4.0.0.
- [Release notes](https://github.com/sonarsource/sonarqube-scan-action/releases)
- [Commits](13990a6956...94d4f8ac4a)

---
updated-dependencies:
- dependency-name: sonarsource/sonarqube-scan-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-11-13 13:31:45 +00:00
Alysson Ribeiro
1fc030afe4 Feature(sendError): add unwrap interface 2024-11-07 14:59:06 +01:00
4 changed files with 11 additions and 5 deletions

View file

@ -208,7 +208,7 @@ jobs:
run: | run: |
go test -shuffle=on -race --coverprofile=./cov.out ./... go test -shuffle=on -race --coverprofile=./cov.out ./...
- name: SonarQube scan - name: SonarQube scan
uses: sonarsource/sonarqube-scan-action@13990a695682794b53148ff9f6a8b6e22e43955e # master uses: sonarsource/sonarqube-scan-action@94d4f8ac4aaefccd7fb84bff00b0aeb2d65fcd49 # master
if: success() if: success()
env: env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

View file

@ -54,7 +54,7 @@ jobs:
# Initializes the CodeQL tools for scanning. # Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL - name: Initialize CodeQL
uses: github/codeql-action/init@9278e421667d5d90a2839487a482448c4ec7df4d # v3.27.2 uses: github/codeql-action/init@396bb3e45325a47dd9ef434068033c6d5bb0d11a # v3.27.3
with: with:
languages: ${{ matrix.language }} languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file. # If you wish to specify custom queries, you can do so here or in a config file.
@ -65,7 +65,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java). # 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) # If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild - name: Autobuild
uses: github/codeql-action/autobuild@9278e421667d5d90a2839487a482448c4ec7df4d # v3.27.2 uses: github/codeql-action/autobuild@396bb3e45325a47dd9ef434068033c6d5bb0d11a # v3.27.3
# Command-line programs to run using the OS shell. # Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl # 📚 https://git.io/JvXDl
@ -79,4 +79,4 @@ jobs:
# make release # make release
- name: Perform CodeQL Analysis - name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@9278e421667d5d90a2839487a482448c4ec7df4d # v3.27.2 uses: github/codeql-action/analyze@396bb3e45325a47dd9ef434068033c6d5bb0d11a # v3.27.3

View file

@ -75,6 +75,6 @@ jobs:
# Upload the results to GitHub's code scanning dashboard. # Upload the results to GitHub's code scanning dashboard.
- name: "Upload to code-scanning" - name: "Upload to code-scanning"
uses: github/codeql-action/upload-sarif@9278e421667d5d90a2839487a482448c4ec7df4d # v3.27.2 uses: github/codeql-action/upload-sarif@396bb3e45325a47dd9ef434068033c6d5bb0d11a # v3.27.3
with: with:
sarif_file: results.sarif sarif_file: results.sarif

View file

@ -133,6 +133,10 @@ func (e *SendError) Is(errType error) bool {
return false return false
} }
func (e *SendError) Unwrap() []error {
return e.errlist
}
// IsTemp returns true if the delivery error is of a temporary nature and can be retried. // IsTemp returns true if the delivery error is of a temporary nature and can be retried.
// //
// This function checks whether the SendError indicates a temporary error, which suggests // This function checks whether the SendError indicates a temporary error, which suggests
@ -224,3 +228,5 @@ func (r SendErrReason) String() string {
func isTempError(err error) bool { func isTempError(err error) bool {
return err.Error()[0] == '4' return err.Error()[0] == '4'
} }
var _ interface{ Unwrap() []error } = &SendError{}