diff --git a/CHANGELOG.md b/CHANGELOG.md index 05b8126ce..0dcf33d7e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ This document follows the conventions laid out in [Keep a CHANGELOG][]. - Code Coverage (#345) - Added `pysetargv` (#347) - Added XML Documentation (#349) +- Added Embedded tests on Appveyor (#353) - Added PY3 settings to configuration-manager (#346) ### Changed @@ -21,11 +22,11 @@ This document follows the conventions laid out in [Keep a CHANGELOG][]. - Completed refactor of Build Directives on `Runtime.cs` (#339) - Refactor python unittests (#329) - Unfroze Mono version on Travis (#345) -- Enabled Embedded tests on Appveyor (#353) ### Fixed -- Fixed crash during Shutdown (#343) +- Fixed crash during Initialization (#343) +- Fixed crash during Shutdown (#365) ### Removed diff --git a/ci/appveyor_run_tests.ps1 b/ci/appveyor_run_tests.ps1 index 78bae50b9..3bfaf216d 100644 --- a/ci/appveyor_run_tests.ps1 +++ b/ci/appveyor_run_tests.ps1 @@ -26,8 +26,7 @@ if ($NUNIT_STATUS -ne 0) { } # Embedded tests failing due to open issues, pass/fail only on Python exit code -# if ($PYTHON_STATUS -ne 0 -or $NUNIT_STATUS -ne 0) { -if ($PYTHON_STATUS -ne 0) { +if ($PYTHON_STATUS -ne 0 -or $NUNIT_STATUS -ne 0) { Write-Host "Tests failed" -ForegroundColor "Red" $host.SetShouldExit(1) } diff --git a/src/runtime/pyobject.cs b/src/runtime/pyobject.cs index 4527e145f..3296d81f8 100644 --- a/src/runtime/pyobject.cs +++ b/src/runtime/pyobject.cs @@ -113,7 +113,7 @@ protected virtual void Dispose(bool disposing) { if (!disposed) { - if (Runtime.Py_IsInitialized() > 0) + if (Runtime.Py_IsInitialized() > 0 && !Runtime.IsFinalizing) { IntPtr gs = PythonEngine.AcquireLock(); Runtime.XDecref(obj);