Young
dd773b3413
Support tuple type also for memoryview shape arg
2021-11-27 23:39:01 +09:00
Jeong YunWon
448f7e46cc
test_bigrepeat is fixed
...
probably by #3445
2021-11-27 01:46:44 +09:00
Jeong YunWon
0ad3a29cac
Remove TODO from RustPython-invalid test_cmd_line.test_version
2021-11-27 01:34:39 +09:00
Chris Moradi
a685b236f9
Merge branch 'main' of github.com:chrismoradi/RustPython into unimplemented-abstract-methods-raise-error
2021-11-22 14:58:17 -08:00
Noa
a53451bd10
Merge pull request #3386 from coolreader18/no-arc
...
Big overhaul part 1 - replace PyRc with manual RefCount + WeakRefList
2021-11-21 17:43:50 -06:00
Jeong YunWon
b8624c617b
Merge pull request #3454 from YYun-D/doc_modify
...
Fix `bytearray` and `bytes` docs
2021-11-21 13:58:34 +09:00
YYun-D
7de142fcd1
remove bytearray and byte docs
...
Signed-off-by: YYun-D <yeo1998@naver.com >
2021-11-21 12:37:01 +09:00
Jeong YunWon
7305be893a
Merge pull request #3451 from waroad/enumerate_add_reduce
...
add reduce in enumerate
2021-11-21 09:42:34 +09:00
waroad
51e1d7607c
add reduce in enumerate
2021-11-20 20:56:26 +09:00
yyun-d
e49d7118b8
fix test_pickle in test_slice
...
Signed-off-by: yyun-d <yeo1998@naver.com >
2021-11-20 18:59:59 +09:00
Jeong YunWon
69491800e1
Merge pull request #3448 from YYun-D/test_math_modify
...
Update test_math.py to cpython 3.10
2021-11-20 17:33:42 +09:00
yyun-d
3070b19b36
Update test_math.py to cpython 3.10
2021-11-20 16:27:20 +09:00
BongYang
7b79c09c3c
pystr.rs isdecimal() checks not only ASCII but also Unicode decimals
2021-11-20 16:08:27 +09:00
rvsampson94
0fe8a06d65
Dict keys isdisjoint
2021-11-20 12:30:22 +09:00
Jeong YunWon
913b78ca44
Revert "Merge pull request #3433 from deantvv/test-update"
...
This reverts commit 9fa5c5ac66 , reversing
changes made to e7fa32c687 .
2021-11-17 17:06:51 +09:00
Noa
2a87b893fb
Reuse standard no-cb weakref
2021-11-15 16:08:47 -06:00
Noa
f9d9a1e15e
Implement weakref._remove_dead_weakref
2021-11-15 16:08:47 -06:00
Noa
ec0a658d20
Implement weakref.getweakrefs
2021-11-15 16:08:47 -06:00
Noa
e51cb82ff0
Unskip tests
2021-11-15 16:08:46 -06:00
Noa
baf581c11b
Update weakref.py and _weakrefset.py to Python 3.9
2021-11-15 16:08:46 -06:00
Jeong YunWon
9fa5c5ac66
Merge pull request #3433 from deantvv/test-update
...
Update test for `support/os_helper.py`
2021-11-16 02:47:22 +09:00
Chris Moradi
868b680305
more tests passing
2021-11-13 19:26:10 -08:00
Chris Moradi
ab58885734
Check that all abstract methods are implemented prior to instantiation
2021-11-13 17:09:26 -08:00
Dean Li
a1202f5602
test: update importlib
2021-11-13 14:21:59 +08:00
Steve Shi
742ea0c4fa
Reimpl Buffer Protocol and memoryview support ndarray with shape, stride and suboffset ( #3340 )
...
* Fix buffer protocol and memoryview
* Fix io and array the right way to use buffer protocol
* fix rebase
* fix memoryview and introduce VecBuffer
* fix deadlock
* fix memoryview avoid double release buffer
* impl ndim buffer support
* first implement nd array for buffer and memoryview
* fix slice adjust_indices
* fix adjust_indices introduct SaturatedSliceIterator
* fix memoryview cmp
* fix adjust_indices positive_order
* fix bug mark passed test
* fix clippy
* fix set_item_slice deadlock, optimize buffer
* Delete @test_113974_tmp
* Remove vec_buffer_type
* rusty names
* impl memoryview multi index
* add comments
Co-authored-by: Jeong YunWon <jeong@youknowone.org >
2021-11-13 07:17:11 +02:00
Dean Li
c15971f18a
test: update test_unicode_file
2021-11-13 04:24:06 +00:00
Dean Li
323cf44788
test: update test_urllib
2021-11-13 03:51:06 +00:00
Dean Li
2f7e695c4a
test: update test_uu
2021-11-13 03:44:54 +00:00
Dean Li
bd14debebe
test: update test_support
2021-11-13 03:36:25 +00:00
Dean Li
49a5805d11
test: use os_helper
2021-11-13 02:18:33 +00:00
Dean Li
ce75d5c6a2
test: os use os_helper
2021-11-13 02:18:33 +00:00
Dean Li
4bcf317fba
test: move os_helper out as py3.10
2021-11-13 02:18:33 +00:00
joohongpark
5ceb2be86e
fixed set.{__ror__, __sub__} operator to behave according to type
2021-11-11 16:11:48 +09:00
Dean Li
bfe10aa448
test: update test_posix.py
2021-11-06 21:04:14 +08:00
Dean Li
de4c0363bd
test: update support.wait_process from py3.10
2021-11-06 21:04:13 +08:00
Jim Fasarakis-Hilliard
625886f339
Merge pull request #3420 from zetwhite/pos_only_arg
...
fix error message for checking number of positional arguments
2021-11-06 12:10:57 +02:00
zetwhite
0523a57195
fix error message for checking number of positional arguments
2021-11-06 17:00:20 +09:00
Dean Li
04821ce730
os: fix posix_spawn exception
2021-11-06 14:40:54 +08:00
Jeong YunWon
976ed1d5eb
Merge pull request #3412 from DimitrisJim/random_seed
...
Allow any object as an argument for random.seed
2021-11-06 14:24:22 +09:00
Jim Fasarakis-Hilliard
2c2656dc7a
Raise value error on large precision values for float, int __format__ ( #3415 )
2021-11-05 21:15:49 +02:00
Daniel Watkins
14b4f0092f
cformat.rs: fix remaining test_format.test_common_format failures ( #3405 )
...
* cformat.rs: refactor fill_string to take fill_with_precision
This allows it to be used with both self.min_field_width and
self.precision, which is necessary for padding out %ds with precision.
* cformat.rs: zero-pad %d entries using precision
This matches CPython's behaviour.
* cformat.rs: don't left-adjust when filling with precision
That will always be prepending 0s to %d arguments, the LEFT_ADJUST flag
will be used by a later call to `fill_string` with the 0-filled string
as the `string` param.
* floats: handle alternate form of general formatting
* cformat.rs: convert width/precision to i32
In CPython, width can be isize but precision can only be i32. Our
implementation currently assumes the same type for both: as CPython's
tests assert on overflows for precision, but not for width, we use that
size for both.
* test_format: run test_common_format
Except for the line which raises an OverflowError in CPython, because
overflows in Rust (and therefore RustPython) abort the process
immediately.
* test_types: don't expect test_float_to_string to fail
Its string formatting usage now works as expected.
2021-11-05 12:06:58 +02:00
jfh
05c4fcf934
Allow any object as an argument for random.seed
2021-11-04 18:34:20 +02:00
jfh
aa00fe9c64
Mark failing tests in test_random.
2021-11-04 15:12:32 +02:00
jfh
950a2cfad3
Add test_random from CPython 3.8.
2021-11-04 14:56:09 +02:00
Jim Fasarakis-Hilliard
b69cfafad8
Merge pull request #3398 from deantvv/os-error-str-2
...
os: implement os-error-str according to CPython
2021-11-03 16:53:49 +02:00
Dean Li
db212d80ff
os: implement os-error-str according to CPython
...
As was: "FileNotFoundError: [Errno 2] No such file or directory (os
error 2)"
To be: "FileNotFoundError: [Errno 2] No such file or directory (os
error 2): 'filename' -> 'filename2'"
Reference CPython implementation
```
if (self->filename) {
if (self->filename2) {
return PyUnicode_FromFormat("[Errno %S] %S: %R -> %R",
OR_NONE(self->myerrno),
OR_NONE(self->strerror),
self->filename,
self->filename2);
} else {
return PyUnicode_FromFormat("[Errno %S] %S: %R",
OR_NONE(self->myerrno),
OR_NONE(self->strerror),
self->filename);
}
}
if (self->myerrno && self->strerror)
return PyUnicode_FromFormat("[Errno %S] %S",
self->myerrno, self->strerror);
```
2021-11-03 17:30:28 +08:00
Jim Fasarakis-Hilliard
612e943c6c
Merge pull request #3394 from Snowapril/fix-ga-param-chaining
...
Fix `GenericAlias` parameter chaining
2021-11-02 23:37:38 +02:00
Jeong YunWon
d78347e7ea
Merge pull request #3390 from OddBloke/oddbloke/format
...
cformat.rs: fixes to get two test_format.py tests passing
2021-11-02 18:10:08 +09:00
Jeong YunWon
1092f94a75
Merge pull request #3377 from fanninpm/fix-test-posixpath
...
Fix error and unexpected success in test_posixpath
2021-11-02 18:05:52 +09:00
Jeong YunWon
7b99d13f60
Merge pull request #3050 from RustPython/upd-deps
...
Run cargo update + upgrade
2021-11-02 17:58:02 +09:00