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

Update agent to handle updates from import-in-the-middle@1.11.1 #2617

Closed
bizob2828 opened this issue Sep 27, 2024 · 3 comments
Closed

Update agent to handle updates from import-in-the-middle@1.11.1 #2617

bizob2828 opened this issue Sep 27, 2024 · 3 comments
Labels
points: 5 1-2 weeks

Comments

@bizob2828
Copy link
Member

Description

It looks like this PR, broke our wrapReturn shim function which wraps an export in a Proxy. After updating to import-in-the-middle@1.11.1 you get

TypeError: getters.get(...)[name] is not a function
    at Object.get (register.js:20:37)
    at Object.set (shimmer.js:648:30)
    at DatastoreShim.wrapEachProperty (shim.js:347:20)
    at Array.forEach (<anonymous>)
    at DatastoreShim.wrap (shim.js:334:14)
    at DatastoreShim.wrapReturn (shim.js:398:15)
    at instrumentPGNative (pg.js:61:10)
    at initialize (pg.js:33:12)
    at _firstPartyInstrumentation (shimmer.js:711:29)
    at loadInstrumentation (shimmer.js:675:25)

It's failing when we try to assign the exported module property as wrapped here

Steps to Reproduce

  1. npm i import-in-the-middle@latest
  2. npm run versioned:internal:major pg-esm

Expected Result

Tests pass

Actual Result

Tests fail

@workato-integration
Copy link

@bizob2828
Copy link
Member Author

This PR fixes the issue

@bizob2828 bizob2828 changed the title Updated agent to handle updates from import-in-the-middle@1.11.1 Update agent to handle updates from import-in-the-middle@1.11.1 Sep 27, 2024
@bizob2828
Copy link
Member Author

I'm closing this as a patch should be coming with import in the middle to fix this

@github-project-automation github-project-automation bot moved this from Triage Needed: Unprioritized Features to Done: Issues recently completed in Node.js Engineering Board Sep 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
points: 5 1-2 weeks
Projects
Status: Done: Issues recently completed
Development

No branches or pull requests

1 participant