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

Fix status.lastRegistrationCheckTime in body must be of type string: \"null\" error #398

Merged
merged 3 commits into from
Mar 18, 2021

Conversation

mumoshu
Copy link
Collaborator

@mumoshu mumoshu commented Mar 18, 2021

Follow-up for #392

@int128
Copy link
Contributor

int128 commented Mar 18, 2021

FYI: I have deployed 9b87156 and got the following error:

2021-03-18T00:19:02.734Z	ERROR	controllers.Runner	Failed to update runner status	{"runner": "NAME", "error": "Runner.actions.summerwind.dev \"NAME\" is invalid: status.lastRegistrationCheckTime: Invalid value: \"null\": status.lastRegistrationCheckTime in body must be of type string: \"null\""}
...
github.com/summerwind/actions-runner-controller/controllers.(*RunnerReconciler).updateRegistrationToken
	/workspace/controllers/runner_controller.go:467

I hope this will fix it.

@mumoshu
Copy link
Collaborator Author

mumoshu commented Mar 18, 2021

Turns out this happens when the registration token is being renewed here

https://github.com/summerwind/actions-runner-controller/blob/7a7086e7aa14848ec19fe3a9ed6b1f97277397f2/controllers/runner_controller.go#L466

This in conjunction with the wrong CRD scheme resulted in the error. In other places those errors doesn't occur as we use Patch instead of Update there.

@mumoshu mumoshu merged commit 2929a73 into master Mar 18, 2021
@mumoshu mumoshu deleted the fix-status-last-reg-check-time-type-err branch March 18, 2021 01:37
@mumoshu mumoshu mentioned this pull request Mar 18, 2021
mumoshu added a commit that referenced this pull request Mar 19, 2021
mumoshu added a commit that referenced this pull request Mar 19, 2021
mumoshu added a commit that referenced this pull request Mar 19, 2021
So that we could catch bugs in runner controller like seen in #398, #404, and #407.

Ref #400
mumoshu added a commit that referenced this pull request Mar 19, 2021
So that we could catch bugs in runner controller like seen in #398, #404, and #407.

Ref #400
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants