Skip to content

Unable to open checker on windows #29509

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

Closed
yp05327 opened this issue Mar 1, 2024 · 2 comments · Fixed by #29538
Closed

Unable to open checker on windows #29509

yp05327 opened this issue Mar 1, 2024 · 2 comments · Fixed by #29538
Labels

Comments

@yp05327
Copy link
Contributor

yp05327 commented Mar 1, 2024

Description

#29349 (comment)

Gitea Version

1.21.7

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

run binary

Database

None

@charles7668
Copy link
Contributor

I think the problem may be that Windows can't handle signals like Linux does, but in reality, the checker is working correctly.

In Linux, the exit code is 9, which corresponds to the signal "kill". However, in Windows, it always returns 1.

image

@wxiaoguang
Copy link
Contributor

Hmm .... I have question for that code long time ago (#19006 (comment))

But I don't have Windows environment at the moment .... if the code could be refactored and improved, I could help to review & approve.

lunny pushed a commit that referenced this issue Mar 2, 2024
#29538)

Close #29509

Windows, unlike Linux, does not have signal-specified exit codes.
Therefore, we should add a Windows-specific check for Windows. If we
don't do this, the logs will always show a failed status, even though
the command actually works correctly.

If you check the Go source code in exec_windows.go, you will see that it
always returns exit code 1.

![image](https://github.com/go-gitea/gitea/assets/30816317/9dfd7c70-9995-47d9-9641-db793f58770c)

The exit code 1 does not exclusively signify a SIGNAL KILL; it can
indicate any issue that occurs when a program fails.
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants