Application hangs with files with very long lines
The app is hanging when open more than 10 files with big files or files without LF
In order to reproduce this issue, could you share the file size in bytes? Are all the lines without LF or just some lines? Thanks!
Hi Roberto, the file contains only one line without LF at the end (Create View statement for MySQL DB), with 2.523.850 bytes... I was trying to work on ident the T-SQL code but Moped do not like this file and hangs and after a while crashes... I am using Apple M2 Max with 64GB.
Thanks, I'll test with a similar file. Moped wasn't really meant to handle large files, but that size should be OK. Will get back to you.
I haven't been able to reproduce the issue, I have some thoughts on what may be happening:
- Does the file have mixed Unix/Windows end-of-lines? (CR vs LF/CR)
- The syntax formatter is failing on some expression and causing the application to crash. This would be specific to your content.
- The file is too big and complex for the formatter.
If you have the time and are able to, could you check your file with a hex editor for the line endings? Would you be able to duplicate the file, then on the duplicate, remove chunks of text until it opens? When it opens, open separately the removed text - does that crash?
It's big ask, and will help debug the issue. Thanks!