Compare commits

..

6 Commits

Author SHA1 Message Date
Luke Tomlinson
be24587b3c Use minutes for debugging 2021-07-26 10:06:14 -04:00
Falk Puschner
86507610fb 🎨 improve changelog (#531) 2021-07-15 09:55:05 -04:00
Falk Puschner
ceeedec52e 🔥 using v4 & remove token (#530) 2021-07-15 09:48:15 -04:00
dependabot[bot]
0156089d02 Merge pull request #479 from actions/dependabot/npm_and_yarn/vercel/ncc-0.28.6 2021-07-14 18:31:11 +00:00
Luke Tomlinson
cdf15f641a Prep for v4 (#510)
* Update dist for v4 release

* Create CHANGELOG.md

* Update CHANGELOG.md

Co-authored-by: Geoffrey Testelin <geoffrey.testelin@gmail.com>

* Update CHANGELOG.md

Co-authored-by: Geoffrey Testelin <geoffrey.testelin@gmail.com>

* Update CHANGELOG.md

Co-authored-by: Geoffrey Testelin <geoffrey.testelin@gmail.com>

* Update CHANGELOG.md

Co-authored-by: Geoffrey Testelin <geoffrey.testelin@gmail.com>

* Update CHANGELOG.md

Co-authored-by: Geoffrey Testelin <geoffrey.testelin@gmail.com>

* Update CHANGELOG.md

* Update index.js

Co-authored-by: Geoffrey Testelin <geoffrey.testelin@gmail.com>
2021-07-14 10:21:39 -04:00
dependabot[bot]
4b47cddc05 build(deps-dev): bump @vercel/ncc from 0.27.0 to 0.28.6
Bumps [@vercel/ncc](https://github.com/vercel/ncc) from 0.27.0 to 0.28.6.
- [Release notes](https://github.com/vercel/ncc/releases)
- [Commits](https://github.com/vercel/ncc/compare/0.27.0...0.28.6)

---
updated-dependencies:
- dependency-name: "@vercel/ncc"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-06-14 14:09:26 +00:00
6 changed files with 20 additions and 22 deletions

View File

@@ -20,5 +20,5 @@ Starting in version 4.0.0 we will maintain a changelog
### Breaking Changes
* The options `skip-stale-issue-message` and `skip-stale-pr-message` were removed. Instead, setting the options `stale-issue-message` and `stale-pr-message` will be enough to let the stale workflow add a comment. If the options are unset, a comment will not be added which was the equivalent of setting `skip-stale-issue-message` to `false`.
* The options `skip-stale-issue-message` and `skip-stale-pr-message` were removed. Instead, setting the options `stale-issue-message` and `stale-pr-message` will be enough to let the stale workflow add a comment. If the options are unset, a comment will not be added which was the equivalent of setting `skip-stale-issue-message` to `true`.
* The `operations-per-run` option will be more effective. After migrating, you could face a failed-fast process workflow if you let the default value (30) or set it to a small number. In that case, you will see a warning at the end of the logs (if enabled) indicating that the workflow was stopped sooner to avoid consuming too much API calls. In most cases, you can just increase this limit to make sure to process everything in a single run.

View File

@@ -489,7 +489,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
stale-issue-message: 'Message to comment on stale issues. If none provided, will not mark issues stale'
stale-pr-message: 'Message to comment on stale PRs. If none provided, will not mark PRs stale'
@@ -507,7 +507,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
days-before-stale: 30
@@ -526,9 +526,8 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
stale-pr-message: 'This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.'
close-issue-message: 'This issue was closed because it has been stalled for 5 days with no activity.'
@@ -549,9 +548,8 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
stale-pr-message: 'This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.'
close-issue-message: 'This issue was closed because it has been stalled for 5 days with no activity.'
@@ -574,7 +572,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
stale-issue-message: 'Stale issue message'
stale-pr-message: 'Stale pull request message'
@@ -597,7 +595,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
start-date: '2020-18-04T00:00:00Z' # ISO 8601 or RFC 2822
```
@@ -614,7 +612,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
exempt-issue-milestones: 'future,alpha,beta'
exempt-pr-milestones: 'bugfix,improvement'
@@ -632,7 +630,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
exempt-all-pr-milestones: true
```
@@ -649,7 +647,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
any-of-labels: 'needs-more-info,needs-demo'
# You can opt for 'only-labels' instead if your use-case requires all labels
@@ -668,7 +666,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
exempt-issue-assignees: 'marco,polo'
exempt-pr-assignees: 'marco'
@@ -686,7 +684,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
- uses: actions/stale@v4
with:
exempt-all-pr-assignees: true
```

4
dist/index.js vendored
View File

@@ -267,8 +267,8 @@ class IssuesProcessor {
this._statistics = new statistics_1.Statistics();
}
}
static _updatedSince(timestamp, num_min) {
const daysInMillis = 1000 * 60 * num_min;
static _updatedSince(timestamp, num_minutes) {
const daysInMillis = 1000 * 60 * num_minutes;
const millisSinceLastUpdated = new Date().getTime() - new Date(timestamp).getTime();
return millisSinceLastUpdated <= daysInMillis;
}

6
package-lock.json generated
View File

@@ -2141,9 +2141,9 @@
}
},
"@vercel/ncc": {
"version": "0.27.0",
"resolved": "https://registry.npmjs.org/@vercel/ncc/-/ncc-0.27.0.tgz",
"integrity": "sha512-DllIJQapnU2YwewIhh/4dYesmMQw3h2cFtabECc/zSJHqUbNa0eJuEkRa6DXbZvh1YPWBtYQoPV17NlDpBw1Vw==",
"version": "0.28.6",
"resolved": "https://registry.npmjs.org/@vercel/ncc/-/ncc-0.28.6.tgz",
"integrity": "sha512-t4BoSSuyK8BZaUE0gV18V6bkFs4st7baumtFGa50dv1tMu2GDBEBF8sUZaKBdKiL6DzJ2D2+XVCwYWWDcQOYdQ==",
"dev": true
},
"JSONStream": {

View File

@@ -49,7 +49,7 @@
"@types/semver": "^7.3.5",
"@typescript-eslint/eslint-plugin": "^4.26.0",
"@typescript-eslint/parser": "^4.26.1",
"@vercel/ncc": "^0.27.0",
"@vercel/ncc": "^0.28.6",
"ansi-styles": "5.2.0",
"eslint": "^7.28.0",
"eslint-plugin-github": "^4.1.2",

View File

@@ -29,8 +29,8 @@ import {LoggerService} from '../services/logger.service';
* Handle processing of issues for staleness/closure.
*/
export class IssuesProcessor {
private static _updatedSince(timestamp: string, num_min: number): boolean {
const daysInMillis = 1000 * 60 * num_min;
private static _updatedSince(timestamp: string, num_minutes: number): boolean {
const daysInMillis = 1000 * 60 * num_minutes;
const millisSinceLastUpdated =
new Date().getTime() - new Date(timestamp).getTime();