Skip to content

"No editors found" even though Atom is installed #2585

Closed

Description

@mirenbz

Description

I just insalled GitHub Desktop and Atom, and when I try to set up Atom as de default external editor for Github Desktop it says "No editors found". I tries uninstalling and then installing Atom first, with no success.

Version

GitHub Desktop version: 0.8.0

OS version: MS Windows 6.1.7601

Steps to Reproduce

  1. Installed both GitHub Desktop and Atom
  2. On GitHub Desktop, File > Options > Advanced
  3. For "External editor" it says "No editors found. Install Atom?" even though Atom is installed and running properly.

Logs

I don't think there is anything relevant here, but still, latest log:

2017-08-30T07:27:23.899Z - warn: [ui] Unknown URL action: unknown - payload: {"name":"unknown","url":"--squirrel-firstrun"}
2017-08-30T07:27:25.500Z - error: [ui] Error checking for updates
Error: Command failed: 4294967295
System.AggregateException: Se han producido uno o varios errores. ---> System.Exception: Couldn't acquire lock, is another instance running
   en Squirrel.SingleGlobalInstance..ctor(String key, TimeSpan timeOut)
   en Squirrel.UpdateManager.<acquireUpdateLock>b__32_0()
   en System.Threading.Tasks.Task`1.InnerInvoke()
   en System.Threading.Tasks.Task.Execute()
--- Fin del seguimiento de la pila de la ubicaci�n anterior donde se produjo la excepci�n ---
   en System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   en System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   en Squirrel.UpdateManager.<CheckForUpdate>d__7.MoveNext()
--- Fin del seguimiento de la pila de la ubicaci�n anterior donde se produjo la excepci�n ---
   en System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   en System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   en Squirrel.Update.Program.<Download>d__7.MoveNext()
   --- Fin del seguimiento de la pila de la excepci�n interna ---
   en System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
   en System.Threading.Tasks.Task`1.GetResultCore(Boolean waitCompletionNotification)
   en System.Threading.Tasks.Task`1.get_Result()
   en Squirrel.Update.Program.executeCommandLine(String[] args)
   en Squirrel.Update.Program.main(String[] args)
   en Squirrel.Update.Program.Main(String[] args)
---> (N� de excepci�n interna 0) System.Exception: Couldn't acquire lock, is another instance running
   en Squirrel.SingleGlobalInstance..ctor(String key, TimeSpan timeOut)
   en Squirrel.UpdateManager.<acquireUpdateLock>b__32_0()
   en System.Threading.Tasks.Task`1.InnerInvoke()
   en System.Threading.Tasks.Task.Execute()
--- Fin del seguimiento de la pila de la ubicaci�n anterior donde se produjo la excepci�n ---
   en System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   en System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   en Squirrel.UpdateManager.<CheckForUpdate>d__7.MoveNext()
--- Fin del seguimiento de la pila de la ubicaci�n anterior donde se produjo la excepci�n ---
   en System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   en System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   en Squirrel.Update.Program.<Download>d__7.MoveNext()<---


    at AutoUpdater.emitError (C:\Users\[myusername]\AppData\Local\GitHubDesktop\app-0.8.0\resources\electron.asar\browser\api\auto-updater\auto-updater-win.js:58:24)
    at squirrelUpdate.download (C:\Users\[myusername]\AppData\Local\GitHubDesktop\app-0.8.0\resources\electron.asar\browser\api\auto-updater\auto-updater-win.js:34:21)
    at C:\Users\[myusername]\AppData\Local\GitHubDesktop\app-0.8.0\resources\electron.asar\browser\api\auto-updater\squirrel-update-win.js:89:14
    at ChildProcess.<anonymous> (C:\Users\[myusername]\AppData\Local\GitHubDesktop\app-0.8.0\resources\electron.asar\browser\api\auto-updater\squirrel-update-win.js:71:14)
    at emitTwo (events.js:106:13)
    at ChildProcess.emit (events.js:191:7)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
