node icon indicating copy to clipboard operation
node copied to clipboard

lib: modify NativeModule to use compileFunction

Open ryzokuken opened this issue 6 years ago • 17 comments

Modify the NativeModule class to use compileFunction instead of manually wrapping the string source code and then compiling it.

Checklist
  • [x] make -j4 test (UNIX), or vcbuild test (Windows) passes
  • [x] tests and/or benchmarks are included
  • [x] documentation is changed or added
  • [x] commit message follows commit guidelines

/cc @devsnek @bcoe

ryzokuken avatar Oct 23 '18 18:10 ryzokuken

@ryzokuken build started: https://ci.nodejs.org/blue/organizations/jenkins/node-test-pull-request-lite-pipeline/detail/node-test-pull-request-lite-pipeline/1347/pipeline

nodejs-github-bot avatar Oct 23 '18 18:10 nodejs-github-bot

@ryzokuken awesome, thank you for doing this (I'm excited to see if it fixes some of the issues I was seeing around instrumenting internal modules for coverage).

I will get some feedback to you tonight.

bcoe avatar Oct 23 '18 19:10 bcoe

@devsnek done! PTAL.

ryzokuken avatar Oct 24 '18 12:10 ryzokuken

@joyeecheung @jdalton done! PTAL.

ryzokuken avatar Oct 25 '18 00:10 ryzokuken

@joyeecheung done! PTAL.

ryzokuken avatar Oct 27 '18 14:10 ryzokuken

CI: https://ci.nodejs.org/job/node-test-pull-request/18227/

ryzokuken avatar Oct 30 '18 09:10 ryzokuken

@ryzokuken Is this still being worked on? (If yes, should we add an in progress label? If not, should we close it?)

Trott avatar Nov 06 '18 05:11 Trott

@Trott it is! The discussion was moved into another sub-change which should be merged soon and unblock this one.

ryzokuken avatar Nov 06 '18 06:11 ryzokuken

Pointer: https://github.com/nodejs/node/pull/24069

Until that lands, or gets merged into this PR, it will fail the cache generation tests. Although even with that change, this still needs to fix the generator..

joyeecheung avatar Nov 06 '18 06:11 joyeecheung

@joyeecheung @ryzokuken I believe internal modules no longer have a wrapper prefix? is this work still needed?

Seems like the important issue is https://github.com/nodejs/node/pull/21573

bcoe avatar Jan 19 '19 00:01 bcoe

@bcoe IIRC, @joyeecheung took care of this. Working on merging the other one in.

ryzokuken avatar Jan 19 '19 14:01 ryzokuken

This looks like it may have been abandoned. Should we close this? We can re-open it if someone starts to work on it again?

Trott avatar Jun 23 '20 22:06 Trott

@Trott I had a talk with @joyeecheung about these, and looks like they still need some work. Please leave it open and I'd try to look deeper into it either later today or next week.

ryzokuken avatar Jun 28 '20 08:06 ryzokuken

ping @ryzokuken to see if it is moving

gireeshpunathil avatar Dec 01 '20 11:12 gireeshpunathil

I'm super sorry, but I've had no time as of late to finish this. If you don't mind leaving this open, I can try to look into it during vacations later this month or someone else would be interested to pick it up?

ryzokuken avatar Dec 01 '20 11:12 ryzokuken

@ryzokuken any chance you're able to get to this?

bnb avatar Jan 07 '22 23:01 bnb

@bnb sorry about that, I'll try to get back to it over the weekend.

ryzokuken avatar Jan 12 '22 11:01 ryzokuken

This needs a rebase.

aduh95 avatar May 11 '24 16:05 aduh95