create-pull-request action fails on delete
- Linguagem predominante
- Dockerfile
- Estrelas
- 0
- Forks
- 8
- Merge médio
- 6min
- PRs com merge (30d)
- 1
Descrição
### TL;DR
I believe this is caused by the [loop](https://github.com/abcxyz/actions/blob/2c7fac9c570b3c4e27cda7b08bcb143787391eed/.github/actions/create-pull-request/action.yml#L299) that iterates over deleted files and attempts to get the file's mode via the `stat` command. Unfortunately, one cannot stat a deleted file.
My first idea to fix is to see if we need a file's mode for deleted files. I'm hoping we don't, so similar to the SHA, we can just leave it unset/null.
### Expected behavior
_No response_
### Observed behavior
Unhandled error: Error: ENOENT: no such file or directory, stat ''
### Environment Details
```markdown
N/A
```
### Additional information
_No response_
Guia de contribuição
Direção de pesquisa
The issue points to a specific loop in .github/actions/create-pull-request/action.yml line 299. Examine the loop to understand how it handles deleted files. Check if the file mode is needed for deleted files; if not, modify the code to skip the stat call or set the mode to null. Test the fix by simulating a workflow that deletes a file.
Escrita pelo modelo de indexação a partir do texto da issue.
Avaliação
- Stack de tecnologia
- github-actions, shell
- Domínio
- ci-cd, devtools
- Tipo de issue
- Bug
- Dificuldade
- 2/5
- Tempo estimado
- 1-3 horas
- Status de atividade
- Estagnada
- Clareza
- Claramente especificada
- Facilidade para iniciantes
- 65/100