Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

[PM] Installer steals file associations with no warning (for a few users) #6073

Closed
msssk opened this issue Nov 21, 2013 · 65 comments
Closed

Comments

@msssk
Copy link

msssk commented Nov 21, 2013

On Windows 7 the Brackets installer over-writes file associations. It should allow you to specify whether or not you want it to do this.

@peterflynn
Copy link
Member

@msssk That shouldn't happen. Which file extensions? What app were they assigned to before?

@peterflynn
Copy link
Member

Tentatively assigning @bchintx to do follow-up investigation once we have more info.

@ghost ghost assigned bchintx Nov 22, 2013
@aniforprez
Copy link

In my case it overwrote the file associations of MD, Lua, JSON, .properties files.

They were previously assigned to other text editors. MD, Lua and JSON where assigned to Sublime Text whereas .properties was assigned to Notepad.

@msssk
Copy link
Author

msssk commented Nov 22, 2013

I haven't investigated exhaustively, but my .js file association was changed as well as .sh.

@njx
Copy link
Contributor

njx commented Nov 22, 2013

We got a report of this on Twitter as well.

@peterflynn
Copy link
Member

High priority to investigate for Sprint 35.

@peterflynn
Copy link
Member

Adjusting title (was: "Installer does not prompt to set file associations")

@peterflynn
Copy link
Member

@msssk You've installed earlier versions of Brackets too, right? Did this just start happening with the Sprint 34 build?

We did have some installer changes in Sprint 34, but I'm having a really hard time seeing how the diff (https://github.com/adobe/brackets-shell/compare/sprint-33...sprint-34?w=1#diff-13) could in any way be causing this. We previously registered only for the Open With list, and we still register only for the Open With list... If that didn't cause bugs before I'm failing to see how it could now. @bchintx any ideas?

@peterflynn
Copy link
Member

Is it possible there's some other common app that uses the registry key SOFTWARE\Brackets and we're colliding with it? It's certainly a less unique reg key than we used to use...

@Krindi
Copy link

Krindi commented Nov 23, 2013

I just installed Brackets for the first time yesterday, Sprint 34, and did not have any file extensions changed without warning. This is on Windows 8.1, which just gives a prompt about having new programs that can open this file. May be a Windows 7 specific issue.

@peterflynn
Copy link
Member

@Krindi Yeah, this is definitely not the typical install experience for most users. I'll clarify the title.

@msssk
Copy link
Author

msssk commented Nov 23, 2013

@peterflynn I think the last time I installed it was Sprint 24.

@bchintx
Copy link
Contributor

bchintx commented Nov 25, 2013

@msssk @aniforprez The Brackets installer on Windows should only add Brackets as an available program in the "Open With..." context menu, when rt-clicking on a supported file type in Windows Explorer. We don't remove anyone else from the list and we shouldn't automatically take over any default associations.

So, perhaps I'm just misunderstanding what you're seeing. Can you please clarify with some detailed steps to describe the issue?

For example, after installing Brackets, I would expect the following to occur on Windows:

  1. launch Windows Explorer and browse to a file of a supported file type, such as .js.
  2. select and right-click the .js file and mouse-over the "Open With..." context menu item.

At this point, I would expect that you would see a list of programs, including "Brackets", above the last menu item of "Choose default program...". Of course, clicking "Brackets" would then launch Brackets and open the selected file. This is correct behavior.

Are you seeing something different? Or, perhaps, is your concern that the above behavior occurs at all -- ie. that the Brackets installer should have prompted you on install that it was going to add itself to the Open With... list?
@Krindi I think this is what you're referring to?

@aniforprez
Copy link

No, it took over completely as the default application for some file types. As in, if I double-click it, it opens in Brackets automatically for those file types and shows the Brackets icon for files of those few types. The files had been previously assigned as defaults to other text editing software.

This is slightly irritating, especially because it opens file types that have nothing to do with Brackets' intended functionality. For eg. .properties files.

@Krindi
Copy link

Krindi commented Nov 25, 2013

@bchintx Yes that's what I was referring to, just the Windows 8 version of the same effect. The next time you open something relevant a little overlay shows up in the corner informing you that you have new programs that can open that file type and offers to let you change your default program.

@pthiess
Copy link
Contributor

pthiess commented Nov 25, 2013

@gruehle Hi Glenn may you have a look at this while Bryan is out?

