flutter / flutter

Flutter makes it easy and fast to build beautiful apps for mobile and beyond
https://flutter.dev
BSD 3-Clause "New" or "Revised" License
166.5k stars 27.59k forks source link

github-actions bot not closing issues. #158356

Open ditman opened 2 weeks ago

ditman commented 2 weeks ago

Type of Request

bug

Infrastructure Environment

github-actions bot

What is happening?

I marked an issue as "waiting for customer response" 3 weeks ago, and after a period of inaction, the github-actions bot messaged that it was going to "reluctantly going to close this bug for now".

It didn't actually close the issue though (I guess it was feeling very reluctant!)

Here's the link to the issue:

I'm leaving it open in case there's something fishy on it.

Steps to reproduce

  1. Add the waiting for customer response label to a flutter/flutter issue.
  2. Wait 3 weeks.

Expected results

I'd expect the issue to be closed after the inactivity period. The issue where I applied this label remained open.

christopherfujino commented 2 weeks ago

No idea why this didn't work, but as we're using a forked action: https://github.com/flutter/flutter/blob/master/.github/workflows/no-response.yaml

We should migrate this to using the upstream one.

ditman commented 2 weeks ago

Other affected issue:

This issue looks like is going to go unattended for 3 weeks:

(List of labeled issues in reverse comment order)

ditman commented 2 weeks ago

I looked at the latest action logs:

And it seems that it's choking at a locked issue:

flutter/flutter#149165 is being closed
/home/runner/work/_actions/godofredoc/no-response/0ce2dc0e63e1c7d2b87752ceed091f6d32c9df09/dist/index.js:3738
      const error = new requestError.RequestError(toErrorMessage(data), status, {
                    ^

RequestError [HttpError]: Unable to create comment because issue is locked.
    at /home/runner/work/_actions/godofredoc/no-response/0ce2dc0e63e1c7d2b87752ceed091f6d32c9df09/dist/index.js:3738:21
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
  status: 403,

Issue:


I'm going to try and remove the label from that issue and re-run the action, and see if it can continue. (I also wonder why the action attempted to run in a closed issue)

Retry here: https://github.com/flutter/flutter/actions/runs/11733733863

stuartmorgan commented 2 weeks ago

Thanks for investigating this! Primary triage brought this up recently but I hadn't been able to look into it yet. I forgot we have run logs for this that I could look at.

stuartmorgan commented 2 weeks ago

We should migrate this to using the upstream one.

We were not able to get fixed landed upstream that we needed for it to work for us (IIRC it wasn't correctly handling repos with lots of issues); unless that changed we'll need to re-fork instead.

stuartmorgan commented 2 weeks ago

Yes, here we go: https://github.com/lee-dohm/no-response/issues/211

We got the fix landed, but couldn't use it without more changes that we couldn't get landed. Note that the last commit to the upstream repo is 3 years ago.

ditman commented 2 weeks ago

Link to all failed jobs:

(There's a lottttt of them that link back to the same locked issue, probably the code of the action needs to be updated to handle that case? Or maybe be more clear when failing?)

"Normal" failures seem to be related to a secondary rate limit, see this log, but those now are replaced by the locked issue. I hope that removing the label from the locked issue helps the bot.

(PS: We should at least migrate the fork to something owned by the flutter team, and not a personal repo, quite urgently 😅)

christopherfujino commented 2 weeks ago

Yes, here we go: lee-dohm/no-response#211

We got the fix landed, but couldn't use it without more changes that we couldn't get landed. Note that the last commit to the upstream repo is 3 years ago.

Thanks for the context.

ditman commented 2 weeks ago

The bot seems to be closing issues again (?)