question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Newlines stripped from processed files

See original GitHub issue

new lines seem to be removed even if i dont change a file, for now i am having to do:

return root.toSource({quote: 'single', trailingComma: true}) + '\n';

Maybe this is an issue with recast?

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Reactions:1
  • Comments:10 (8 by maintainers)

github_iconTop GitHub Comments

5reactions
nebirhoscommented, Jan 5, 2018

It looks like this is an issue again in v0.4.0.

Edit: Tested the same script with v0.3.32, newlines are preserved as expected.

0reactions
ibrahimacommented, Jan 25, 2018

Aha, ran into this issue as well. I can confirm that downgrading to v0.3.32 fixes the issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

shell - When printing a variable that contains newlines, why is ...
In a somewhat common case, you'd use command substitution to capture a one-line output, say osrev=$(uname -r) . The utilities usually print a ......
Read more >
python - How to strip newlines from each line during a file read?
This works fine, but I can't help thinking there's a more efficient way to do this, to strip the newlines during the read...
Read more >
Sanitizing files with no trailing newline « \1 - backreference.org
As it happens, certain applications produce text files with the final newline character missing on the last line.
Read more >
Read a text file into string and strip newlines in Python
Strip newlines means removing the \n from last of the string. To open a file in python , we use open() method.It returns...
Read more >
Line breaks are removed in posts made in plain text format
The information bar message about extra line breaks does not appear, either in the Preview pane or when you read the post. This...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found