Skip to content

Commit f85999e

Browse files
committed
Merge branch 'master' into soft-shutdown
2 parents b387e9e + 9fb545a commit f85999e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+1046
-470
lines changed

.bumpversion.cfg

-29
This file was deleted.

.travis.yml

+4-3
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,11 @@ dist: xenial
22
sudo: false
33
language: python
44
python:
5-
- 2.7
6-
- 3.5
7-
- 3.6
5+
- 3.8
86
- 3.7
7+
- 3.6
8+
- 3.5
9+
- 2.7
910

1011
env:
1112
matrix:

AUTHORS.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@
22

33
## Development Lead
44

5-
- Barton Cline ([@BartonCline](https://github.com/BartonCline))
65
- Benedikt Reinartz ([@filmor](https://github.com/filmor))
6+
- Victor Milovanov ([@lostmsu](https://github.com/lostmsu))
7+
8+
## Former Development Leads
9+
- Barton Cline ([@BartonCline](https://github.com/BartonCline))
710
- Brian Lloyd ([@brianlloyd](https://github.com/brianlloyd))
811
- David Anthoff ([@davidanthoff](https://github.com/davidanthoff))
912
- Denis Akhiyarov ([@denfromufa](https://github.com/denfromufa))
@@ -45,6 +48,7 @@
4548
- Luke Stratman ([@lstratman](https://github.com/lstratman))
4649
- Konstantin Posudevskiy ([@konstantin-posudevskiy](https://github.com/konstantin-posudevskiy))
4750
- Matthias Dittrich ([@matthid](https://github.com/matthid))
51+
- Meinrad Recheis ([@henon](https://github.com/henon))
4852
- Mohamed Koubaa ([@koubaa](https://github.com/koubaa))
4953
- Patrick Stewart ([@patstew](https://github.com/patstew))
5054
- Raphael Nestler ([@rnestler](https://github.com/rnestler))
@@ -53,7 +57,6 @@
5357
- Sean Freitag ([@cowboygneox](https://github.com/cowboygneox))
5458
- Serge Weinstock ([@sweinst](https://github.com/sweinst))
5559
- Simon Mourier ([@smourier](https://github.com/smourier))
56-
- Victor Milovanov ([@lostmsu](https://github.com/lostmsu))
5760
- Viktoria Kovescses ([@vkovec](https://github.com/vkovec))
5861
- Ville M. Vainio ([@vivainio](https://github.com/vivainio))
5962
- Virgil Dupras ([@hsoft](https://github.com/hsoft))

CHANGELOG.md

+49-17
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,71 @@
11
# Changelog
22

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][].
55

66
This document follows the conventions laid out in [Keep a CHANGELOG][].
77

8-
## [unreleased][]
8+
## [Unreleased][]
99

1010
### Added
1111

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 `object.GetRawPythonProxy() -> PyObject` extension method, that bypasses any conversions
12+
### Changed
13+
14+
### Fixed
15+
16+
## [2.5.0][] - 2020-06-14
17+
18+
This version improves performance on benchmarks significantly compared to 2.3.
19+
20+
### Added
21+
22+
- Automatic NuGet package generation in appveyor and local builds
23+
- Function that sets `Py_NoSiteFlag` to 1.
24+
- Support for Jetson Nano.
25+
- Support for `__len__` for .NET classes that implement ICollection
26+
- `PyExport` attribute to hide .NET types from Python
27+
- `PythonException.Format` method to format exceptions the same as
28+
`traceback.format_exception`
29+
- `Runtime.None` to be able to pass `None` as parameter into Python from .NET
30+
- `PyObject.IsNone()` to check if a Python object is None in .NET.
31+
- Support for Python 3.8
32+
- Codecs as the designated way to handle automatic conversions between
33+
.NET and Python types
1734

1835
### Changed
1936

2037
- Added argument types information to "No method matches given arguments" message
2138
- Moved wheel import in setup.py inside of a try/except to prevent pip collection failures
22-
- Removes PyLong_GetMax and PyClass_New when targetting Python3
39+
- Removes `PyLong_GetMax` and `PyClass_New` when targetting Python3
40+
- Improved performance of calls from Python to C#
2341
- Added support for converting python iterators to C# arrays
24-
- Changed usage of obselete function GetDelegateForFunctionPointer(IntPtr, Type) to GetDelegateForFunctionPointer<TDelegate>(IntPtr)
25-
- 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])
42+
- Changed usage of the obsolete function
43+
`GetDelegateForFunctionPointer(IntPtr, Type)` to
44+
`GetDelegateForFunctionPointer<TDelegate>(IntPtr)`
45+
- When calling C# from Python, enable passing argument of any type to a
46+
parameter of C# type `object` by wrapping it into `PyObject` instance.
47+
([#881][i881])
2648
- Added support for kwarg parameters when calling .NET methods from Python
49+
- Changed method for finding MSBuild using vswhere
50+
- Reworked `Finalizer`. Now objects drop into its queue upon finalization,
51+
which is periodically drained when new objects are created.
52+
- Marked `Runtime.OperatingSystemName` and `Runtime.MachineName` as
53+
`Obsolete`, should never have been `public` in the first place. They also
54+
don't necessarily return a result that matches the `platform` module's.
55+
- Unconditionally depend on `pycparser` for the interop module generation
2756

2857
### Fixed
2958

30-
- Fixed runtime that fails loading when using pythonnet in an environment
31-
together with Nuitka
32-
- Fixes bug where delegates get casts (dotnetcore)
33-
- Determine size of interpreter longs at runtime
34-
- Handling exceptions ocurred in ModuleObject's getattribute
59+
- Fixed runtime that fails loading when using pythonnet in an environment
60+
together with Nuitka
61+
- Fixes bug where delegates get casts (dotnetcore)
62+
- Determine size of interpreter longs at runtime
63+
- Handling exceptions ocurred in ModuleObject's getattribute
64+
- Fill `__classcell__` correctly for Python subclasses of .NET types
65+
- Fixed issue with params methods that are not passed an array.
66+
- Use UTF8 to encode strings passed to `PyRun_String` on Python 3
3567

36-
## [2.4.0][]
68+
## [2.4.0][] - 2019-05-15
3769

3870
### Added
3971

CONTRIBUTING.md

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
# How to contribute
22

3-
PythonNet is developed and maintained by unpaid community members so well
3+
Python.NET is developed and maintained by unpaid community members so well
44
written, documented and tested pull requests are encouraged.
55

66
By submitting a pull request for this project, you agree to license your
77
contribution under the MIT license to this project.
88

9+
This project has adopted the code of conduct defined by the Contributor
10+
Covenant to clarify expected behavior in our community. For more information
11+
see the [.NET Foundation Code of Conduct](https://dotnetfoundation.org/code-of-conduct).
12+
913
## Getting Started
1014

1115
- Make sure you have a [GitHub account](https://github.com/signup/free)
@@ -41,3 +45,4 @@ contribution under the MIT license to this project.
4145

4246
- [General GitHub documentation](https://help.github.com/)
4347
- [GitHub pull request documentation](https://help.github.com/send-pull-requests/)
48+
- [.NET Foundation Code of Conduct](https://dotnetfoundation.org/about/code-of-conduct)

LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2006-2019 the contributors of the "Python for .NET" project
3+
Copyright (c) 2006-2020 the contributors of the Python.NET project
44

55
Permission is hereby granted, free of charge, to any person obtaining a
66
copy of this software and associated documentation files (the "Software"),

README.rst

+15-15
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
pythonnet - Python for .NET
1+
pythonnet - Python.NET
22
===========================
33

44
|Join the chat at https://gitter.im/pythonnet/pythonnet|
@@ -8,7 +8,7 @@ pythonnet - Python for .NET
88
|license shield| |pypi package version| |conda-forge version| |python supported shield|
99
|stackexchange shield|
1010

11-
Python for .NET is a package that gives Python programmers nearly
11+
Python.NET is a package that gives Python programmers nearly
1212
seamless integration with the .NET Common Language Runtime (CLR) and
1313
provides a powerful application scripting tool for .NET developers. It
1414
allows Python code to interact with the CLR, and may also be used to
@@ -17,8 +17,7 @@ embed Python into a .NET application.
1717
Calling .NET code from Python
1818
-----------------------------
1919

20-
Python for .NET allows CLR namespaces to be treated essentially as
21-
Python packages.
20+
Python.NET allows CLR namespaces to be treated essentially as Python packages.
2221

2322
.. code-block::
2423
@@ -90,18 +89,24 @@ Output:
9089
int32
9190
[ 6. 10. 12.]
9291
92+
93+
94+
Resources
95+
---------
96+
9397
Information on installation, FAQ, troubleshooting, debugging, and
9498
projects using pythonnet can be found in the Wiki:
9599

96100
https://github.com/pythonnet/pythonnet/wiki
97101

98-
Python 3.8.0 support
99-
--------------------
102+
Mailing list
103+
https://mail.python.org/mailman/listinfo/pythondotnet
104+
Chat
105+
https://gitter.im/pythonnet/pythonnet
100106

101-
Some features are disabled in Python 3.8.0 because of
102-
`this bug in Python <https://bugs.python.org/issue37633>`_. The error is
103-
``System.EntryPointNotFoundException : Unable to find an entry point named
104-
'Py_CompileString' in DLL 'python38'``. This will be fixed in Python 3.8.1.
107+
.NET Foundation
108+
---------------
109+
This project is supported by the `.NET Foundation <https://dotnetfoundation.org>`_.
105110

106111
.. |Join the chat at https://gitter.im/pythonnet/pythonnet| image:: https://badges.gitter.im/pythonnet/pythonnet.svg
107112
:target: https://gitter.im/pythonnet/pythonnet?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
@@ -121,8 +126,3 @@ Some features are disabled in Python 3.8.0 because of
121126
:target: http://stackoverflow.com/questions/tagged/python.net
122127
.. |conda-forge version| image:: https://img.shields.io/conda/vn/conda-forge/pythonnet.svg
123128
:target: https://anaconda.org/conda-forge/pythonnet
124-
125-
Resources
126-
---------
127-
Mailing list: https://mail.python.org/mailman/listinfo/pythondotnet
128-
Chat: https://gitter.im/pythonnet/pythonnet

appveyor.yml

+11-14
Original file line numberDiff line numberDiff line change
@@ -15,28 +15,26 @@ environment:
1515
CODECOV_ENV: PYTHON_VERSION, PLATFORM
1616

1717
matrix:
18+
- PYTHON_VERSION: 3.8
1819
- PYTHON_VERSION: 2.7
1920
BUILD_OPTS: --xplat
20-
- PYTHON_VERSION: 3.5
21+
- PYTHON_VERSION: 3.7
2122
BUILD_OPTS: --xplat
2223
- PYTHON_VERSION: 3.6
2324
BUILD_OPTS: --xplat
24-
- PYTHON_VERSION: 3.7
25-
BUILD_OPTS: --xplat
26-
- PYTHON_VERSION: 2.7
2725
- PYTHON_VERSION: 3.5
28-
- PYTHON_VERSION: 3.6
26+
BUILD_OPTS: --xplat
27+
- PYTHON_VERSION: 2.7
28+
BUILD_OPTS: --xplat
29+
- PYTHON_VERSION: 3.8
2930
- PYTHON_VERSION: 3.7
31+
- PYTHON_VERSION: 3.6
32+
- PYTHON_VERSION: 3.5
33+
- PYTHON_VERSION: 2.7
3034

35+
matrix:
3136
- PYTHON_VERSION: 3.7
3237
PYTHONNET_SOFT_SHUTDOWN: 1
33-
34-
matrix:
35-
allow_failures:
36-
- PYTHON_VERSION: 3.4
37-
BUILD_OPTS: --xplat
38-
- PYTHON_VERSION: 3.4
39-
4038
init:
4139
# Update Environment Variables based on matrix/platform
4240
- set PY_VER=%PYTHON_VERSION:.=%
@@ -60,9 +58,8 @@ build_script:
6058
- coverage run setup.py bdist_wheel %BUILD_OPTS%
6159

6260
test_script:
63-
- pip install --no-index --find-links=.\dist\ pythonnet
61+
- pip install --find-links=.\dist\ pythonnet
6462
- ps: .\ci\appveyor_run_tests.ps1
65-
- ps: .\ci\appveyor_build_recipe.ps1
6663

6764
on_finish:
6865
# Temporary disable multiple upload due to codecov limit of 20 per commit.

ci/appveyor_build_recipe.ps1

-43
This file was deleted.

conda.recipe/README.md

-5
This file was deleted.

conda.recipe/bld.bat

-6
This file was deleted.

conda.recipe/meta.yaml

-29
This file was deleted.

0 commit comments

Comments
 (0)