-
Notifications
You must be signed in to change notification settings - Fork 31.1k
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
node: call set_trace_sync_io before bootstrap #5964
Conversation
env->set_trace_sync_io was previously being called after node::LoadEnvironment, meaning it wasn't in effect for the initial script.
Save the following in a script and call with var fs = require('fs')
console.log(fs.readFileSync(__filename, {encoding:'UTF8'})) I'll add a test. /cc @cjihrig |
@trevnorris |
Yea, I think that was by design. |
@cjihrig correct. |
Okay, I'll add a comment to that effect then. |
On second thought, @trevnorris could you explain why we skip the trace on the initial tick? I can add a comment and check the docs, would be nice to have an explanation. |
First, yes, it is supposed to run after bootstrap. From
Reasons for this:
Have you tried running |
Closing since this does not appear to be an issue, please let me know if this wasn't correct. :) |
Pull Request check-list
make -j8 test
(UNIX) orvcbuild test nosign
(Windows) pass withthis change (including linting)?
test (or a benchmark) included?
Affected core subsystem(s)
node --trace-sync-io
Description of change
env->set_trace_sync_io
was previously being called afternode::LoadEnvironment
so it wasn't in effect for the initial script.