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

opentelemetry-resource-detector-aws doesn't compile on main #1429

Closed
Flarna opened this issue Mar 15, 2023 · 4 comments · Fixed by open-telemetry/opentelemetry-js#3677
Closed
Labels
bug Something isn't working

Comments

@Flarna
Copy link
Member

Flarna commented Mar 15, 2023

Refs: #1427 (comment)

a local run shows following errors in opentelemetry-resource-detector-aws:

src/detectors/AwsBeanstalkDetector.ts:85:7 - error TS2739: Type 'IResource' is missing the following properties from type 'Resource': _attributes, _syncAttributes, _asyncAttributesPromise
85       return Resource.empty();
         ~~~~~~~~~~~~~~~~~~~~~~~~

src/detectors/AwsEcsDetector.ts:53:7 - error TS2322: Type 'IResource' is not assignable to type 'Resource'.
53       return Resource.empty();
         ~~~~~~~~~~~~~~~~~~~~~~~~

src/detectors/AwsEcsDetector.ts:79:5 - error TS2322: Type 'IResource' is not assignable to type 'Resource'.
79     return resource;
       ~~~~~~~~~~~~~~~~

src/detectors/AwsEcsDetector.ts:118:5 - error TS2322: Type 'IResource' is not assignable to type 'Resource'.
118     return Resource.empty();
        ~~~~~~~~~~~~~~~~~~~~~~~~

src/detectors/AwsEksDetector.ts:73:9 - error TS2322: Type 'IResource' is not assignable to type 'Resource'.
73         return Resource.empty();
           ~~~~~~~~~~~~~~~~~~~~~~~~

src/detectors/AwsEksDetector.ts:79:7 - error TS2322: Type 'IResource' is not assignable to type 'Resource'.
 79       return !containerId && !clusterName
          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 80         ? Resource.empty()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~
...
 87             [SemanticResourceAttributes.CONTAINER_ID]: containerId || '',
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 88           });
    ~~~~~~~~~~~~~

src/detectors/AwsEksDetector.ts:91:7 - error TS2322: Type 'IResource' is not assignable to type 'Resource'.
91       return Resource.empty();
         ~~~~~~~~~~~~~~~~~~~~~~~~

src/detectors/AwsLambdaDetector.ts:37:7 - error TS2322: Type 'IResource' is not assignable to type 'Resource'.
37       return Resource.empty();
         ~~~~~~~~~~~~~~~~~~~~~~~~

Found 8 errors.
@Flarna Flarna added the bug Something isn't working label Mar 15, 2023
@Flarna
Copy link
Member Author

Flarna commented Mar 15, 2023

fyi @willarmiros

@Flarna
Copy link
Member Author

Flarna commented Mar 15, 2023

@pichlermarc I guess open-telemetry/opentelemetry-js#3676 describes the actual root cause right?

@pichlermarc
Copy link
Member

pichlermarc commented Mar 15, 2023

@pichlermarc I guess open-telemetry/opentelemetry-js#3676 describes the actual root cause right?

Yes, we'll have to cut another release in core to fix this.

@willarmiros
Copy link
Contributor

Thanks for the awareness - please let us know if there's any action needed to update the resource detectors themselves (from what I can tell it seems like an unintentional breaking change in the underlying Resources package).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
3 participants