https://github.com/dimitrisjim/zoot
Sync stdlib between CPython and RustPython (WIP)
https://github.com/dimitrisjim/zoot
Last synced: 2 months ago
JSON representation
Sync stdlib between CPython and RustPython (WIP)
- Host: GitHub
- URL: https://github.com/dimitrisjim/zoot
- Owner: DimitrisJim
- License: mit
- Created: 2022-12-04T20:59:08.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-01-16T13:31:18.000Z (over 2 years ago)
- Last Synced: 2025-01-25T10:28:23.175Z (4 months ago)
- Language: Python
- Homepage:
- Size: 99.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# zoot
Sync stdlib between CPython and RustPython. Currently just copies a file over from CPython to RustPython,
grabs any decorators previously specified in the RustPython test file, and then re-applies those
to the new file copied over.Decorators currently used throughout the test-suite are of the form:
```python
# TODO: RUSTPYTHON
@unittest.expectedFailure
```or:
```python
@unittest.skip("TODO: RUSTPYTHON ")
```the `skip` version of the decorators is very rarely used with a test class.
These decorators denote missing/faulty functionality in RustPython. They are extracted from the test file found
in the RustPython repo and then re-applied along with any preceding `# TODO: RUSTPYTHON` comments to the new file
copied over from CPython.Ideally, can automatically mark tests that are failing in rustpython.
## Usage
Flesh this out a bit more.
```bash
$ python -m zoot --cpython --rustpython
```## Requirements
Requires `libCST` and Python 3.8+, `pytest` for testing.
### A couple of TODOs:
1. Execute test files with tip of rustpython binary and add skips when necessary? -- This requires
disambiguation of different error codes returned and a way to grab test-names. Can do this with
the test lib.
2. Have it watch for file changes in the CPython repo and automatically automatically open a PR for the changes on
my local fork of RustPython. After reviewing the changes I can push it back upstream. Use submodules for this?