Skip to content

gcp-metadata: Internal error log is printed - "MetadataLookupWarning: received unexpected error = All promises were rejected" #138

@yoshigev

Description

@yoshigev

Please make sure you have searched for information in the following guides.

Link to the code that reproduces this issue. A link to a public Github Repository or gist with a minimal reproduction.

https://gist.github.com/yoshigev/c3ab7122f306757744b1e0e919ae65d0

A step-by-step description of how to reproduce the issue, based on the linked reproduction.

Just run isAvailable() method as shown in the gist, in non GCP environment.

The console output will show MetadataLookupWarning: received unexpected error = All promises were rejected warning.

A clear and concise description of what the bug is, and what you expected to happen.

The bug was probably introduced by dd0012a.

The new code changed the thrown error of fastFailMetadataRequest - as explained in the comment there, the new error is AggregateError. The problem is, that this error is not masked in isAvailable as the other known errors.

cc @Dhoni77

A clear and concise description WHY you expect this behavior, i.e., was it a recent change, there is documentation that points to this behavior, etc. **

There is no reason for this error to appear, as this is not a real problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions