AnacondaRecipes / scikit-learn-feedstock

A conda-smithy repository for scikit-learn.
BSD 3-Clause "New" or "Revised" License
0 stars 2 forks source link

scikit-learn-0.24.2-py38hf11a4ad_0 broken #5

Closed ericpre closed 3 years ago

ericpre commented 3 years ago

For example: https://dev.azure.com/ericpre/hyperspy/_build/results?buildId=1579&view=logs&j=32edd453-ed69-5a2f-b70b-23152512c6ed&t=d8b436e5-01fe-5ab5-0b75-76dd486489bd

ERROR conda.core.link:_execute(699): An error occurred while installing package 'defaults::scikit-learn-0.24.2-py38hf11a4ad_0'.
Rolling back transaction: ...working... done

LinkError: post-link script failed for package defaults::scikit-learn-0.24.2-py38hf11a4ad_0
location of failed script: C:\Miniconda\envs\test_env\Scripts\.scikit-learn-post-link.bat
==> script messages <==
<None>
==> script output <==
stdout: 
stderr: find: '/I': No such file or directory
find: 'win-64': No such file or directory
--- Logging error ---

Traceback (most recent call last):

  File "C:\Miniconda\lib\site-packages\conda\gateways\logging.py", line 149, in emit

    self.flush()

  File "C:\Miniconda\lib\logging\__init__.py", line 1065, in flush

    self.stream.flush()

OSError: [Errno 22] Invalid argument

Call stack:

  File "C:\Miniconda\Scripts\conda-script.py", line 12, in <module>

    sys.exit(main())

  File "C:\Miniconda\lib\site-packages\conda\cli\main.py", line 152, in main

    return conda_exception_handler(_main, *args, **kwargs)

  File "C:\Miniconda\lib\site-packages\conda\exceptions.py", line 1371, in conda_exception_handler

    return_value = exception_handler(func, *args, **kwargs)

  File "C:\Miniconda\lib\site-packages\conda\exceptions.py", line 1079, in __call__
ericpre commented 3 years ago

@adipietro18, @chenghlee, the post link script added in https://github.com/AnacondaRecipes/scikit-learn-feedstock/pull/4 seems to be broken.

chenghlee commented 3 years ago

@ericpre: what version of windows are you running this on, and are you using powershell or cmd?

ericpre commented 3 years ago

This is on azure pipeline with this step running this bash script.

From the azure pipeline output, the OS: Microsoft Windows Server 2019 10.0.17763

Could it be that it running conda install of such package doesn't play well with the bash task on azure pipeline?

chenghlee commented 3 years ago

It's not a conda install issue. It's that we assume that post-link.bat runs using CMD or PowerShell, and as a result, that find refers to the Windows command and not to the NIX command. My guess is that bash on Windows/Azure sets its $PATH so the NIX command is found first.

Is there a way for you to check to if either the $WINDIR or $SYSTEMROOT environment variable is defined in that bash environment and if so, that $WINDIR\System32\find.exe exists? If so, we'll patch the post link script to invoke the "correct" find using its full path.

ericpre commented 3 years ago

This is what I have got from https://dev.azure.com/ericpre/ci-scripts/_build/results?buildId=1598&view=logs&j=32edd453-ed69-5a2f-b70b-23152512c6ed&t=d8b436e5-01fe-5ab5-0b75-76dd486489bd

Both $WINDIR and $SYSTEMROOT variable exists. $WINDIR\System32\find.exe exists too and which find returns /usr/bin/find.

script:

    echo "Display WINDIR"
    echo "$WINDIR"
    echo "Display SYSTEMROOT"
    echo "$SYSTEMROOT"
    echo "ls $WINDIR"
    ls $WINDIR
    echo "ls $SYSTEMROOT"
    ls $SYSTEMROOT
    echo "Which find"
    which find
    echo "ls $WINDIR\System32\find.exe"
    ls "$WINDIR\System32\find.exe"

Relevant output:

