Skip to content
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

feat: Sleep 3sec for issue milestone query #97

Merged
merged 1 commit into from
Oct 30, 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 nu/milestone.nu
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ export def guess-milestone-for-issue [
loop {
if $milestone != '-' or $tries > 5 { break }
print $'Try to guess milestone for issue (ansi p)($issueNO)(ansi reset) closed by PR (ansi p)($pr)(ansi reset) ...'
$tries += 1; sleep 2sec
$tries += 1; sleep 3sec
$milestone = (gh pr view --repo $repo $pr --json 'milestone'
| from json
| get milestone?.title?
Expand Down
2 changes: 1 addition & 1 deletion nu/query.nu
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def query-issue-status [issueNO: int, payload: string, token: string] {
| select number milestone?.title? author.login repository.nameWithOwner mergeCommit.abbreviatedOid title
| rename -c $rename

$tries += 1; sleep 2sec
$tries += 1; sleep 3sec
$closer = if ($closers | is-empty) { {} } else { $closers | last }
$milestone = $closer.milestone? | default '-'
}
Expand Down