|
1 | 1 | # Changelog
|
2 | 2 |
|
3 |
| -All notable changes to Python for .NET will be documented in this file. |
4 |
| -This project adheres to [Semantic Versioning][]. |
| 3 | +All notable changes to Python.NET will be documented in this file. This |
| 4 | +project adheres to [Semantic Versioning][]. |
5 | 5 |
|
6 | 6 | This document follows the conventions laid out in [Keep a CHANGELOG][].
|
7 | 7 |
|
8 |
| -## [unreleased][] |
| 8 | +## [Unreleased][] |
9 | 9 |
|
10 | 10 | ### Added
|
| 11 | +- Added Python 3 buffer api support and PyBuffer interface for fast byte and numpy array read/write ([#980][p980]) |
| 12 | + |
| 13 | +### Changed |
| 14 | +- Drop support for Python 2, 3.4, and 3.5 |
| 15 | +- `clr.AddReference` may now throw errors besides `FileNotFoundException`, that provide more |
| 16 | +details about the cause of the failure |
| 17 | +- `clr.AddReference` no longer adds ".dll" implicitly |
| 18 | +- `PyIter(PyObject)` constructor replaced with static `PyIter.GetIter(PyObject)` method |
| 19 | +- Return values from .NET methods that return an interface are now automatically |
| 20 | + wrapped in that interface. This is a breaking change for users that rely on being |
| 21 | + able to access members that are part of the implementation class, but not the |
| 22 | + interface. Use the new __implementation__ or __raw_implementation__ properties to |
| 23 | + if you need to "downcast" to the implementation class. |
| 24 | + |
| 25 | +### Fixed |
| 26 | + |
| 27 | +- Fix incorrect dereference of wrapper object in `tp_repr`, which may result in a program crash |
| 28 | +- Fix incorrect dereference in params array handling |
| 29 | +- Fix `object[]` parameters taking precedence when should not in overload resolution |
| 30 | +- Fixed a bug where all .NET class instances were considered Iterable |
| 31 | +- Fix incorrect choice of method to invoke when using keyword arguments. |
| 32 | +- Fix non-delegate types incorrectly appearing as callable. |
| 33 | +- Indexers can now be used with interface objects |
| 34 | +- Fixed a bug where indexers could not be used if they were inherited |
| 35 | +- Made it possible to use `__len__` also on `ICollection<>` interface objects |
11 | 36 |
|
12 |
| -- Added automatic NuGet package generation in appveyor and local builds |
13 |
| -- Added function that sets Py_NoSiteFlag to 1. |
14 |
| -- Added support for Jetson Nano. |
15 |
| -- Added support for __len__ for .NET classes that implement ICollection |
16 |
| -- Added `PyExport` attribute to hide .NET types from Python |
17 |
| -- Added PythonException.Format method to format exceptions the same as traceback.format_exception |
18 |
| -- Added Runtime.None to be able to pass None as parameter into Python from .NET |
19 |
| -- Added PyObject.IsNone() to check if a Python object is None in .NET. |
| 37 | +## [2.5.0][] - 2020-06-14 |
| 38 | + |
| 39 | +This version improves performance on benchmarks significantly compared to 2.3. |
| 40 | + |
| 41 | +### Added |
| 42 | + |
| 43 | +- Automatic NuGet package generation in appveyor and local builds |
| 44 | +- Function that sets `Py_NoSiteFlag` to 1. |
| 45 | +- Support for Jetson Nano. |
| 46 | +- Support for `__len__` for .NET classes that implement ICollection |
| 47 | +- `PyExport` attribute to hide .NET types from Python |
| 48 | +- `PythonException.Format` method to format exceptions the same as |
| 49 | + `traceback.format_exception` |
| 50 | +- `Runtime.None` to be able to pass `None` as parameter into Python from .NET |
| 51 | +- `PyObject.IsNone()` to check if a Python object is None in .NET. |
20 | 52 | - Support for Python 3.8
|
21 |
| -- Added Python 3 buffer api support and PyBuffer interface for fast byte and numpy array read/write ([#980][p980]) |
| 53 | +- Codecs as the designated way to handle automatic conversions between |
| 54 | + .NET and Python types |
22 | 55 |
|
23 | 56 | ### Changed
|
24 | 57 |
|
25 | 58 | - Added argument types information to "No method matches given arguments" message
|
26 | 59 | - Moved wheel import in setup.py inside of a try/except to prevent pip collection failures
|
27 |
| -- Removes PyLong_GetMax and PyClass_New when targetting Python3 |
| 60 | +- Removes `PyLong_GetMax` and `PyClass_New` when targetting Python3 |
28 | 61 | - Improved performance of calls from Python to C#
|
29 | 62 | - Added support for converting python iterators to C# arrays
|
30 |
| -- Changed usage of obselete function GetDelegateForFunctionPointer(IntPtr, Type) to GetDelegateForFunctionPointer<TDelegate>(IntPtr) |
31 |
| -- When calling C# from Python, enable passing argument of any type to a parameter of C# type `object` by wrapping it into `PyObject` instance. ([#881][i881]) |
| 63 | +- Changed usage of the obsolete function |
| 64 | + `GetDelegateForFunctionPointer(IntPtr, Type)` to |
| 65 | + `GetDelegateForFunctionPointer<TDelegate>(IntPtr)` |
| 66 | +- When calling C# from Python, enable passing argument of any type to a |
| 67 | + parameter of C# type `object` by wrapping it into `PyObject` instance. |
| 68 | + ([#881][i881]) |
32 | 69 | - Added support for kwarg parameters when calling .NET methods from Python
|
33 | 70 | - Changed method for finding MSBuild using vswhere
|
34 |
| -- Reworked `Finalizer`. Now objects drop into its queue upon finalization, which is periodically drained when new objects are created. |
35 |
| -- Marked `Runtime.OperatingSystemName` and `Runtime.MachineName` as `Obsolete`, should never have been `public` in the first place. They also don't necessarily return a result that matches the `platform` module's. |
| 71 | +- Reworked `Finalizer`. Now objects drop into its queue upon finalization, |
| 72 | + which is periodically drained when new objects are created. |
| 73 | +- Marked `Runtime.OperatingSystemName` and `Runtime.MachineName` as |
| 74 | + `Obsolete`, should never have been `public` in the first place. They also |
| 75 | + don't necessarily return a result that matches the `platform` module's. |
| 76 | +- Unconditionally depend on `pycparser` for the interop module generation |
36 | 77 |
|
37 | 78 | ### Fixed
|
38 | 79 |
|
39 |
| -- Fixed runtime that fails loading when using pythonnet in an environment |
40 |
| - together with Nuitka |
41 |
| -- Fixes bug where delegates get casts (dotnetcore) |
42 |
| -- Determine size of interpreter longs at runtime |
43 |
| -- Handling exceptions ocurred in ModuleObject's getattribute |
44 |
| -- Fill `__classcell__` correctly for Python subclasses of .NET types |
45 |
| -- Fixed issue with params methods that are not passed an array. |
| 80 | +- Fixed runtime that fails loading when using pythonnet in an environment |
| 81 | + together with Nuitka |
| 82 | +- Fixes bug where delegates get casts (dotnetcore) |
| 83 | +- Determine size of interpreter longs at runtime |
| 84 | +- Handling exceptions ocurred in ModuleObject's getattribute |
| 85 | +- Fill `__classcell__` correctly for Python subclasses of .NET types |
| 86 | +- Fixed issue with params methods that are not passed an array. |
| 87 | +- Use UTF8 to encode strings passed to `PyRun_String` on Python 3 |
46 | 88 |
|
47 |
| -## [2.4.0][] |
| 89 | +## [2.4.0][] - 2019-05-15 |
48 | 90 |
|
49 | 91 | ### Added
|
50 | 92 |
|
@@ -72,6 +114,7 @@ This document follows the conventions laid out in [Keep a CHANGELOG][].
|
72 | 114 | - PythonEngine.Intialize will now call `Py_InitializeEx` with a default value of 0, so signals will not be configured by default on embedding. This is different from the previous behaviour, where `Py_Initialize` was called instead, which sets initSigs to 1. ([#449][i449])
|
73 | 115 | - Refactored MethodBinder.Bind in preparation to make it extensible (#829)
|
74 | 116 | - Look for installed Windows 10 sdk's during installation instead of relying on specific versions.
|
| 117 | +- Remove `LoadLibrary` call. ([#880][p880]) |
75 | 118 |
|
76 | 119 | ### Fixed
|
77 | 120 |
|
|
0 commit comments