Closed THE-FYP closed 7 years ago
Hi @THE-FYP
You should not install package-deps from github, you should install install it from atom-package-deps
@ NPM
@steelbrain, I don't install package-deps from github, it was just an example. This problem occurs in any package that has dependencies installing from a repository. And this happens only when package installs through package-deps.
Example package: atom-defold-ide - it installs package autocomplete-lua, which has dependency that installs from repository.
atom-package-deps
under the hood checks if a package is installed or not, if it's not, it does apm install $package_name
. APM handles all the github auth and everything so it's most likely a bug in APM itself (just like the stack trace suggests)
Installing package directly from command prompt using apm install autocomplete-lua --production --color false
(the same command as package-deps
uses for the defold-ide installation, as i understand) does not cause any errors and succeeds.
After a thorough examination of the error, I'm blaming this one on env variables. Can you please post your env variables for your user? (make sure to remove any that contain sensitive info)
Sure.
From Atom:
APPDATA:"C:\Users\root\AppData\Roaming"
ATOM_HOME:"C:\Users\root\.atom"
BOOST_ROOT:"D:\Dev\SDK\boost\boost_1_60_0"
COMPUTERNAME:"FYP"
ComSpec:"C:\WINDOWS\system32\cmd.exe"
CommonProgramFiles:"C:\Program Files\Common Files"
CommonProgramFiles(x86):"C:\Program Files (x86)\Common Files"
CommonProgramW6432:"C:\Program Files\Common Files"
DXSDK_DIR:"D:\Dev\SDK\DXSDK"
FPS_BROWSER_APP_PROFILE_STRING:"Internet Explorer"
FPS_BROWSER_USER_PROFILE_STRING:"Default"
HOMEDRIVE:"C:"
HOMEPATH:"\Users\root"
LOCALAPPDATA:"C:\Users\root\AppData\Local"
LOGONSERVER:"\\FYP"
NODE_ENV:"production"
NODE_PATH:"C:\Users\root\AppData\Local\atom\app-1.16.0\resources\app.asar\exports"
OS:"Windows_NT"
PATHEXT:".COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY;.PYW"
PSModulePath:"C:\Program Files\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules;C:\Program Files\WindowsPowerShell\Modules\;C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\ResourceManager\AzureResourceManager\;C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\ServiceManagement\;C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\Storage\"
PUBLIC:"C:\Users\Public"
Path:"D:\Python27\;D:\Python27\Scripts;D:\Python\Scripts\;D:\Python\;C:\ProgramData\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\Calibre2\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;D:\Program Files\Installed Programs\CMake\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files (x86)\IVI Foundation\VISA\WinNT\Bin\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\Program Files (x86)\Microsoft SQL Server\110\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\120\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\130\DTS\Binn\;D:\Program Files\SDK\Tesseract-OCR;D:\Dev\SDK\Perl\c\bin;D:\Dev\SDK\Perl\perl\site\bin;D:\Dev\SDK\Perl\perl\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Skype\Phone\;C:\Program Files\Git\cmd;D:\Python\Scripts\;D:\Python\;D:\Program Files\Installed Programs\CMake\bin;D:\Program Files\Installed Programs\GnuWin32\bin;D:\Dev\SDK\LuaJIT-2.0.4\src;C:\Users\root\AppData\Local\Microsoft\WindowsApps;C:\Program Files (x86)\LuaRocks\;C:\Users\root\AppData\Local\atom\bin"
ProgramData:"C:\ProgramData"
ProgramFiles:"C:\Program Files"
ProgramFiles(x86):"C:\Program Files (x86)"
ProgramW6432:"C:\Program Files"
RWGDIR:"D:/Dev/RW/Graphics"
RWGSDK:"D:/Dev/RW/Graphics/rwsdk"
RWOESDK:"D:\Dev\RW/shared/OpenExport"
SDK_DIR:"D:\Dev\SDK"
SESSIONNAME:"Console"
SystemDrive:"C:"
SystemRoot:"C:\WINDOWS"
TEMP:"C:\Users\root\AppData\Local\Temp"
TESSDATA_PREFIX:"D:\Program Files\SDK\Tesseract-OCR\tessdata"
TMP:"C:\Users\root\AppData\Local\Temp"
USERDOMAIN:"FYP"
USERDOMAIN_ROAMINGPROFILE:"FYP"
USERNAME:"root"
USERPROFILE:"C:\Users\root"
VBOX_MSI_INSTALL_PATH:"D:\Program Files\Installed Programs\VBox\"
VS90COMNTOOLS:"D:\Program Files\Installed Programs\MSVCPP2008\Common7\Tools\"
VS110COMNTOOLS:"C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\Tools\"
VS120COMNTOOLS:"D:\Program Files\Installed Programs\MSVS2013\Common7\Tools\"
VS140COMNTOOLS:"D:\Program Files\Installed Programs\Visual Studio 2015\Common7\Tools\"
VSSDK140Install:"D:\Program Files\Installed Programs\Visual Studio 2015\VSSDK\"
WIX:"C:\Program Files (x86)\WiX Toolset v3.10\"
windir:"C:\WINDOWS"
From command prompt:
ALLUSERSPROFILE=C:\ProgramData
APPDATA=C:\Users\root\AppData\Roaming
BOOST_ROOT=D:\Dev\SDK\boost\boost_1_60_0
CommonProgramFiles=C:\Program Files\Common Files
CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
CommonProgramW6432=C:\Program Files\Common Files
COMPUTERNAME=FYP
ComSpec=C:\WINDOWS\system32\cmd.exe
DXSDK_DIR=D:\Dev\SDK\DXSDK
ELECTRON_ENABLE_LOGGING=YES
EXPECT_OUTPUT=YES
HOMEDRIVE=C:
HOMEPATH=\Users\root
LOCALAPPDATA=C:\Users\root\AppData\Local
LOGONSERVER=\\FYP
OS=Windows_NT
Path=D:\Python27\;D:\Python27\Scripts;D:\Python\Scripts\;D:\Python\;C:\ProgramData\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\Calibre2\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;D:\Program Files\Installed Programs\CMake\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files (x86)\IVI Foundation\VISA\WinNT\Bin\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\Program Files (x86)\Microsoft SQL Server\110\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\120\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\130\DTS\Binn\;D:\Program Files\SDK\Tesseract-OCR;D:\Dev\SDK\Perl\c\bin;D:\Dev\SDK\Perl\perl\site\bin;D:\Dev\SDK\Perl\perl\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Skype\Phone\;C:\Program Files\Git\cmd;D:\Program Files\Installed Programs\GnuWin32\bin;D:\Dev\SDK\LuaJIT-2.0.4\src;C:\Users\root\AppData\Local\Microsoft\WindowsApps;C:\Program Files (x86)\LuaRocks\;C:\Users\root\AppData\Local\atom\bin
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY;.PYW
ProgramData=C:\ProgramData
ProgramFiles=C:\Program Files
ProgramFiles(x86)=C:\Program Files (x86)
ProgramW6432=C:\Program Files
PROMPT=$P$G
PSARGS=--version
PSModulePath=%ProgramFiles%\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules;C:\Program Files\WindowsPowerShell\Modules\;C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\ResourceManager\AzureResourceManager\;C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\ServiceManagement\;C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\Storage\
PUBLIC=C:\Users\Public
RWGDIR=D:/Dev/RW/Graphics
RWGSDK=D:/Dev/RW/Graphics/rwsdk
RWOESDK=D:\Dev\RW/shared/OpenExport
SDK_DIR=D:\Dev\SDK
SystemDrive=C:
SystemRoot=C:\WINDOWS
TEMP=C:\Users\root\AppData\Local\Temp
TESSDATA_PREFIX=D:\Program Files\SDK\Tesseract-OCR\tessdata
TMP=C:\Users\root\AppData\Local\Temp
USERDOMAIN=FYP
USERDOMAIN_ROAMINGPROFILE=FYP
USERNAME=root
USERPROFILE=C:\Users\root
VBOX_MSI_INSTALL_PATH=D:\Program Files\Installed Programs\VBox\
VS110COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\Tools\
VS120COMNTOOLS=D:\Program Files\Installed Programs\MSVS2013\Common7\Tools\
VS140COMNTOOLS=D:\Program Files\Installed Programs\Visual Studio 2015\Common7\Tools\
VS90COMNTOOLS=D:\Program Files\Installed Programs\MSVCPP2008\Common7\Tools\
VSSDK140Install=D:\Program Files\Installed Programs\Visual Studio 2015\VSSDK\
windir=C:\WINDOWS
WIX=C:\Program Files (x86)\WiX Toolset v3.10\
Also i tested it on another computer and have the same issue. After that i asked my friend to check it and he has no problem, he uses Windows 7 and Atom v1.16.0 but 32-bit version, so maybe that's the case?
Hmmm, it seems apm
is expanding the environment in some manner when launched from a shell vs. executed directly.
This isn't an issue with the environment size missing parts of your %PATH%
as mine is larger than yours and it still fails... but in a different place. Yours is failing due to a missing ssh
, while mine fails later with a missing sh
(since I have ssh
in my PATH).
However, like you when I run apm install autocomplete-lua
it completes, and I can see it launching a sh.exe
, so apm
is doing something odd here...
Looked into this more, the only difference between this package and Atom's settings-view
in installing packages is this package uses exec
to spawn apm
, while settings-view
uses Atom's BufferedProcess
. Since the environment expansion provided from exec
isn't necessary as Atom is giving the full path, it might be best to remove that extra moving part and just use BufferedProcess
.
I can also reproduce this
Can you please publish the release, so i can test it?
Hi @THE-FYP I would love to
Delaying it by a day or two in case something else comes up that we have to include in the latest release.
Attempting to install a package with any dependency from repository instead of npm registry (e.g.
"package-deps": "github:steelbrain/package-deps"
instead of"package-deps": "latest"
) leads to the following error:Tested on Windows 7, Windows 10 and Linux, using the latest version of
package-deps
and Atom v1.16.0. Error occurs only in Windows. Example package: atom-defold-ide - it installs package autocomplete-lua, which has dependency that installs from repository.