2021-05-25T16:08:44.4353958Z Display WINDIR
2021-05-25T16:08:44.4355018Z C:\Windows

2021-05-25T16:08:44.4356067Z Display SYSTEMROOT
2021-05-25T16:08:44.4357083Z C:\Windows

2021-05-25T16:08:44.5347468Z Which find
2021-05-25T16:08:44.5641552Z /usr/bin/find

2021-05-25T16:08:44.5649014Z ls C:\Windows\System32\find.exe
2021-05-25T16:08:44.5865317Z C:\Windows\System32\find.exe
raw ouput

``` 2021-05-25T16:08:44.0145896Z ##[section]Starting: Debug bash task 2021-05-25T16:08:44.0326462Z ============================================================================== 2021-05-25T16:08:44.0327273Z Task : Bash 2021-05-25T16:08:44.0327652Z Description : Run a Bash script on macOS, Linux, or Windows 2021-05-25T16:08:44.0328169Z Version : 3.182.0 2021-05-25T16:08:44.0328484Z Author : Microsoft Corporation 2021-05-25T16:08:44.0330368Z Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/bash 2021-05-25T16:08:44.0331018Z ============================================================================== 2021-05-25T16:08:44.2865031Z Generating script. 2021-05-25T16:08:44.3243471Z [command]"C:\Program Files\Git\bin\bash.exe" --noprofile --norc -c pwd 2021-05-25T16:08:44.3822480Z /d/a/_temp 2021-05-25T16:08:44.3898700Z ========================== Starting Command Output =========================== 2021-05-25T16:08:44.3912784Z [command]"C:\Program Files\Git\bin\bash.exe" --noprofile --norc /d/a/_temp/b4f70322-d1d9-4f62-9408-41b417f01816.sh 2021-05-25T16:08:44.4353958Z Display WINDIR 2021-05-25T16:08:44.4355018Z C:\Windows 2021-05-25T16:08:44.4356067Z Display SYSTEMROOT 2021-05-25T16:08:44.4357083Z C:\Windows 2021-05-25T16:08:44.4357802Z ls C:\Windows 2021-05-25T16:08:44.5008575Z ADFS 2021-05-25T16:08:44.5009657Z AppReadiness 2021-05-25T16:08:44.5010560Z BitLockerDiscoveryVolumeContents 2021-05-25T16:08:44.5011562Z Boot 2021-05-25T16:08:44.5012414Z Branding 2021-05-25T16:08:44.5013297Z CbsTemp 2021-05-25T16:08:44.5014232Z Containers 2021-05-25T16:08:44.5015148Z Cursors 2021-05-25T16:08:44.5016657Z DfsrAdmin.exe 2021-05-25T16:08:44.5019007Z DfsrAdmin.exe.config 2021-05-25T16:08:44.5020667Z DigitalLocker 2021-05-25T16:08:44.5021633Z Downloaded Program Files 2021-05-25T16:08:44.5022494Z DtcInstall.log 2021-05-25T16:08:44.5023319Z ELAMBKUP 2021-05-25T16:08:44.5024196Z Fonts 2021-05-25T16:08:44.5025055Z Globalization 2021-05-25T16:08:44.5025905Z Help 2021-05-25T16:08:44.5027013Z HelpPane.exe 2021-05-25T16:08:44.5027999Z IME 2021-05-25T16:08:44.5028736Z INF 2021-05-25T16:08:44.5029692Z IdentityCRL 2021-05-25T16:08:44.5030741Z ImmersiveControlPanel 2021-05-25T16:08:44.5031750Z InputMethod 2021-05-25T16:08:44.5032873Z Installer 2021-05-25T16:08:44.5034030Z InteractiveVMWorkingDir 2021-05-25T16:08:44.5035039Z L2Schemas 2021-05-25T16:08:44.5036041Z LiveKernelReports 2021-05-25T16:08:44.5037119Z Logs 2021-05-25T16:08:44.5038257Z Microsoft.NET 2021-05-25T16:08:44.5039321Z Migration 2021-05-25T16:08:44.5040146Z ModemLogs 2021-05-25T16:08:44.5041130Z OCR 2021-05-25T16:08:44.5042077Z OEM 2021-05-25T16:08:44.5043247Z Offline Web Pages 2021-05-25T16:08:44.5044251Z PFRO.log 2021-05-25T16:08:44.5045305Z PLA 2021-05-25T16:08:44.5046314Z Panther 2021-05-25T16:08:44.5047366Z Performance 2021-05-25T16:08:44.5048306Z PolicyDefinitions 2021-05-25T16:08:44.5049298Z Prefetch 2021-05-25T16:08:44.5050239Z PrintDialog 2021-05-25T16:08:44.5051247Z Provisioning 2021-05-25T16:08:44.5052415Z Registration 2021-05-25T16:08:44.5053320Z RemotePackages 2021-05-25T16:08:44.5054236Z Resources 2021-05-25T16:08:44.5055200Z SKB 2021-05-25T16:08:44.5056163Z SchCache 2021-05-25T16:08:44.5057365Z ServerDataCenter.xml 2021-05-25T16:08:44.5058425Z ServiceProfiles 2021-05-25T16:08:44.5059773Z ServiceState 2021-05-25T16:08:44.5060731Z Setup 2021-05-25T16:08:44.5061897Z ShellComponents 2021-05-25T16:08:44.5063249Z ShellExperiences 2021-05-25T16:08:44.5064302Z SoftwareDistribution 2021-05-25T16:08:44.5065288Z Speech 2021-05-25T16:08:44.5066833Z Speech_OneCore 2021-05-25T16:08:44.5067980Z SysWOW64 2021-05-25T16:08:44.5068999Z System 2021-05-25T16:08:44.5070121Z System32 2021-05-25T16:08:44.5071120Z SystemApps 2021-05-25T16:08:44.5072077Z SystemResources 2021-05-25T16:08:44.5073023Z TAPI 2021-05-25T16:08:44.5073918Z Tasks 2021-05-25T16:08:44.5074901Z Temp 2021-05-25T16:08:44.5075837Z TextInput 2021-05-25T16:08:44.5076863Z Vss 2021-05-25T16:08:44.5077624Z WMSysPr9.prx 2021-05-25T16:08:44.5080026Z WaaS 2021-05-25T16:08:44.5084029Z Web 2021-05-25T16:08:44.5084887Z WinSxS 2021-05-25T16:08:44.5085950Z WindowsShell.Manifest 2021-05-25T16:08:44.5087347Z WindowsUpdate.log 2021-05-25T16:08:44.5089498Z appcompat 2021-05-25T16:08:44.5090502Z apppatch 2021-05-25T16:08:44.5091356Z assembly 2021-05-25T16:08:44.5092247Z bcastdvr 2021-05-25T16:08:44.5093285Z bfsvc.exe 2021-05-25T16:08:44.5094328Z bootstat.dat 2021-05-25T16:08:44.5095600Z debug 2021-05-25T16:08:44.5097027Z diagnostics 2021-05-25T16:08:44.5098015Z drivers 2021-05-25T16:08:44.5098991Z en-US 2021-05-25T16:08:44.5099993Z explorer.exe 2021-05-25T16:08:44.5101188Z hh.exe 2021-05-25T16:08:44.5102259Z iis.log 2021-05-25T16:08:44.5103213Z lsasetup.log 2021-05-25T16:08:44.5104265Z media 2021-05-25T16:08:44.5105427Z mib.bin 2021-05-25T16:08:44.5106617Z notepad.exe 2021-05-25T16:08:44.5107451Z py.exe 2021-05-25T16:08:44.5108415Z pyshellext.amd64.dll 2021-05-25T16:08:44.5109441Z pyw.exe 2021-05-25T16:08:44.5110441Z regedit.exe 2021-05-25T16:08:44.5111390Z rescache 2021-05-25T16:08:44.5112308Z schemas 2021-05-25T16:08:44.5113239Z security 2021-05-25T16:08:44.5114352Z servicing 2021-05-25T16:08:44.5115679Z splwow64.exe 2021-05-25T16:08:44.5117088Z symbols 2021-05-25T16:08:44.5118135Z system.ini 2021-05-25T16:08:44.5119117Z tracing 2021-05-25T16:08:44.5120418Z twain_32 2021-05-25T16:08:44.5121564Z twain_32.dll 2021-05-25T16:08:44.5122533Z win.ini 2021-05-25T16:08:44.5123665Z winhlp32.exe 2021-05-25T16:08:44.5124583Z write.exe 2021-05-25T16:08:44.5125570Z ls C:\Windows 2021-05-25T16:08:44.5229735Z ADFS 2021-05-25T16:08:44.5231346Z AppReadiness 2021-05-25T16:08:44.5232426Z BitLockerDiscoveryVolumeContents 2021-05-25T16:08:44.5234582Z Boot 2021-05-25T16:08:44.5238098Z Branding 2021-05-25T16:08:44.5239059Z CbsTemp 2021-05-25T16:08:44.5240105Z Containers 2021-05-25T16:08:44.5241052Z Cursors 2021-05-25T16:08:44.5241884Z DfsrAdmin.exe 2021-05-25T16:08:44.5243580Z DfsrAdmin.exe.config 2021-05-25T16:08:44.5245477Z DigitalLocker 2021-05-25T16:08:44.5246533Z Downloaded Program Files 2021-05-25T16:08:44.5247443Z DtcInstall.log 2021-05-25T16:08:44.5248186Z ELAMBKUP 2021-05-25T16:08:44.5248944Z Fonts 2021-05-25T16:08:44.5249711Z Globalization 2021-05-25T16:08:44.5250519Z Help 2021-05-25T16:08:44.5251651Z HelpPane.exe 2021-05-25T16:08:44.5252648Z IME 2021-05-25T16:08:44.5253766Z INF 2021-05-25T16:08:44.5254943Z IdentityCRL 2021-05-25T16:08:44.5255944Z ImmersiveControlPanel 2021-05-25T16:08:44.5257615Z InputMethod 2021-05-25T16:08:44.5258651Z Installer 2021-05-25T16:08:44.5259888Z InteractiveVMWorkingDir 2021-05-25T16:08:44.5260878Z L2Schemas 2021-05-25T16:08:44.5261923Z LiveKernelReports 2021-05-25T16:08:44.5262995Z Logs 2021-05-25T16:08:44.5264030Z Microsoft.NET 2021-05-25T16:08:44.5265059Z Migration 2021-05-25T16:08:44.5266084Z ModemLogs 2021-05-25T16:08:44.5267250Z OCR 2021-05-25T16:08:44.5268125Z OEM 2021-05-25T16:08:44.5269258Z Offline Web Pages 2021-05-25T16:08:44.5270278Z PFRO.log 2021-05-25T16:08:44.5271267Z PLA 2021-05-25T16:08:44.5272292Z Panther 2021-05-25T16:08:44.5273465Z Performance 2021-05-25T16:08:44.5274582Z PolicyDefinitions 2021-05-25T16:08:44.5275503Z Prefetch 2021-05-25T16:08:44.5276688Z PrintDialog 2021-05-25T16:08:44.5277672Z Provisioning 2021-05-25T16:08:44.5278648Z Registration 2021-05-25T16:08:44.5279642Z RemotePackages 2021-05-25T16:08:44.5280669Z Resources 2021-05-25T16:08:44.5281623Z SKB 2021-05-25T16:08:44.5282523Z SchCache 2021-05-25T16:08:44.5283552Z ServerDataCenter.xml 2021-05-25T16:08:44.5284598Z ServiceProfiles 2021-05-25T16:08:44.5285554Z ServiceState 2021-05-25T16:08:44.5286735Z Setup 2021-05-25T16:08:44.5287715Z ShellComponents 2021-05-25T16:08:44.5288578Z ShellExperiences 2021-05-25T16:08:44.5289364Z SoftwareDistribution 2021-05-25T16:08:44.5290935Z Speech 2021-05-25T16:08:44.5291974Z Speech_OneCore 2021-05-25T16:08:44.5292955Z SysWOW64 2021-05-25T16:08:44.5294261Z System 2021-05-25T16:08:44.5295361Z System32 2021-05-25T16:08:44.5296571Z SystemApps 2021-05-25T16:08:44.5298523Z SystemResources 2021-05-25T16:08:44.5299581Z TAPI 2021-05-25T16:08:44.5300533Z Tasks 2021-05-25T16:08:44.5301383Z Temp 2021-05-25T16:08:44.5302213Z TextInput 2021-05-25T16:08:44.5302931Z Vss 2021-05-25T16:08:44.5304263Z WMSysPr9.prx 2021-05-25T16:08:44.5305516Z WaaS 2021-05-25T16:08:44.5306861Z Web 2021-05-25T16:08:44.5307690Z WinSxS 2021-05-25T16:08:44.5308631Z WindowsShell.Manifest 2021-05-25T16:08:44.5309458Z WindowsUpdate.log 2021-05-25T16:08:44.5310313Z appcompat 2021-05-25T16:08:44.5311308Z apppatch 2021-05-25T16:08:44.5312262Z assembly 2021-05-25T16:08:44.5313156Z bcastdvr 2021-05-25T16:08:44.5314335Z bfsvc.exe 2021-05-25T16:08:44.5315485Z bootstat.dat 2021-05-25T16:08:44.5316454Z debug 2021-05-25T16:08:44.5317714Z diagnostics 2021-05-25T16:08:44.5318631Z drivers 2021-05-25T16:08:44.5319926Z en-US 2021-05-25T16:08:44.5320951Z explorer.exe 2021-05-25T16:08:44.5321991Z hh.exe 2021-05-25T16:08:44.5322946Z iis.log 2021-05-25T16:08:44.5324092Z lsasetup.log 2021-05-25T16:08:44.5325291Z media 2021-05-25T16:08:44.5326375Z mib.bin 2021-05-25T16:08:44.5327561Z notepad.exe 2021-05-25T16:08:44.5328536Z py.exe 2021-05-25T16:08:44.5329569Z pyshellext.amd64.dll 2021-05-25T16:08:44.5330581Z pyw.exe 2021-05-25T16:08:44.5331610Z regedit.exe 2021-05-25T16:08:44.5332587Z rescache 2021-05-25T16:08:44.5333718Z schemas 2021-05-25T16:08:44.5334733Z security 2021-05-25T16:08:44.5335696Z servicing 2021-05-25T16:08:44.5337064Z splwow64.exe 2021-05-25T16:08:44.5338212Z symbols 2021-05-25T16:08:44.5339173Z system.ini 2021-05-25T16:08:44.5340199Z tracing 2021-05-25T16:08:44.5341085Z twain_32 2021-05-25T16:08:44.5342073Z twain_32.dll 2021-05-25T16:08:44.5343611Z win.ini 2021-05-25T16:08:44.5344734Z winhlp32.exe 2021-05-25T16:08:44.5345968Z write.exe 2021-05-25T16:08:44.5347468Z Which find 2021-05-25T16:08:44.5641552Z /usr/bin/find 2021-05-25T16:08:44.5649014Z ls C:\Windows\System32\find.exe 2021-05-25T16:08:44.5865317Z C:\Windows\System32\find.exe 2021-05-25T16:08:44.6034920Z ##[section]Finishing: Debug bash task ```

chenghlee commented 3 years ago

Thanks; we'll update the recipe so the Windows post-link script uses the absolute path to find and release a new build shortly.

antkneed commented 3 years ago

Thank you for the assistance in tracking this down. 👍

A new build of scikit-learn has been uploaded for Windows that resolves this issue. If you are still running into this error, please feel free to re-open or create a new issue.