Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 81cd197

Browse files
committed
Merge branch 'master' into PR/ExceptionsImprovement
2 parents e4c1b9b + 742463e commit 81cd197

Some content is hidden

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

45 files changed

+481
-338
lines changed

.bumpversion.cfg

Lines changed: 0 additions & 29 deletions
This file was deleted.

.travis.yml

Lines changed: 4 additions & 3 deletions
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

Lines changed: 5 additions & 2 deletions
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))
@@ -54,7 +57,6 @@
5457
- Sean Freitag ([@cowboygneox](https://github.com/cowboygneox))
5558
- Serge Weinstock ([@sweinst](https://github.com/sweinst))
5659
- Simon Mourier ([@smourier](https://github.com/smourier))
57-
- Victor Milovanov ([@lostmsu](https://github.com/lostmsu))
5860
- Viktoria Kovescses ([@vkovec](https://github.com/vkovec))
5961
- Ville M. Vainio ([@vivainio](https://github.com/vivainio))
6062
- Virgil Dupras ([@hsoft](https://github.com/hsoft))
@@ -71,4 +73,5 @@
7173
- ([@rmadsen-ks](https://github.com/rmadsen-ks))
7274
- ([@stonebig](https://github.com/stonebig))
7375
- ([@testrunner123](https://github.com/testrunner123))
76+
- ([@DanBarzilian](https://github.com/DanBarzilian))
7477

CHANGELOG.md

Lines changed: 50 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,73 @@
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 PythonException.Format method to format exceptions the same as traceback.format_exception
17-
- Added Runtime.None to be able to pass None as parameter into Python from .NET
18-
- Added PyObject.IsNone() to check if a Python object is None in .NET.
12+
### Changed
13+
14+
### Fixed
15+
16+
- Fix incorrect dereference of wrapper object in tp_repr, which may result in a program crash
17+
18+
## [2.5.0][] - 2020-06-14
19+
20+
This version improves performance on benchmarks significantly compared to 2.3.
21+
22+
### Added
23+
24+
- Automatic NuGet package generation in appveyor and local builds
25+
- Function that sets `Py_NoSiteFlag` to 1.
26+
- Support for Jetson Nano.
27+
- Support for `__len__` for .NET classes that implement ICollection
28+
- `PyExport` attribute to hide .NET types from Python
29+
- `PythonException.Format` method to format exceptions the same as
30+
`traceback.format_exception`
31+
- `Runtime.None` to be able to pass `None` as parameter into Python from .NET
32+
- `PyObject.IsNone()` to check if a Python object is None in .NET.
33+
- Support for Python 3.8
34+
- Codecs as the designated way to handle automatic conversions between
35+
.NET and Python types
1936

2037
### Changed
2138

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

3259
### Fixed
3360

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

40-
## [2.4.0][]
70+
## [2.4.0][] - 2019-05-15
4171

4272
### Added
4373

CONTRIBUTING.md

Lines changed: 6 additions & 1 deletion
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

Lines changed: 1 addition & 1 deletion
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

Lines changed: 15 additions & 15 deletions
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

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -15,24 +15,21 @@ environment:
1515
CODECOV_ENV: PYTHON_VERSION, PLATFORM
1616

1717
matrix:
18-
- PYTHON_VERSION: 2.7
18+
- PYTHON_VERSION: 3.8
1919
BUILD_OPTS: --xplat
20-
- PYTHON_VERSION: 3.5
20+
- PYTHON_VERSION: 3.7
2121
BUILD_OPTS: --xplat
2222
- PYTHON_VERSION: 3.6
2323
BUILD_OPTS: --xplat
24-
- PYTHON_VERSION: 3.7
25-
BUILD_OPTS: --xplat
26-
- PYTHON_VERSION: 2.7
2724
- PYTHON_VERSION: 3.5
28-
- PYTHON_VERSION: 3.6
25+
BUILD_OPTS: --xplat
26+
- PYTHON_VERSION: 2.7
27+
BUILD_OPTS: --xplat
28+
- PYTHON_VERSION: 3.8
2929
- PYTHON_VERSION: 3.7
30-
31-
matrix:
32-
allow_failures:
33-
- PYTHON_VERSION: 3.4
34-
BUILD_OPTS: --xplat
35-
- PYTHON_VERSION: 3.4
30+
- PYTHON_VERSION: 3.6
31+
- PYTHON_VERSION: 3.5
32+
- PYTHON_VERSION: 2.7
3633

3734
init:
3835
# Update Environment Variables based on matrix/platform
@@ -57,9 +54,8 @@ build_script:
5754
- coverage run setup.py bdist_wheel %BUILD_OPTS%
5855

5956
test_script:
60-
- pip install --no-index --find-links=.\dist\ pythonnet
57+
- pip install --find-links=.\dist\ pythonnet
6158
- ps: .\ci\appveyor_run_tests.ps1
62-
- ps: .\ci\appveyor_build_recipe.ps1
6359

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

ci/appveyor_build_recipe.ps1

Lines changed: 0 additions & 43 deletions
This file was deleted.

conda.recipe/README.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

0 commit comments

Comments
 (0)