2017-08-30T07:28:53.184Z - info: [ui] Executing getConfigValueInPath: git config -z --global user.name (took 2.032s)
2017-08-30T07:50:49.383Z - info: [ui] Executing getConfigValueInPath: git config -z --global user.name (took 1.390s)
2017-08-30T08:02:58.762Z - info: [ui] Opt in reported.
2017-08-30T08:02:59.463Z - info: [ui] Stats reported.
2017-08-30T08:06:05.988Z - warn: [ui] Unknown URL action: unknown - payload: {"name":"unknown","url":"--squirrel-firstrun"}
2017-08-30T08:18:51.499Z - info: [ui] Executing getConfigValueInPath: git config -z --global user.name (took 6.442s)
2017-08-30T08:24:56.861Z - info: [ui] Executing getConfigValueInPath: git config -z --global user.name (took 1.306s)

Activity

  1. shiftkey commented on Aug 30, 2017

    @shiftkey
    Member

    @mberasategi thanks for the details. Can you tell me about how you have Atom installed?

    We probe this registry key to find the install location: HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\atom. Maybe I'm missing one of the installer options that Atom supports?

  2. added
    bug
    more-info-needed
    on Aug 30, 2017
  3. mirenbz commented on Sep 1, 2017

    @mirenbz
    Author

    Thanks for your reply @shiftkey . I just downloaded the installer from https://atom.io/ (64bit version) and run it. Install location as found in the registry key you mention is C:\Users\[myusername]\AppData\Local\atom.

  4. DRSAgile commented on Sep 2, 2017

    @DRSAgile

    Same issue; the registry entry for Atom is filled properly: the "InstallLocation" key has "C:\Users[myusername]\AppData\Local\atom" value.

    While it is still not fixed, can I force the connection with Atom "manually" in any other way?

    Also, can I connect it to Notepad++ instead of Atom if I chose so (also "manually" as the application itself does not offer such possibility with GUI)?

  5. shiftkey commented on Sep 3, 2017

    @shiftkey
    Member

    @mberasategi @DRSAgile The next thing to check alongside the registry entry is that the installation is unpacked as expected. Could you check that Atom added itself to your PATH and that the cmd file exists (I'm just running these commands in a Command Prompt shell):

    C:\Users\shiftkey>echo %PATH%
    // other entries
    C:\Users\shiftkey\AppData\Local\GitHubDesktop\bin;C:\Users\shiftkey\AppData\Local\atom\bin
    
    C:\Users\shiftkey>dir %LOCALAPPDATA%\atom\bin
     Volume in drive C has no label.
     Volume Serial Number is 1073-2740
    
     Directory of C:\Users\shiftkey\AppData\Local\atom\bin
    
    09/03/2017  12:12 PM    <DIR>          .
    09/03/2017  12:12 PM    <DIR>          ..
    09/03/2017  12:12 PM                68 apm
    09/03/2017  12:12 PM                65 apm.cmd
    09/03/2017  12:12 PM                75 atom
    09/03/2017  12:12 PM                58 atom.cmd
                   4 File(s)            266 bytes
                   2 Dir(s)  76,747,313,152 bytes free
    

    Also, can I connect it to Notepad++ instead of Atom if I chose so

    @DRSAgile this is not currently supported. See #2487 for that discussion.

  6. DRSAgile commented on Sep 3, 2017

    @DRSAgile

    @shiftkey Thanks for reply.

    Yes, the "%PATH%" is updated; the last two entried there are: "C:\Users[Username]\AppData\Local\GitHubDesktop\bin;C:\Users[Username]\AppData\Local\atom\bin"

    The dir command works also. The only difference is that free space is different (33 805 893 632).
    Atom itself works fine. I tried to restart everything, but it did not help either.

    Another issue is that I can not find an option to autopush changes to GitHub's server once I press "Commit" -- it is not convenient as I always forget to manually click to "push" at the top. Maybe I simply failed to find this option?

  7. mirenbz commented on Sep 4, 2017

    @mirenbz
    Author

    Hi @shiftkey , it turns out the Atom dir is not added to my path, and dir %LOCALAPPDATA%\atom\bin is not found...

    Actually, the app is not working too smoothly either. I takes ages for it to load (not that my computer is lightning fast either, but still). I will try reinstalling and see if it gets added to the path.

  8. shiftkey commented on Sep 4, 2017

    @shiftkey
    Member

    @mberasategi it sounds like something about your installation failed - there might be something in your %LOCALAPPDATA%\atom\SquirrelSetup.log that might shed light on what happened, but I think I'd need to send you over to the Atom issue tracker for further assistance.

  9. mirenbz commented on Sep 4, 2017

    @mirenbz
    Author

    @shiftkey OK. I'll try reinstalling as said and if it doesn't work I'll go to the Atom issue tracker. Thanks for your attention.

  10. Ben3eeE commented on Sep 4, 2017

    @Ben3eeE

    @mberasategi The bin folder not being created or modified on install is a known issue with the Atom installer /cc: atom/atom#11450

    You can try running atom --squirrel-updated from within the %LOCALAPPDATA%\atom folder. This should create the bin folder.

  11. shiftkey commented on Sep 5, 2017

    @shiftkey
    Member

    @DRSAgile

    Another issue is that I can not find an option to autopush changes to GitHub's server once I press "Commit" -- it is not convenient as I always forget to manually click to "push" at the top. Maybe I simply failed to find this option?

    Please open a fresh issue to talk about this - it's not relevant to the Atom issue we're investigating here.

  12. shiftkey commented on Sep 5, 2017

    @shiftkey
    Member

    @DRSAgile I'm still not 100% sure why we're not detecting the installation. We enumerate the keys at that location to verify it's the app we expect using the Publisher and DisplayName keys, maybe I'm missing some assumption:

    case ExternalEditor.Atom:
    return displayName === 'Atom' && publisher === 'GitHub Inc.'

    Could you run this command from a Powershell prompt and attach the output?

    > Get-Item HKCU:\Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\atom

    This is what it looks like for my 64-bit installation of 1.19.5:

    
    
        Hive: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall
    
    
    Name                           Property
    ----                           --------
    atom                           DisplayIcon          : C:\Users\shiftkey\AppData\Local\atom\app.ico
                                   DisplayName          : Atom
                                   DisplayVersion       : 1.19.5
                                   InstallDate          : 20170905
                                   InstallLocation      : C:\Users\shiftkey\AppData\Local\atom
                                   Publisher            : GitHub Inc.
                                   QuietUninstallString : "C:\Users\shiftkey\AppData\Local\atom\Update.exe" --uninstall -s
                                   UninstallString      : "C:\Users\shiftkey\AppData\Local\atom\Update.exe" --uninstall
                                   URLUpdateInfo        :
                                   EstimatedSize        : 179214
                                   NoModify             : 1
                                   NoRepair             : 1
                                   Language             : 1033
    
  13. DRSAgile commented on Sep 5, 2017

    @DRSAgile

    @shiftkey Thanks for reply.

    It looks like I have the same data, please see below.

    Could you please check the source code if it asks for elevation of privileges/permissions to go through the registry? Maybe the code you cited just receives nothing?

    Normally just reading the data from registry should not be an issue, but in my practice I witnessed weird cases where even reading from registry was not possible without certain permissions, especially with UAC-enabled Windows 10 (the reason why you only saw a couple of cases like mine is maybe because the most people turn the UAC off; GitHub desktop did not cause UAC promt). I am not a professional in this, so this is only my guess.


    PS C:\Windows\System32\WindowsPowerShell\v1.0> Get-Item HKCU:\Software\Microsoft\Windows\CurrentVersion\Uninstall\atom

    Hive: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall
    

    Name Property


    atom DisplayIcon : C:\Users[Username]\AppData\Local\atom\app.ico
    DisplayName : Atom
    DisplayVersion : 1.19.5
    InstallDate : 20170902
    InstallLocation : C:\Users[Username]\AppData\Local\atom
    Publisher : GitHub Inc.
    QuietUninstallString : "C:\Users[Username]\AppData\Local\atom\Update.exe" --uninstall
    -s
    UninstallString : "C:\Users[Username]\AppData\Local\atom\Update.exe" --uninstall
    URLUpdateInfo :
    EstimatedSize : 179214
    NoModify : 1
    NoRepair : 1
    Language : 1033

    PS C:\Windows\System32\WindowsPowerShell\v1.0>

  14. shiftkey commented on Sep 5, 2017

    @shiftkey
    Member

    Could you please check the source code if it asks for elevation of privileges/permissions to go through the registry? Maybe the code you cited just receives nothing?

    The code for this is invoking C:\Windows\System32\reg.exe and parsing that output:

    const proc = spawn(regPath, ['QUERY', key], {
    cwd: undefined,
    })

    You can test this doesn't require additional permissions by invoking it from a plain command prompt:

    > C:\Windows\system32\reg.exe QUERY HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall\atom
    
    HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall\atom
        DisplayIcon    REG_SZ    C:\Users\shiftkey\AppData\Local\atom\app.ico
        DisplayName    REG_SZ    Atom
        DisplayVersion    REG_SZ    1.19.5
        InstallDate    REG_SZ    20170905
        InstallLocation    REG_SZ    C:\Users\shiftkey\AppData\Local\atom
        Publisher    REG_SZ    GitHub Inc.
        QuietUninstallString    REG_SZ    "C:\Users\shiftkey\AppData\Local\atom\Update.exe" --uninstall -s
        UninstallString    REG_SZ    "C:\Users\shiftkey\AppData\Local\atom\Update.exe" --uninstall
        URLUpdateInfo    REG_SZ
        EstimatedSize    REG_DWORD    0x2bc0e
        NoModify    REG_DWORD    0x1
        NoRepair    REG_DWORD    0x1
        Language    REG_DWORD    0x409
    

    There's one note from the upstream project that inspired this around the Windows console not handling UTF-8 characters - it's a long shot, but is there any special characters in your username that we might not be parsing correctly? You've also not mentioned other editors (VSCode/Sublime) - if they're also installed, but not showing up in the list under Options | Advanced tab, then it might not be specific to the Atom installation.

  15. 26 remaining items

  16. shiftkey commented on Sep 14, 2017

    @shiftkey
    Member

    Also, I believe that both the "GitHub Desktop" and "Atom" Apps can still be considered in their Beta stage.

    @DOBRESCUMihai19 I'd love to get more details about what you believe is missing from Desktop. We're close to 1.0, and we've got a roadmap planned out for future updates, to give you an idea of where we're heading...

    EDIT: oops, this was meant for @DOBRESCUMihai19 - apologies @mberasategi!

  17. mirenbz commented on Sep 14, 2017

    @mirenbz
    Author

    Thanks @shiftkey , but that issue with the text editor of choice was the only flaw I found. I left Atom for later on and I'm currently using Sublime (which is what I used otherwise), and everything is fine. So I'm quite happy with Desktop.

    That quote was actually from @DOBRESCUMihai19 , which was who you meant to mention, probably 😉

  18. shiftkey commented on Sep 14, 2017

    @shiftkey
    Member

    @mberasategi you're right, I mentioned the wrong person. I've edited it again to clarify!

  19. shiftkey commented on Sep 18, 2017

    @shiftkey
    Member

    @DRSAgile I wonder if you're not also dealing with the same issue as #2735 - could you run chcp from your cmd.exe and see what it returns?

  20. DRSAgile commented on Sep 18, 2017

    @DRSAgile

    It looks like the same issue as CHCP besides the code itself does return non-ASCII characters just as in the case you referenced to. So yes, if you are using Regex to read the code page, simply filtering out everything besides digits would be enough for this all to work without issue.

  21. shiftkey commented on Sep 18, 2017

    @shiftkey
    Member

    @DRSAgile cool, I'll close this out as I think that's the only outstanding issue here. #2759 should go out in the next update.

  22. shiftkey commented on Sep 18, 2017

    @shiftkey
    Member

    For anyone else who discovers this discussion, please open a fresh issue rather than commenting further if you encounter an issue with the Atom integration.

  23. locked as resolved and limited conversation to collaborators on Jul 20, 2018
  24. unlocked this conversation on Sep 27, 2018
  25. BrainNotFoundException commented on Jan 1, 2021

    @BrainNotFoundException

    @mberasategi The bin folder not being created or modified on install is a known issue with the Atom installer /cc: atom/atom#11450

    You can try running atom --squirrel-updated from within the %LOCALAPPDATA%\atom folder. This should create the bin folder.

    yea this works.
    but for some reason i had to type atom --squirrel-update for it to work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugmore-info-needed

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions