ProgerXP / Notepad2e

Word highlighting, simultaneous editing, split views, math evaluation, un/grep, comment reformatting, UAC elevation, complete regexps (PCRE), Lua lexers, DPI awareness and more (XP+)
Other
375 stars 52 forks source link

Strange characters at the end of big json files #305

Open x011 opened 4 years ago

x011 commented 4 years ago

This happens at the end of big (24MB) json files:

https://i.imgur.com/YWPaQnL.jpg

Any idea why?

ProgerXP commented 4 years ago

Wow. Can't say I'm often editing >10M files with highlighting but I routinely work with >100M files (no highlighting) and I haven't seen any glitches like that.

Try two things:

  1. Get SciTE (the text editor from Scintilla, the highlighting backend Notepad2 is using) and try opening your JSON file there. How does it look like?
  2. Upload your JSON file here (as zip please), we'll check on our side.
x011 commented 4 years ago

Hi again, 1 - json looks normal on SciTE 4.3.3 and on the original notepad2 2 - I cannot upload the file because it contains sensitive information, like emails and passwords.

I've removed most of the extra options and changed the font, but it didn't solve the problem:

options

ProgerXP commented 4 years ago

Perhaps this is caused by Scintilla upgrade. Try these two versions:

Does it make any difference?

exe.zip

ProgerXP commented 4 years ago

@cshnik Any idea how to debug it?

x011 commented 4 years ago

All versions I've tried show the same behaviour:

After removing all sensitive data, I end up with an invalid json file, but I still get the same awkward characters. Please notice this happens only at the end of a 25MB file with a single line.
It seems a memory issue, but I'm definitely not an expert, also, it's just a visual artifact because the data is clean on copy paste.

test.zip

ProgerXP commented 4 years ago

Thanks for the data. I confirm I have the same issue on my system.

screen

as zip please

test.zip