Debug -> Reload Without Extensions? In Ubuntu 16.04 with Xfce4.12 as my DE, I am unable to open files in Brackets by right clicking them in Thunar/my desktop and then clicking Open With Brackets. Brackets opens, but the file does not. This is a pretty high priority bug in my opinion as being able to open up new text files by right clicking on them and selecting Open With is quite important for a text editor.
Expected behavior: I expect the file to open inside of Brackets.
Actual behavior: Brackets opens, but the file does not. It simply opens the last file(s) that were in open in Working Files, or no files if there were not any files open in Working Files.
Ubuntu 16.04 LTS with Xfce4.12
Brackets 1.11
I was NOT able to replicate this on Windows 10, Open With Brackets works as expected on Windows 10.
Has anyone been able to replicate this? I would like to know if others are experiencing this or if it is just me.
Happened to me as well. Same version of brackets and SO
I also have this issue on 17.04 openbox
I see that there's a new Linux release of Brackets, version 1.12. Any chance that this issue is being looked into for 1.12?
CC: @nethip
@kenstuddy We have refreshed the Brackets Linux installer builds so the version is still 1.11. You could get the latest installers from http://brackets.io and try installing the package.
Regarding the issue, I am not sure we will be able to pick up this specific item for 1.12.
I am using Brackets 1.11 and Linux Mint 18.3 KDE. When I right click on an HTML file (for example) Brackets does open, but the file I clicked is not loaded into the editor, which is not what I would expect to happen. Oddly it has open a file that I am not currently working on in the editor, nor the one I clicked on.
Pinging @rajnishb for this work item. This needs to be supported by Brackets on Linux. We need to prioritize this work item for 1.13. I have added to the release tasks tentatively so that @rajnishb can prioritize the work item.
I am just getting started in coding (again, actually) and would be glad to help @rajishb with this. I assume this part of the code base is not in javascript, but I can test, research or experiment. :-)
@WausauBill Awesome! That would be really helpful. You are right about that part of code not being part of Javascript. It requires a little research from the OS side and also about how we integrate that in brackets-shell, the uber container for the Brackets application.
Hi @nethip ... A little more investigations shows that, pretty much, opening files from a file manager in Linux with Brackets is completely broken. Here are some various circumstances and what happens.
Right Click/"Open With" If Brackets is not running, it opens the application but the file that was selected in file manager does not open. When Brackets opens it has the last files used open in the editor panes. If Brackets is running it opens another instance with no files open, but does not open the selected file.
Dragging File to Brackets: If I drag a file from the file manager to Brackets, the "plus sign" on the file (the one that tells you that it is OK to drag and drop the file) does appear when the file is in the Brackets window, but the file does not load/open in Brackets.
Set Brackets as default application: Slightly different. If Brackets is closed it opens, but with no files open in the editing panes, does not open clicked file. If an instance of Bracket is open, another instance opens, with no files open, does not open clicked file.
Finally, I tried an XDG-Open from the terminal. It behaves as above, same as clicking on a file in the file manager with Brackets selected as the default application for the file type clicked.
It seems to me that the operating system is sending the correct input to Brackets, but there is some kind of flaw in the file handling system in the shell. Everything thing seems to be fine from the OS side, the icons indicate the operations that the OS is doing (for example, opening the application) but at the end the files simply don't open in Brackets.
I am not sure where to look in the shell to see if perhaps a module is missing or misnamed.
I don't know how similar the apps are and if Atom is using a similar application shell, but all of these file operations do work correctly in Atom.
More information on the problem:
When I start Brackets with no files open I get these 2 error messages in the console and timeline:
**NodeDebugUtils.js:111 [node-error 10:50:54 AM] nodeSocketTransport: Error on live preview server creation: Error: listen EADDRINUSE 0.0.0.0:8123handleLogEvent @ NodeDebugUtils.js:111
Failed to clear temp storage: It was determined that certain files are unsafe for access within a Web application, or that too many calls are being made on file resources. SecurityError**
Same two errors when starting Brackets when clicking on a file in file manager to open specific file type.
When I try and drag and drop a file, I get this error message in the console:
Uncaught TypeError: Cannot read property 'isFile' of null
Which is in this function of the code:
From the file DragAndDrop.js
/**
* Returns true if the drag and drop items contains valid drop objects.
* @param {Array.
* @return {boolean} True if one or more items can be dropped.
*/
function isValidDrop(items) {
var i, len = items.length;
for (i = 0; i < len; i++) {
if (items[i].kind === "file") {
var entry = items[i].webkitGetAsEntry();
if (entry.isFile) {
// If any files are being dropped, this is a valid drop
return true;
} else if (len === 1) {
// If exactly one folder is being dropped, this is a valid drop
return true;
}
}
}
// No valid entries found
return false;
}
The UnCaught Type error is on the line: if (entry.isFile) {
And it seems to happen 22 times, perhaps somehow 22 items got into the Array.
According to StackOverflow the security error that appears all the time may be from a validity check entering an infinite loop or returning invalid results.
This jsFiddle seems to be similar to the issue in Brackets, but I am not experienced enough to see where they differ. The fiddle works (shows the proper result for dropped files) for me on Linux.
https://jsfiddle.net/x85vtnef/1/
I am wondering at this point if there are 2 different issues, the drag and drop perhaps being one and the files not opening from clicking the file manager another.
I can now definitely say that "Open With" and "drag and drop" are two separate issues.
There was a comment on Brackets not working in Ubuntu #11111 that Linux users should try the Brackets-Electron version .
I downloaded and installed this version and found that, in fact, the "Open With" does work correctly. The developer console does not show the errors that "regular" Brackets does:
**NodeDebugUtils.js:111 [node-error 10:50:54 AM] nodeSocketTransport: Error on live preview server creation: Error: listen EADDRINUSE 0.0.0.0:8123handleLogEvent @ NodeDebugUtils.js:111
Failed to clear temp storage: It was determined that certain files are unsafe for access within a Web application, or that too many calls are being made on file resources. SecurityError**
However drag and drop does NOT work in Brackets-Electron -- it throws slightly different errors in the drag and drop handlers:
Uncaught TypeError: Cannot read property 'isFile' of null
at isValidDrop (DragAndDrop.js:51)
at HTMLBodyElement.handleDragOver (DragAndDrop.js:194)
at HTMLBodyElement.dispatch (jquery-2.1.3.min.js:formatted:1883)
at HTMLBodyElement.r.handle (jquery-2.1.3.min.js:formatted:1768)
It seems to be a fork of the Brackets project, has it's own repository, and obviously at least in regard to this issue, some different code in it. :-)
Any progress??
I am having the exact same issue on Ubuntu 16.04 and Brackets Release 1.12 build 1.12.0-17621 (release d3b783b99) - build timestamp: Thu Feb 01 2018 12:36:24 GMT+0000
Files wont open up when double clicking or dragging files onto brackets..
Super frustrating...
No updates on this, eh?
latest Brackets 1.12 still completely useless on Ubuntu 16.04 :(
Any more progress made with this?
CC: @WausauBill
CC: @nethip
I gave up on this and installed VS.Code..
@kenstuddy Apologies for the late reply. I could not find time to get onto this! But when I get a chance I will have a look at it.
Same is happening to me too. I am using Ubuntu 16.04 LTS and the bracket version is 1.13.
@Cipher1X - just delete Brackets and install VSCode.. much better and no issues..
This is also happening in Ubuntu 18.04.
Yup.. brackets on any Ubuntu install is pretty much useless..
Doesn't look like anyone cares either.
Your best bet is to install visual studio code .
This is also happening in Linux Mint 18/3 - Brackets (sprint 13 build 1.13.0-17696 (release 49d29a8bc) )
I just sent an email to [email protected] with the link to this issue. Please do the same and they might look into it if they get enough requests.
LOL - I have given up on this.
Just install visual studio code, you will thank me later.. it works on all platforms with much better support and plugins..
Brackets is dead to me :p
Same on 19.10. I do not want to give up on Brackets and it would be very nice if someone from the dev team could stop by to let us know if a fix is coming or not. Would highly appreciate them for taking their time to update us.
@vikobeibe - dude, its been broken for 3 years.. its clear that it will never get fixed.
Just give it up and go with VSCODE, its free and a thousand times better..
I have the same problem on Ubuntu 20.04
I can reproduce the same behavior in Brackets 1.14.1 with Dolphin file manager. Ubuntu 18.04, KDE 5.44.0, Plasma 5.12.6. If I press Debug -> Show Developer Tools -> Console after trying to open a file I see this error message
NodeDebugUtils.js:111 [node-error 19:31:15] nodeSocketTransport: Error on live preview server creation: Error: listen EADDRINUSE 0.0.0.0:8123
I tested it without extensions.
Most helpful comment
@kenstuddy Apologies for the late reply. I could not find time to get onto this! But when I get a chance I will have a look at it.