@njx
Copy link
Contributor

njx commented Nov 25, 2013

This was somehow tagged both "medium priority" and "high priority". We discussed it in bug review and agreed that it was high priority--we shouldn't be stealing file associations. However, we need to distinguish between people seeing the default file association change vs. just seeing it get added to the Open With list.

@bchintx
Copy link
Contributor

bchintx commented Nov 25, 2013

@njx @peterflynn @pthiess IMHO this isn't "stealing file associations". We're just adding ourselves as a candidate to open specific file types. We don't replace or remove other applications that may also be in the Open With... list, nor do we override any other apps that may have set themselves as the default editor for those file types.

As @Krindi points out, yes, Window 8.x will display a popup saying that another application is available to open a just opened file type. However, any other app would do the same if it registers itself as a candidate to open any individual file type.

IMHO, this isn't a med or high priority issue. I'd vote that this be a great enhancement request to the installer UI to allow the user to specify whether/which file extensions they'd like Brackets to register (or not register). I can create a user story in Trello, if that'd help.

@peterflynn
Copy link
Member

@bchintx Note that some users such as @aniforprez have reported that Brackets does replace other applications as the default Open gesture (not just on the Open With list).

I agree the issue @Krindi described is not a bug -- but the other reports seem much more serious.

@njx
Copy link
Contributor

njx commented Nov 25, 2013

Yes, and we had at least one report on Twitter of the same behavior @aniforprez is describing (Brackets taking over the default file association).

@bchintx
Copy link
Contributor

bchintx commented Nov 25, 2013

@peterflynn @njx Hmm. Ok. I'll setup a clean Windows image and investigate...

@bchintx
Copy link
Contributor

bchintx commented Jan 13, 2014

quick update: I'm able to reproduce the reported behavior if I install Brackets to a clean Win8 system -- ie. that since we install ourselves as the first and only Open With... application, then Win8 will go ahead and use us as the default editor for that file type. However, it there's at least one other application that's also in the Open With... list (by ProgID), then Brackets isn't being used as the default.

Also, I haven't (yet) been able to reproduce the problem where a Brackets installation actually steals the association from another previously installed application, but I'm still trying to reproduce this on different systems. (I haven't seen it on Win7 yet at all.)

For now, going ahead and clearing the milestone and dropping to Med priority.

@le717
Copy link
Contributor

le717 commented Jan 13, 2014

I have this issue, Windows 8.1 Core x64. I'm on Sprint 35, only previous installation was Sprint 34. I know for sure Brackets now has the file association for JSON (as in, the file opens in Brackets when clicked and has the Brackets logo). Previously it had no association. I'll check for any others when I boot my laptop.

I am a bit experienced with Windows installers using Inno Setup and I have read multiple NSIS installer scripts in the past (simply learning how they are written. Those things are difficult to write), so I'll take a quick peek at Bracket's and see if I can catch anything that could cause this stealing. You're still using the standard msiexec.exe stuff to compile it and not WiX, right? NVM that question.

@peterflynn
Copy link
Member

@le717 I think what you're seeing is expected behavior. If no app was previously associated with the file type, my understanding is that (at least on Win 8.x), merely registering an app for 'open with' on that filetype sets it as the default as well.

The subject of this bug the case where there was already a file association pointing to some other app, but Brackets overwrites the association when installed. We haven't been able to reproduce that, but we've gotten a couple isolated reports (e.g. from @aniforprez) of it happening.

@le717
Copy link
Contributor

le717 commented Jan 14, 2014

@aniforprez How did you associate the file extensions with Sublime? Using regedit or the method described here? I'm attempting to recreate this bug as well based on a wild idea I had.

@peterflynn You're right, that is how it is supposed to act. I guess I did not have my techie and programmer hats on right then.

One thing I am definitely seeing is number of file associations the installer makes "Open With" strings for. Take for example .py and .pyw. As you may know, these are Python scripts. Yes, Brackets allows editing of them and there are even pep8 and linter plugins, but most of the time Python programmers (and this is coming from a Python programmer) have a more dedicated editor when working in that language, such as PyDev, PyScripter, Aptana or some editor that incorporates PyDev, NINJA-IDE, etc. My point is just because Brackets can support those files may not mean the installer should attempt to support them by creating the strings. Removing files that are not core to Brackets' mission (web design) would help remedy what @aniforprez said:

This is slightly irritating, especially because it opens file types that have nothing to do with Brackets' intended functionality. For eg. .properties files.

@marcelgerber
Copy link
Contributor

I appreciate @le717's idea, too.
Not to register some of the languages Brackets supports would be a cool thing, for example, I wouldn't ever had the idea of editing a .ini file with Brackets.

@marcelgerber
Copy link
Contributor

Looks like this is still a problem:
http://blog.brackets.io/2014/03/18/brackets-sprint-37-build/#comment-2448

@bchintx bchintx added this to the Brackets 1.0 milestone Mar 20, 2014
@bchintx
Copy link
Contributor

bchintx commented Jun 27, 2014

@SAplayer Good news! Using a clean Windows 7 VM, I was able to recreate the icon behavior that you reported in your comment above. Apparently, the PerceivedType reg key that we were installing was causing the associated icon to be overridden in the scenario you described. Since we don't "really" need that key in order to support launching Brackets, I've removed it from our Windows installer and submitted it as brackets-shell Pull Request.

Hopefully, this will address, at least some, of the concerns expressed in this issue thread. For the rest, hopefully, having a selectable UI in the installer will address the rest.

@pthiess
Copy link
Contributor

pthiess commented Aug 17, 2014

@marcelgerber @bchintx Can I close this issue - is it useful to open a new issue to track remaining issues if any?
Thanks a ton for your feedback.
Peter :)

