Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

System.Diagnostics.ProcessTest.Start1_FileName_NotFound failing #6383

Closed
lewurm opened this issue Jan 3, 2018 · 10 comments
Closed

System.Diagnostics.ProcessTest.Start1_FileName_NotFound failing #6383

lewurm opened this issue Jan 3, 2018 · 10 comments
Assignees
Labels

Comments

@lewurm
Copy link
Member

@lewurm lewurm commented Jan 3, 2018

Steps to Reproduce

export MONO_TLS_PROVIDER=legacy
export TEST_HARNESS_VERBOSE=1
make -w -C mcs/class/System run-test V=1 TESTNAME=System.Diagnostics.ProcessTest.Start1_FileName_NotFound

Current Behavior

native crash.

On which platforms did you notice this

[ ] macOS
[x] Linux, more specifically it's a Ubuntu chroot on a ChromeOS device.
[ ] Windows

Version Used:

master

Stacktrace

***** MonoTests.System.Diagnostics.ProcessTest.Start1_FileName_NotFound
Stacktrace:

  at <unknown> <0xffffffff>
  at (wrapper managed-to-native) System.Diagnostics.Process.ShellExecuteEx_internal (System.Diagnostics.ProcessStartInfo,System.Diagnostics.Process/ProcInfo&) [0x00008] in <fedd6a1bd58a41328d231359c1d10c50>:0
  at System.Diagnostics.Process.StartWithShellExecuteEx (System.Diagnostics.ProcessStartInfo) [0x000be] in /home/lewurm/work/mono/mcs/class/System/System.Diagnostics/Process.cs:598
  at System.Diagnostics.Process.Start () [0x00032] in /home/lewurm/work/mono/mcs/class/referencesource/System/services/monitoring/system/diagnosticts/Process.cs:2000
  at (wrapper remoting-invoke-with-check) System.Diagnostics.Process.Start () [0x00032] in <fedd6a1bd58a41328d231359c1d10c50>:0
  at MonoTests.System.Diagnostics.ProcessTest.Start1_FileName_NotFound () [0x00154] in /home/lewurm/work/mono/mcs/class/System/Test/System.Diagnostics/ProcessTest.cs:214
  at (wrapper runtime-invoke) object.runtime_invoke_void__this__ (object,intptr,intptr,intptr) [0x0004f] in <0890f81cc00f4109b92e9ab281ffb710>:0
  at <unknown> <0xffffffff>
  at (wrapper managed-to-native) System.Reflection.MonoMethod.InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&) [0x00016] in <0890f81cc00f4109b92e9ab281ffb710>:0
  at System.Reflection.MonoMethod.Invoke (object,System.Reflection.BindingFlags,System.Reflection.Binder,object[],System.Globalization.CultureInfo) [0x00032] in /home/lewurm/work/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:305
  at System.Reflection.MethodBase.Invoke (object,object[]) [0x00000] in /home/lewurm/work/mono/mcs/class/referencesource/mscorlib/system/reflection/methodbase.cs:229
  at NUnit.Framework.Internal.Reflect.InvokeMethod (System.Reflection.MethodInfo,object,object[]) [0x00009] in /home/lewurm/work/mono/external/nunit-lite/NUnitLite-1.0.0/src/framework/Internal/Reflect.cs:215
  at NUnit.Framework.Internal.Commands.TestMethodCommand.RunNonAsyncTestMethod (NUnit.Framework.Internal.TestExecutionContext) [0x00000] in /home/lewurm/work/mono/external/nunit-lite/NUnitLite-1.0.0/src/framework/Internal/Commands/TestMethodCommand.cs:114
  at NUnit.Framework.Internal.Commands.TestMethodCommand.RunTestMethod (NUnit.Framework.Internal.TestExecutionContext) [0x0001a] in /home/lewurm/work/mono/external/nunit-lite/NUnitLite-1.0.0/src/framework/Internal/Commands/TestMethodCommand.cs:90
  at NUnit.Framework.Internal.Commands.TestMethodCommand.Execute (NUnit.Framework.Internal.TestExecutionContext) [0x00000] in /home/lewurm/work/mono/external/nunit-lite/NUnitLite-1.0.0/src/framework/Internal/Commands/TestMethodCommand.cs:66
[...]

