Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Interop methods with Py_ssize_t works differently in NetCoreApp 2.0#531

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
filmor merged 3 commits intopythonnet:masterfromdmitriyse:py_ssize_t-fix
Oct 23, 2018
Merged
Show file tree
Hide file tree
Changes from1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
NextNext commit
Interop fix for Py_ssize_t methods (it's produces problems only on Ne…
…tCoreApp 2.0).
  • Loading branch information
@filmor
dse authored andfilmor committedOct 19, 2018
commitf121c44a04f77a02f9b98df798dae91dd7aa8ee0
2 changes: 2 additions & 0 deletionsCHANGELOG.md
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -28,6 +28,7 @@ This document follows the conventions laid out in [Keep a CHANGELOG][].
- Fixed Visual Studio 2017 compat ([#434][i434]) for setup.py
- Fixed crashes when integrating pythonnet in Unity3d ([#714][i714]),
related to unloading the Application Domain
- Fixed interop methods with Py_ssize_t. NetCoreApp 2.0 is more sensitive than net40 and requires this fix. ([#531][p531])
- Fixed crash on exit of the Python interpreter if a python class
derived from a .NET class has a `__namespace__` or `__assembly__`
attribute ([#481][i481])
Expand DownExpand Up@@ -688,3 +689,4 @@ This document follows the conventions laid out in [Keep a CHANGELOG][].
[p163]: https://github.com/pythonnet/pythonnet/pull/163
[p625]: https://github.com/pythonnet/pythonnet/pull/625
[i131]: https://github.com/pythonnet/pythonnet/issues/131
[p531]: https://github.com/pythonnet/pythonnet/pull/531
6 changes: 2 additions & 4 deletionssrc/embed_tests/TestPySequence.cs
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -69,10 +69,8 @@ public void TestRepeat()
PyObject actual = t1.Repeat(3);
Assert.AreEqual("FooFooFoo", actual.ToString());

// On 32 bit system this argument should be int, but on the 64 bit system this should be long value.
// This works on the Framework 4.0 accidentally, it should produce out of memory!
// actual = t1.Repeat(-3);
// Assert.AreEqual("", actual.ToString());
actual = t1.Repeat(-3);
Assert.AreEqual("", actual.ToString());
}

[Test]
Expand Down
2 changes: 1 addition & 1 deletionsrc/runtime/exceptions.cs
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -276,7 +276,7 @@ public static void SetError(Exception e)
/// </remarks>
public static bool ErrorOccurred()
{
return Runtime.PyErr_Occurred() !=0;
return Runtime.PyErr_Occurred() !=IntPtr.Zero;
}

/// <summary>
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp