Commit Graph

1103 Commits

Author SHA1 Message Date
lynskylate
c9c580d2fe Add inet_ntoa and windows gethostname 2019-08-07 01:28:17 +08:00
lynskylate
4e969e9db7 Remove unsafe code 2019-08-05 07:10:28 +08:00
lynskylate
5f4c8c65fa Impl gethostname sethostname inet_aton 2019-08-05 00:16:05 +08:00
yf
18bbe94753 Add os.openpty 2019-08-04 18:26:15 +08:00
Antonio Yang
0f4c2c10b7 byte.decode
- support ascii, utf-8 encoding
- raise LookupError for unhandled encoding
2019-08-01 22:57:17 +08:00
Noah
13d0c074e9 Merge pull request #1191 from mpajkowski/os_module
Implement several methods - os module
2019-07-31 09:11:53 -05:00
Dong-hee Na
5bfa4cec7c ascii: Improve test 2019-07-31 16:34:00 +09:00
Marcin Pajkowski
53c653fd2b Implement several methods - os module
os.getpid  [RUST STD]
os.getegid [UNIX]
os.getgid  [UNIX]
os.getsid  [UNIX]
os.getuid  [UNIX]
os.geteuid [UNIX]
os.getppid [UNIX]
os.getpgid [UNIX]
os.setgid  [UNIX]
os.setegid [UNIX]
os.setpgid [UNIX]
os.setuid  [UNIX]
os.seteuid [UNIX]
2019-07-30 18:15:33 +02:00
Dong-hee Na
4ee80a3d42 builtin: Fix hex format of ascii 2019-07-29 01:23:40 +09:00
Windel Bouwman
50dd93db1e Merge pull request #1182 from RustPython/example1
Add support for star expression in tuple.
2019-07-28 10:01:51 +02:00
Windel Bouwman
1024281014 Add support for star expression in tuple. 2019-07-27 13:10:55 +02:00
Dong-hee Na
aecb1510de builtins: Implement ascii builtin API 2019-07-27 17:44:41 +09:00
Noah
c9985499ea Add empty tuple optimization (#1178)
* Add empty tuple optimization

* Add test snippet for empty tuple
2019-07-25 17:10:16 +02:00
Noah
a91470d67e Merge pull request #1171 from mpajkowski/iter_str
Implement str iterator support
2019-07-24 15:50:32 -04:00
Noah
0e95f512d7 Merge pull request #1173 from corona10/seekable
stdlib.io: Implement seekable()
2019-07-24 10:15:42 -04:00
Windel Bouwman
fe44179320 Merge pull request #1174 from Askaholic/patch-2
Improve tests for int ratio properties
2019-07-24 09:57:08 +02:00
Windel Bouwman
1ca863dbd5 Merge pull request #1167 from cclauss/patch-1
Travis CI: Lint Python code with flake8
2019-07-24 09:04:48 +02:00
Askaholic
a7065935f8 Fix test and add test for negative numberers 2019-07-23 22:24:35 -08:00
Dong-hee Na
29248fd1fa stdlib.io: Implement seekable() 2019-07-24 14:16:37 +09:00
Marcin Pajkowski
6aeec34df0 Add tests for str.__iter__ and str.__next__ 2019-07-24 03:17:05 +02:00
Askaholic
86a1ef2ab8 Add numerator/denominator tests to snippets 2019-07-23 12:42:45 -08:00
Christian Clauss
b174453677 Travis CI: Lint Python code with flake8
These tests focus on Python syntax errors and undefined names.
2019-07-23 12:36:22 +02:00
coolreader18
5821bac2dc Update READMEs 2019-07-16 19:13:07 -05:00
Aviv Palivoda
42b1b75562 Merge pull request #1152 from RustPython/import-syntax
Address relative import with 3 dots. Closes #1052.
2019-07-16 19:03:50 +03:00
Windel Bouwman
ff762d7109 Address relative import with 3 dots. Closes #1052. 2019-07-15 21:41:43 +02:00
Aviv Palivoda
802acf7dd5 Add sys.exc_info 2019-07-15 19:26:53 +03:00
Windel Bouwman
8516ad29c9 Merge pull request #1148 from dmitrijoseph/comp
Implemented range methods lt, gt, le, ge
2019-07-15 07:02:15 +02:00
dmitrijoseph
eba282dcbe Implemented lt, gt, le, ge 2019-07-14 18:47:45 -04:00
Windel Bouwman
f752c93c0a Add sys.settrace and sys.setprofile functions to register profiling functions. 2019-07-14 12:33:22 +02:00
Windel Bouwman
2893780036 Check output of logger calls. 2019-07-11 17:48:10 +02:00
Windel Bouwman
140ad71f05 Add testcase for logging module. 2019-07-10 21:02:04 +02:00
Windel Bouwman
98e6486c98 Merge pull request #1128 from RustPython/re-kung-fu
Add time.gmtime function.
2019-07-10 20:06:43 +02:00
Windel Bouwman
dd20263fba Merge pull request #1123 from corona10/fix_complex_hash
complex: Fix hash function to work correctly
2019-07-10 19:27:59 +02:00
Windel Bouwman
fb23cc6e03 Add time.ctime, time.strftime 2019-07-10 17:37:42 +02:00
Windel Bouwman
0ab39651b8 Add time.gmtime function. 2019-07-10 16:12:30 +02:00
Windel Bouwman
d16c288ef1 Improve re module. Favor string.py over string.rs 2019-07-10 11:19:01 +02:00
Dong-hee Na
d349d254f6 complex: Fix hash function to work correctly
Currently, hash(3.1-4.2j) or hash(3.1+4.2j) is crashed due to
overflow error on RustPython.

This patch will fix this issue.
2019-07-10 09:21:19 +09:00
Windel Bouwman
9261d944a7 Merge pull request #1124 from corona10/sys_maxunicode
sys: Fix sys.maxsize and add sys.maxunicode
2019-07-09 20:33:09 +02:00
Dong-hee Na
2e618af4f9 sys: Fix sys.maxsize and add sys.maxunicode
Current implementation of sys.maxsize is unsigned type
but AFAIK the type of sys.maxsize should be identical with
Py_ssize_t which is known as signed type.

sys.maxunicode is hardcoded from cpython repository
https://github.com/python/cpython/blob/master/Python/sysmodule.c#L2654
2019-07-10 02:48:45 +09:00
Aviv Palivoda
86cbc2e66d Fix exception stack 2019-07-09 17:48:27 +03:00
Windel Bouwman
86decbb172 Merge pull request #1097 from RustPython/coolreader18/collections-deque
Add deque to collections
2019-07-09 07:16:56 +02:00
coolreader18
7b23a96d4b Fix warnings test 2019-07-07 17:27:04 -05:00
coolreader18
1c1440eb78 Add __len__ to deque 2019-07-07 15:38:57 -05:00
coolreader18
d891c87c4f Add maxlen as a named arg 2019-07-07 15:38:49 -05:00
coolreader18
9d3fa18ec8 Add __mul__ to deque 2019-07-07 15:38:47 -05:00
coolreader18
0ca6d24902 Add deque tests 2019-07-07 15:38:45 -05:00
Windel Bouwman
ff21c14c49 Merge pull request #1116 from RustPython/remove-cpython-bytecode-tests
Remove bytecode compilation.
2019-07-07 21:54:38 +02:00
Windel Bouwman
fabc260b01 Merge pull request #1117 from silmeth/exc-repr
make exceptions repr tests Python 3.7-friendly by eval-repr round-trip
2019-07-07 19:44:28 +02:00
silmeth
fe9e71167f fix big int crash in json_snippets – actually use a big integer 2019-07-07 17:17:08 +02:00
silmeth
1b539dedd0 move asserts out of round trip test utils 2019-07-07 17:13:57 +02:00