Thread 1 (Thread 0x7a9587439740 (LWP 13641)):
#0  0x00007a9586909f7b in __waitpid (pid=13665, stat_loc=0x7ffcf7b7456c, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:29
#1  0x0000000000514984 in mono_handle_native_crash (signal=0x8bbb33 "SIGSEGV", ctx=0x0, info=0x0) at mini-exceptions.c:2813
#2  0x00000000006140a9 in altstack_handle_and_restore (ctx=0x7ffcf7b74fb0, obj=0x0, stack_ovf=0) at exceptions-amd64.c:849
#3  0x000000000076bcb4 in mono_w32handle_ref_core (handle_data=0x0) at w32handle.c:411
#4  0x000000000076baea in mono_w32handle_lookup_and_ref (handle=0x0, handle_data=0x7ffcf7b75230) at w32handle.c:335
#5  0x0000000000649255 in mono_w32process_get_pid (handle=0x0) at w32process-unix.c:889
#6  0x000000000064c02d in ves_icall_System_Diagnostics_Process_ShellExecuteEx_internal (proc_start_info=0x7a9585e4d340, process_info
=0x7ffcf7b75320) at w32process-unix.c:2230
#7  0x000000004133de2a in ?? ()
#8  0x0000000000000001 in ?? ()
#9  0x00007a9586108130 in ?? ()
#10 0x00007a9585e4bfd8 in ?? ()
#11 0x00007a9585e4d210 in ?? ()
#12 0x00007a9585e4d340 in ?? ()
#13 0x00007ffcf7b75ad8 in ?? ()

I would appreciate some help debugging this.

/cc @luhenry

@pr0vieh
Copy link

@pr0vieh pr0vieh commented Jan 4, 2018

i think this is related to https://bugzilla.xamarin.com/show_bug.cgi?id=60977

@akoeplinger
Copy link
Member

@akoeplinger akoeplinger commented Jan 4, 2018

I'm seeing this on a regular Ubuntu 16.04 VirtualBox VM as well. I wonder why it doesn't show up in CI. @lewurm is your chroot 16.04 as well?

@lewurm
Copy link
Member Author

@lewurm lewurm commented Jan 4, 2018

@akoeplinger yes, 16.04.

@pr0vieh
Copy link

@pr0vieh pr0vieh commented Jan 5, 2018

@lewurm @akoeplinger also on Ubuntu 17.10.

@akoeplinger
Copy link
Member

@akoeplinger akoeplinger commented Jan 5, 2018

I tried the commit before #5570 and it doesn't crash, but still fails the test at ProcessTest.cs:215. After the PR it does crash, so something is definitely off :)

@luhenry
Copy link
Contributor

@luhenry luhenry commented Jan 8, 2018

I cannot reproduce the crash locally, would you mind checking on your end if #6449 fixes the issue? Thank you

@akoeplinger
Copy link
Member

@akoeplinger akoeplinger commented Jan 8, 2018

@luhenry yes it does seem to fix the crash for me.

@lewurm
Copy link
Member Author

@lewurm lewurm commented Jan 8, 2018

it doesn't crash the runtime anymore, but still something is odd:

***** /home/lewurm/work/mono/mcs/class/lib/net_4_x-linux/tests/net_4_x_System_test.dll
***** MonoTests.System.Diagnostics.ProcessTest
***** MonoTests.System.Diagnostics.ProcessTest.Start1_FileName_NotFound

Tests run: 1, Passed: 0, Errors: 0, Failures: 1, Inconclusive: 0
  Not run: 0, Invalid: 0, Ignored: 0, Skipped: 0
Elapsed time: 00:00:00.1610000

Errors and Failures:

1) Start1_FileName_NotFound (MonoTests.System.Diagnostics.ProcessTest.Start1_FileName_NotFound)
   #C1
  at MonoTests.System.Diagnostics.ProcessTest.Start1_FileName_NotFound () [0x0015b] in /home/lewurm/work/mono/mcs/class/System/Test/System.Diagnostics/ProcessTest.cs:215 
  at (wrapper managed-to-native) System.Reflection.MonoMethod.InternalInvoke(System.Reflection.MonoMethod,object,object[],System.Exception&)
  at System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00032] in /home/lewurm/work/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:305 

xdg-open: file '/usr/bin/shouldnoteverexist' does not exist

@akoeplinger
Copy link
Member

@akoeplinger akoeplinger commented Jan 8, 2018

@lewurm yes, but that happened even before #5570 as I mentioned in #6383 (comment)

@luhenry luhenry closed this in #6449 Jan 9, 2018
luhenry added a commit that referenced this issue Jan 9, 2018
* [w32process] Ensure process_handle is a legal value

Fixes #6383

* [w32process] Remove dead code
@akoeplinger
Copy link
Member

@akoeplinger akoeplinger commented Jan 9, 2018

Opened #6466 for the remaining issue.

