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

TypeError from HealthcheckResult #15

Open
Rid opened this issue Nov 2, 2023 · 3 comments
Open

TypeError from HealthcheckResult #15

Rid opened this issue Nov 2, 2023 · 3 comments

Comments

@Rid
Copy link
Member

Rid commented Nov 2, 2023

In certain circumstances, we can see the following error:

PHP Fatal error: Uncaught TypeError: Docker\API\Model\HealthcheckResult::setStart(): Argument #1 ($start) must be of type ?DateTimeInterface, bool given, called in /usr/local/cylo-serverapi/vendor/beluga-php/docker-php-api/src/Normalizer/HealthcheckResultNormalizer.php on line 47 and defined in /usr/local/cylo-serverapi/vendor/beluga-php/docker-php-api/src/Model/HealthcheckResult.php:63

I'm not 100% certain what the circumstances are to reproduce the error yet, it may be a fresh container which has not run a healthcheck yet, in which case returning a boolean is not documented in the docker swagger: https://github.com/moby/moby/blob/217054ddea5517d391b69c4826b3a4cfa393b1e6/api/swagger.yaml#L852

If it is intended behaviour the swagger file will need to be updated.

@flavioheleno
Copy link
Member

I think that once we get to reproduce it, we may follow through in moby's repository to check with them if the behavior is expected or not and act from there.

WDYT?

@Rid
Copy link
Member Author

Rid commented Nov 6, 2023

I'm busy this week, but I will check the docker code to see if the HealthcheckResult can return a bool.

@Rid
Copy link
Member Author

Rid commented Apr 10, 2024

Planning to take a look at these bugs and get the jane code merged in May, very busy with other projects atm.

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

No branches or pull requests

2 participants