Alexander Niederbühl
ad0a068a38
Add minimal datetime as testcase which should pass on all platforms
2019-07-15 08:08:51 +02:00
Alexander Niederbühl
f642f19167
Increase MIN_DATETIME_FROM_TIMESTAMP for windows
...
Otherwise test_datetime_from_timestamp will give an OSError. This seems
to be a similar problem as https://bugs.python.org/issue29097
2019-07-15 08:07:14 +02:00
Yuji Kanagawa
9c961b4248
Merge branch 'master' into gc-default
2019-07-15 14:25:27 +09:00
kngwyu
370849e075
Use [Option<T>; N] in ArrayList
2019-07-15 13:32:18 +09:00
Yuji Kanagawa
67a7a6de67
Merge branch 'master' into clippy
2019-07-15 12:44:56 +09:00
Yuji Kanagawa
29b0a02fda
Merge pull request #531 from pganssle/enforce_gc_protocol
...
Enforce GC contract at compile time
2019-07-15 12:44:15 +09:00
Alexander Niederbühl
86cc424b23
Fail CI if there are clippy warnings
2019-07-14 22:42:37 +02:00
Alexander Niederbühl
cc31c7dbf2
Ignore remaining clippy lints
2019-07-14 22:42:37 +02:00
Alexander Niederbühl
faa21f48c7
Fix some clippy lints
2019-07-14 22:42:37 +02:00
Alexander Niederbühl
ceefa7cc27
Add __clear__ for test class
2019-07-14 20:45:05 +02:00
Alexander Niederbühl
cc469afc38
Merge branch 'master' into gc-default
2019-07-14 20:42:57 +02:00
Alexander Niederbühl
ec71dc63a0
Remove #[allow(unused_variables)]
2019-07-14 18:09:12 +02:00
Paul Ganssle
e633ae25eb
Add changelog error for PR #532
2019-07-14 18:00:16 +02:00
Paul Ganssle
ca07c48931
Add documentation for new PyGCProtocol behavior
2019-07-14 17:56:36 +02:00
Paul Ganssle
59ed277879
Enforce GC contract at compile time
...
PyGCProtocol must be implemented for anything registered as tracked by
the garbage collector. This modifies the `pyclass` macro to enforce this
at compile time.
2019-07-14 17:55:47 +02:00
Yuji Kanagawa
670b41c898
Merge pull request #530 from Alexander-N/gc-test
...
Implement PyGCProtocol in test class
2019-07-15 00:47:21 +09:00
Yuji Kanagawa
2d879bc853
Merge pull request #529 from kngwyu/getter-py
...
Allow py: Python as an argument of getter
2019-07-15 00:44:33 +09:00
Alexander Niederbühl
7c687a8d38
Remove default implementation for PyGCProtocol
...
Implementations for these methods should always be provided. See #531
2019-07-14 17:26:04 +02:00
Alexander Niederbühl
72339e5bf9
Implement PyGCProtocol in test class
...
For the garbage collection to work the PyGCProtocol has to be
implemented. Ideally it should not even get compiled if it doesn't since
a missing tp_traverse can produce a segfault.
2019-07-14 15:54:45 +02:00
kngwyu
a6438ebb10
Handle a corner case in which a getter takes multiple Python
2019-07-14 14:35:50 +09:00
konstin
96a56fa9b8
Merge pull request #505 from PyO3/fix_getattr
...
Use existing fields and methods before calling custom __getattr__
2019-07-13 20:39:14 +02:00
kngwyu
60cbe2f47d
Add a test that confirms __getattr__ doesn't override
2019-07-13 23:46:25 +09:00
konstin
7a83cb6afa
Use existing fields and methods before calling custom __getattr__
...
Previously, defining `__getattr__` would override all existing fields and methods. This changes it to behave like a `__getattr__` method defined in python, i.e. the custom method is only called if there isn't a field or method of that name
2019-07-13 22:54:43 +09:00
kngwyu
383d0d3bac
Do not execute test_compule_error in kcov
2019-07-13 15:00:19 +09:00
kngwyu
721e746585
Allow py: Python as an argument of getter
2019-07-12 23:41:13 +09:00
kngwyu
fc5cdc1031
[derive-backend] Add utils::if_type_is_python
2019-07-12 22:22:56 +09:00
Yuji Kanagawa
5d85ea7fdc
Merge pull request #513 from kngwyu/pinbox
...
Refactoring around Box usages
2019-07-10 11:43:10 +09:00
Yuji Kanagawa
83d0ac4e70
Merge pull request #523 from ijl/fix-deprecation
...
Fix deprecation warnings on sync and mem
2019-07-09 20:03:12 +09:00
kngwyu
9f827f024c
Update MIN_DATE/VERSION in build.rs
2019-07-09 19:06:50 +09:00
kngwyu
27f6abddba
Do not use tox-venv in travis
2019-07-09 18:48:45 +09:00
ijl
c27d9947a8
Fix deprecation warnings on sync and mem
2019-07-07 09:52:25 +00:00
konstin
9669edbfe3
Merge pull request #515 from kngwyu/guide-str-arg
...
Add arg=string example in the method arguments section in the guide
2019-06-21 20:54:26 +02:00
kngwyu
c12836edcf
Add arg=string example in the method arguments section in the guide
2019-06-21 17:07:51 +09:00
kngwyu
2fa017a508
Refactor type_object::initialize_type
2019-06-16 21:54:06 +09:00
kngwyu
02d93346c2
Use Pin<Box> for PyBuffer
2019-06-16 21:53:02 +09:00
Yuji Kanagawa
3e69389e68
Merge pull request #512 from kngwyu/expose-py-run
...
Expose py_run! macro
2019-06-15 23:50:14 +09:00
kngwyu
9073956da6
Edit CHANGELOG
2019-06-15 23:12:22 +09:00
kngwyu
503ec1a061
Use unindent crate instead of _indoc_runtime
2019-06-15 01:10:18 +09:00
kngwyu
f642dbccb2
Refactor py_run!
2019-06-14 18:58:00 +09:00
Yuji Kanagawa
05b0cb66f8
Merge pull request #506 from PyO3/more_error_information
...
Print error before on class init panic
2019-06-14 14:16:47 +09:00
kngwyu
8dbb388372
Change add_wrapped to take &impl Fn
2019-06-14 12:42:32 +09:00
kngwyu
0f9a3b1194
Expose py_run macro
2019-06-13 18:18:06 +09:00
Yuji Kanagawa
787f5d305e
Merge pull request #509 from Alexander-N/coverage
...
Ignore return code of coverage script
2019-06-09 12:55:16 +09:00
Yuji Kanagawa
1d05de8546
Merge pull request #508 from Alexander-N/patch-1
...
Add python-ext-wasm as example
2019-06-09 12:54:24 +09:00
Alexander Niederbühl
c416e0ef8e
Ignore return code of coverage script
...
A failure in the coverage script should not cause the whole build to
fail.
2019-06-08 17:08:37 +02:00
Alexander-N
c66a95d355
Add python-ext-wasm as example
2019-06-08 16:35:24 +02:00
Yuji Kanagawa
f2a7c64365
Merge pull request #503 from kngwyu/reject-generics
...
Reject generics explicitly for #[pyclass]
2019-06-06 19:02:26 +09:00
konstin
45f23c08de
Merge pull request #507 from thedrow/patch-2
...
Added fastuuid as an example
2019-06-05 21:06:23 +02:00
Omer Katz
9c3b4b7d37
Added fastuuid as an example.
2019-06-05 20:54:26 +03:00
konstin
dfd5a2abb8
Print error before on class init panic
...
Inspired by https://github.com/rust-numpy/rust-numpy/issues/97 , also fixes some warnings from the latest nightly
2019-06-05 12:01:09 +02:00