@bchintx
Copy link
Contributor

bchintx commented Aug 18, 2014

IMHO we can close it since the other aspects of this issue should be covered in the Trello card or other issues mentioned above. Closing...

@agustisanchez
Copy link

Is this bug really fixed? I installed Brackets a couple of months ago on my MacBook (OS X 10.11.2) and it overwrote ALL file extensions.
I'm still resetting them back manually :(

@mostafazs
Copy link

i have the same issue
install Brackets.Release.1.5.msi.. and all below mentioned files are now open by bracket by double-click on them.

I also use Notepad++ & Eclips for several years, but for example notepad++ allow me to config file association, on settings page.but bracket change it without my permission.

Also try correct this problem by deleting HKEY_LOCAL_MACHINE\SOFTWARE\Brackets\Capabilities\FileAssociations keys from registry ...but not work ...at last i delete bracket from my system.

I also install Bracket on clean win7 VM and problem exist ... what happen? is this bug fixed or somethings wrong with our systems.

More Info:
Windows 7 Ultimate 32-bit
Bracket 1.5

Some of extentions:
.php
.json
.yml
.shjson
.sh
.md
.java

@yoniholmes
Copy link

The latest Brackets at time of writing (1.5) also over-wrote my 'default application' for several key programming language extensions without any prompt on my machine running OSX 10.10.5 (Yosemite). Rather irritating! Same issue at #9927 #9014.

To be clear, on OSX when I right click on files such as .css, .js, .json, and select 'Open With' I see a list of compatible programs with Brackets at the top listed as 'Brackets (default)'. Double clicking on a file with one of those extensions therefore opens them in Brackets instead of the application that I actually want to open them and would have opened them had I not installed Brackets..

@le717
Copy link
Contributor

le717 commented Feb 1, 2016

No, this has not yet been fixed. It was merely closed and put on the backlog.

If you or someone you know can work with WiX installers, you can always send them our way to help fix the installer. IMO, the file association options should work like the VLC installer.

I have put up a PR for one short-term but helpful remedy, removing unnecessary file associations, at adobe/brackets-shell#547. Please show your support for it (and give feedback on files that should/should not be associated) and hopefully it can be merged very soon (v1.7 would be nice...).

@yoniholmes
Copy link

Hi Caleb, thanks for your reply. Just to be clear, the issue I was experiencing was in Mac OSX, not in Windows. In my view (and I'm not sure what's technically possible), rather than reducing the number of extensions as a solution, a better solution would be:

  1. Show the user a prompt so that they can accept or decline Bracket's desire to override file extensions
  2. Have a menu setting that's always available to allow users to apply / revoke it as the default application for a given set of file extensions
  3. (Optional) have a checkbox list of file extensions for which Brackets should be the default application

The above would make for a better user experience, give users total control, as opposed to frustrating them when Brackets overrides defaults without asking.

Hope it helps,

Thanks,

Jonathan

#12180

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests