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

In some cases getMetadataForProject method is throwing errors #941

Open
roopa0222 opened this issue Jun 13, 2024 · 1 comment
Open

In some cases getMetadataForProject method is throwing errors #941

roopa0222 opened this issue Jun 13, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@roopa0222
Copy link

Describe the bug
In my test extension I tried to use getMetadataForProject method in the main.ts . It threw an error and extension was not activated.

const finalProjectId = await papi.projectLookup.getMetadataForProject(
    // TPKJ ID
    'b4c501ad2538989d6fb723518e92408406e232d3',
    );
    logger.debug(`Metadata: ${JSON.stringify(finalProjectId)}`);

To Reproduce
Behavior is not consistent, TJ think it could be a race condition

Expected behavior
Should be able to use the method without any errors

main_extensionHostError.log

@roopa0222 roopa0222 added the bug Something isn't working label Jun 13, 2024
@tjcouch-sil
Copy link
Member

tjcouch-sil commented Jun 18, 2024

Notes for working on this: this is specifically running getMetadataForProject directly in the activate function. I believe we are not waiting on any PDPFs to get registered when we do this, so it's likely a race condition between this call and the activation of the appropriate PDPF. Possibly the same fix will also fix #919

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
Status: No status
Development

No branches or pull requests

2 participants