luhenry added a commit to luhenry/mono that referenced this issue Jan 12, 2018
luhenry added a commit to luhenry/mono that referenced this issue Jan 12, 2018
luhenry added a commit to luhenry/mono that referenced this issue Jan 12, 2018
* [w32process] Ensure process_handle is a legal value

Fixes mono#6383

* [w32process] Remove dead code
luhenry added a commit to luhenry/mono that referenced this issue Jan 12, 2018
* [w32process] Ensure process_handle is a legal value

Fixes mono#6383

* [w32process] Remove dead code
marek-safar added a commit that referenced this issue Jan 15, 2018
* [w32process] Ensure process_handle is a legal value

Fixes #6383

* [w32process] Remove dead code
marek-safar added a commit that referenced this issue Jan 16, 2018
* [w32process] Ensure process_handle is a legal value

Fixes #6383

* [w32process] Remove dead code
jonpryor added a commit to jonpryor/xamarin-android that referenced this issue Jan 18, 2018
jonpryor added a commit to xamarin/xamarin-android that referenced this issue Jan 18, 2018
Context: mono/mono#6383
Context: mono/mono#6414
jonpryor added a commit to xamarin/xamarin-android that referenced this issue Jan 18, 2018
Fixes: #1186

Context: mono/mono#6383
Context: mono/mono#6414

Re-enable `MonoTests.System.Reflection.Emit.SaveTest` again for the
Release configuration.
joncham added a commit to Unity-Technologies/mono that referenced this issue Apr 6, 2018
* [w32process] Ensure process_handle is a legal value

Fixes mono#6383

* [w32process] Remove dead code
joncham added a commit to Unity-Technologies/mono that referenced this issue Apr 6, 2018
* [w32process] Ensure process_handle is a legal value

Fixes mono#6383

* [w32process] Remove dead code
jonpryor added a commit to xamarin/xamarin-android that referenced this issue Apr 25, 2018
Bumps to Java.Interop/master/0afb2b0f
Bumps to llvm/master/a9cfb50e.

Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=11771
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=15051
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=19436
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=45901
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=56071
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=58413
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=58413
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=58413
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=59184
fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60065
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60225
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60298
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60359
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60568
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60756
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60848
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60862
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60900
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60904
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=60986
Fixes: https://github.com/mono/mono/issues/59400
Fixes: mono/mono#6169
Fixes: mono/mono#6187
Fixes: mono/mono#6192
Fixes: mono/mono#6255
Fixes: mono/mono#6264
Fixes: mono/mono#6266
Fixes: mono/mono#6281
Fixes: mono/mono#6283
Fixes: mono/mono#6320
Fixes: mono/mono#6339
Fixes: mono/mono#6343
Fixes: mono/mono#6349
Fixes: mono/mono#6379
Fixes: mono/mono#6383
Fixes: mono/mono#6401.
Fixes: mono/mono#6411
Fixes: mono/mono#6414
Fixes: mono/mono#6490
Fixes: mono/mono#6721
Fixes: mono/mono#6767
Fixes: mono/mono#6777
Fixes: mono/mono#6848
Fixes: mono/mono#6940
Fixes: mono/mono#6948
Fixes: mono/mono#6998
Fixes: mono/mono#7016
Fixes: mono/mono#7085
Fixes: mono/mono#7086
Fixes: mono/mono#7095
Fixes: mono/mono#7137
Fixes: mono/mono#7184
Fixes: mono/mono#7240
Fixes: mono/mono#7262
Fixes: mono/mono#7289
Fixes: mono/mono#7338
Fixes: mono/mono#7356
Fixes: mono/mono#7364
Fixes: mono/mono#7378
Fixes: mono/mono#7389
Fixes: mono/mono#7460
Fixes: mono/mono#7535
Fixes: mono/mono#7536
Fixes: mono/mono#7610
Fixes: mono/mono#7624
Fixes: mono/mono#7637
Fixes: mono/mono#7655
Fixes: mono/mono#7657
Fixes: mono/mono#7685
Fixes: mono/mono#7786
Fixes: mono/mono#7792
Fixes: mono/mono#7822
Fixes: mono/mono#7860
Fixes: mono/mono#8089
Fixes: mono/mono#8267
Fixes: mono/mono#8409
Fixes: xamarin/maccore#628
Fixes: xamarin/maccore#629
Fixes: xamarin/maccore#673
Fixes: xamarin/maccore#673
Fixes: #1561
joncham added a commit to Unity-Technologies/mono that referenced this issue May 8, 2018
* [w32process] Ensure process_handle is a legal value

Fixes mono#6383

* [w32process] Remove dead code
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants