Log warnings state "could not rewrite [filename]"

  • Updated


Log and console output contains a warning stating could not rewrite <filename>.


Part of the Node.js instrumentation process involves rewriting source as it is loaded into the module cache. The agent may fail to rewrite some files for a number of reasons: unexpected syntax, unusual character encodings, etc. When this happens, the agent will log its failure and load the original, unmodified source into the module cache. While the agent may have difficulty following dataflow through these files, everything else should work as normal. 


If you are seeing these messages, please let us know via the Submit a request link below.

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request