You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 6, 2021. It is now read-only.
Repository navigation
This repository was archived by the owner on Sep 6, 2021. It is now read-only.
"Error opening file" message not very helpfulΒ #7850
Today I got a "Error opening file" error dialog when trying to open a file. The dialog reads: "An error occurred when trying to open the file {{file_name_here}}. The file could not be read."
I'm very confused by the error. I've checked the file's permissions. And I've checked the file's integrity. I tried opening the file in other editors (without any issue). But Brackets is still unable to load this particular file. The development console doesn't give me any additional info either.
Is there any way to improve the error dialog to give me a little more information about what error the file system returned? Something that will give me more insight into why the file can't be loaded in Brackets.
@globexdesigns If you're on Mac or if you're on a bleeding-edge git copy on Windows, try upgrading to the newly-released Sprint 39 build.
I suspect the file you're trying to open is not using UTF-8 encoding. Brackets currently only supports UTF-8. The new Sprint 39 build gives a much more clear error message in this case.
Indeed. Sprint 39 tells me: "An error occurred when trying to open the file {{file_name_here}}. The file is not UTF-8 encoded text.".
Just out of curiosity -- can you recommend how I would go about fixing the file so that it can be read? Is there some other text editor that can help me convert the encoding?
Reviewed. In order to make it clearer that this is a current limitation in Brackets, let's change the second sentence to say: "Brackets currently only supports UTF-8 encoded text files."
Hi there, I'm going to submit a pull request for this. I've read through the brackets contributing docs. I'll tag up with you folks on usenet/irc before I take on anything bigger than a starter bug. Thanks!
edit: Should i only put issue #s in pull requests, and keep them out of commit messages?
Activity
peterflynn commentedon May 15, 2014
@globexdesigns If you're on Mac or if you're on a bleeding-edge git copy on Windows, try upgrading to the newly-released Sprint 39 build.
I suspect the file you're trying to open is not using UTF-8 encoding. Brackets currently only supports UTF-8. The new Sprint 39 build gives a much more clear error message in this case.
EvHaus commentedon May 16, 2014
Indeed. Sprint 39 tells me: "An error occurred when trying to open the file {{file_name_here}}. The file is not UTF-8 encoded text.".
Just out of curiosity -- can you recommend how I would go about fixing the file so that it can be read? Is there some other text editor that can help me convert the encoding?
marcelgerber commentedon May 17, 2014
Notepad++ can convert your files, and ST has
Save with Encoding.ingorichter commentedon May 19, 2014
In Sprint 39 we have introduced a new error message to let the user know that we can't open a binary or non utf-8 file.
njx commentedon May 19, 2014
Reviewed. In order to make it clearer that this is a current limitation in Brackets, let's change the second sentence to say: "Brackets currently only supports UTF-8 encoded text files."
njx commentedon May 19, 2014
Marking starter bug, low priority, since it's just changing the text.
h1w4y commentedon May 24, 2014
Hi there, I'm going to submit a pull request for this. I've read through the brackets contributing docs. I'll tag up with you folks on usenet/irc before I take on anything bigger than a starter bug. Thanks!
edit: Should i only put issue #s in pull requests, and keep them out of commit messages?
redmunds commentedon May 30, 2014
Confirmed. Closing.