Skip to content

Merge to release #1741

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1,483 commits into from
Feb 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
1483 commits
Select commit Hold shift + click to select a range
e46b1b3
Add empty abiflags to sys
palaviv Dec 28, 2019
7518faa
Add mode parameter to mkdir
palaviv Dec 28, 2019
4aa032d
Add time.perf_counter
palaviv Dec 28, 2019
4c7c5fd
Change test code to allow running
palaviv Dec 28, 2019
e194254
Add expectedFailure on failing test_bool tests
palaviv Dec 28, 2019
88c477f
Fix CR comments
palaviv Dec 28, 2019
30473d3
Add support for string formatting of floats with ":f" format code
doyshinda Dec 28, 2019
31d3fc6
Merge pull request #1651 from doyshinda/impl_format_for_float
coolreader18 Jan 1, 2020
e84ecaf
bump up num-bigint to 0.2.4 to fix modpow
youknowone Jan 2, 2020
13914e0
objstr::get_value -> objstr::clone_value
youknowone Jan 2, 2020
92ba35d
Allow to skip VM param for IntoPyNativeFunc functions
youknowone Dec 28, 2019
102b91a
Merge pull request #1653 from youknowone/fix-modpow
coolreader18 Jan 2, 2020
1913f03
Support eval and exec mode in wasm
yanganto Dec 27, 2019
73f1b11
Merge pull request #1648 from yanganto/wasm-exec-mode
coolreader18 Jan 3, 2020
765089d
Add support for the `%` format code for floats.
doyshinda Jan 3, 2020
b3d887f
Merge pull request #1657 from doyshinda/impl_percent_format
coolreader18 Jan 4, 2020
cdba57d
Merge pull request #1650 from palaviv/run-unittests
coolreader18 Jan 4, 2020
857c5e3
Add stub frame.clear
palaviv Jan 4, 2020
641418f
Add __main__ to test lib
palaviv Jan 4, 2020
9b37be8
Add test_compare
palaviv Jan 4, 2020
f068836
Mark test_compare failed test with expectedFailure
palaviv Jan 4, 2020
0e38b51
Add test_decorators
palaviv Jan 4, 2020
27da37c
Add test_list
palaviv Jan 4, 2020
247d814
Mark failed and error tests for lists
palaviv Jan 4, 2020
4c0e7bf
Add TODO on all marked tests
palaviv Jan 4, 2020
f015423
Run CPython test suite in travis CI
palaviv Jan 4, 2020
44bd0b6
introduce PyArithmaticValue
youknowone Dec 21, 2019
b1e582e
Adapt PyReturn to PyFloat
youknowone Dec 21, 2019
6bba9ff
PyComparisonValue
youknowone Jan 4, 2020
6a15801
Implement the '%' string format code for integers
doyshinda Jan 5, 2020
8494979
Reorganize unicodedata and add unicodedata.ucd_3_2_0
coolreader18 Dec 26, 2019
98211a3
Try to cut down on the # of unicode crates we use
coolreader18 Dec 26, 2019
7d3f341
Add tests
coolreader18 Dec 29, 2019
f93d976
Merge pull request #1658 from RustPython/coolreader18/unicode-stuff
coolreader18 Jan 5, 2020
baeed51
Add os.chroot
jhyeom26 Jan 5, 2020
22b1692
Merge pull request #1642 from youknowone/pyreturn
youknowone Jan 5, 2020
3a0f6a0
Merge pull request #1663 from jhyeom26/add-chroot
youknowone Jan 5, 2020
a3293a7
Merge pull request #1662 from doyshinda/impl_percent_format_for_int
palaviv Jan 5, 2020
9f4f8ad
PyTuple::elements into private
youknowone Jan 2, 2020
6f313c1
Refactor tuple comparison operators
youknowone Jan 2, 2020
50ff5e8
sequence comparison uses `impl SimpleSeq` rather than `dyn SimpleSeq`
youknowone Jan 2, 2020
0aca07a
rustpython_vm::sequence & PySequenceContainer
youknowone Jan 5, 2020
2912d79
Add htons, ntohl, and ntohs to socket.rs
metaphorshear Jan 7, 2020
0e583b2
Refactor PyList to have elements as private field
youknowone Jan 7, 2020
12725a3
PyList::borrow_sequence to borrow SimpleSeq
youknowone Jan 7, 2020
18fcd99
SimpleSeq for PyDeque
youknowone Jan 7, 2020
226ebfa
vm::sequence for SimpleSeq utilities
youknowone Jan 7, 2020
db67018
PyList::cmp
youknowone Jan 7, 2020
5a3937f
Refactor deque and fix comparison bug
youknowone Jan 7, 2020
93e2eec
Made requested changes. (Combined short and long versions of hton and…
metaphorshear Jan 7, 2020
43d1355
Disambiguated method call for ntoh
metaphorshear Jan 7, 2020
a72109c
Formatting changes.
metaphorshear Jan 7, 2020
e4636b4
Merge pull request #1664 from metaphorshear/metaphorshear/extend-socket
coolreader18 Jan 8, 2020
5e2035f
remove unnessessary pub
youknowone Jan 7, 2020
2473f8a
Merge pull request #1655 from youknowone/refactor-tuple
youknowone Jan 8, 2020
5d50e19
dict comprehension test
youknowone Jan 8, 2020
bb9d09b
bad int test snippet
youknowone Jan 8, 2020
88c295c
inline new_bool
youknowone Jan 8, 2020
9d01ae2
socket.has_ipv6 as false (temporary)
youknowone Jan 8, 2020
73e6539
Merge pull request #1665 from youknowone/small-changes
youknowone Jan 8, 2020
a47defc
whats_left prints inherited but unimplemented attrs
youknowone Jan 8, 2020
5389ab0
more types for whats_left.sh
youknowone Jan 8, 2020
d3b2fa6
Allow serializing PyBaseExceptionRef
coolreader18 Jan 8, 2020
4a0a916
Improve wasm errors
coolreader18 Jan 8, 2020
156e6e1
Merge pull request #1654 from youknowone/clone-value
coolreader18 Jan 9, 2020
6f43d22
Fix pyExec not returning errors, remove typescript hack
coolreader18 Jan 9, 2020
c090f45
Add optional source_path argument to vm.run functions
coolreader18 Jan 9, 2020
b104183
Merge pull request #1667 from youknowone/whatsleft
youknowone Jan 10, 2020
abedbfd
Merge pull request #1660 from palaviv/run-unittests
palaviv Jan 10, 2020
098532b
Remove proc-macro-hack and use our own slightly-less-hacky hack
coolreader18 Jan 10, 2020
7d40f45
Add list iter __length_hint__ tests
coolreader18 Jan 10, 2020
6b537f1
Add objsequence::{opt_,}len
coolreader18 Dec 29, 2019
fc3ac16
Add length_hint functionality
coolreader18 Dec 29, 2019
c65dc33
Add _operator module
coolreader18 Dec 29, 2019
098393d
Add __length_hint__ to a bunch of iterators
coolreader18 Jan 3, 2020
a26e5f2
Add dict iterator __length_hint__
coolreader18 Jan 3, 2020
896f3c4
Merge pull request #1666 from RustPython/coolreader18/length_hint
coolreader18 Jan 10, 2020
bc0baa4
Merge pull request #1669 from RustPython/coolreader18/no-proc-macro-hack
coolreader18 Jan 10, 2020
c5264c9
Update wasm-bindgen, export PyError to JS
coolreader18 Jan 10, 2020
bb45696
Merge pull request #1668 from RustPython/coolreader18/exc-ser
coolreader18 Jan 11, 2020
8f036b3
quickfix Lib/test list test_extend
coolreader18 Jan 12, 2020
9fdf54f
quickfix Lib/test bool test_sane_len
coolreader18 Jan 12, 2020
2428996
Merge pull request #1649 from youknowone/func-vm
youknowone Jan 12, 2020
81d36a1
__eq__ and __ne__ compatibility
youknowone Jan 12, 2020
5c87571
Remove public field from PyBuiltinFunction
youknowone Jan 9, 2020
78b268a
Remove unbound methods from modules
youknowone Jan 11, 2020
70b63eb
new_rustfunc -> new_function & new_method to distinguish bindable fun…
youknowone Jan 11, 2020
b74d5e0
Add PyBuiltinMethod
youknowone Jan 11, 2020
947c4fe
Merge pull request #1608 from cclauss/patch-2
youknowone Jan 12, 2020
1de9b1a
math: Implement math.nextafter
corona10 Jan 12, 2020
a6eeb80
conda install
davidbrochart Jan 12, 2020
1e467a6
Merge pull request #1681 from davidbrochart/update_readme
coolreader18 Jan 12, 2020
86c098b
Merge pull request #1674 from youknowone/unbound-method
youknowone Jan 13, 2020
c6e148e
cleanup bytearray
youknowone Jan 10, 2020
36ebb04
cleanup bytes
youknowone Jan 10, 2020
1077744
cleanup memoryview
youknowone Jan 10, 2020
a11ccc4
refactor byteinner cmp
youknowone Jan 10, 2020
eb4904b
cleanup bytes with Into<Vec<u8>>
youknowone Jan 10, 2020
0b9bee9
use Vec::with_capaciity for bytes methods
youknowone Jan 10, 2020
943a148
fix bytes for wasm
youknowone Jan 10, 2020
73b363d
Add asyncbrowser demo snippet
coolreader18 Jan 9, 2020
96dfaa0
Combine index.js and main.js into one to improve UX while loading rus…
coolreader18 Jan 10, 2020
e01e711
Add the other rp.py* functions to the mini-doc
coolreader18 Jan 10, 2020
338ac4d
Update demo dependencies
coolreader18 Jan 10, 2020
53be1a0
Improve WASM testing and CI
coolreader18 Jan 10, 2020
22653ac
Add clean-webpack-plugin
coolreader18 Jan 10, 2020
6feb0d7
Fix contest
coolreader18 Jan 13, 2020
0418cc7
Add _operator._compare_digest
coolreader18 Jan 4, 2020
c4d1ad3
Merge pull request #1679 from corona10/math_nextafter
youknowone Jan 13, 2020
e10a8b2
Use new_function for nextafter to fix CI
coolreader18 Jan 13, 2020
468f7ba
Clarify that the compile error is for python code in py_compile_bytecode
coolreader18 Jan 13, 2020
c9a78bc
Put diagnostics inside generated macro for result_to_tokens_expr
coolreader18 Jan 13, 2020
80f4f91
Point to the specific function that's not IntoPyFunc for pyimpl
coolreader18 Jan 13, 2020
b29707c
Say what file failed to compile in py_compile_bytecode
coolreader18 Jan 14, 2020
9bad207
Merge pull request #1670 from youknowone/bytes
youknowone Jan 14, 2020
d812d4a
Merge pull request #1683 from RustPython/coolreader18/improve-derive-…
youknowone Jan 14, 2020
cdc3970
Add PyBuiltinDescriptor for descriptors
youknowone Jan 11, 2020
4c2e34a
Use slot descriptor get if it exists
youknowone Jan 12, 2020
ddf5c9a
Compile for redox
coolreader18 Jan 14, 2020
bc96512
Remove all(?) UB from init_type_hierarchy
coolreader18 Jan 2, 2020
b630270
Do raw trait object manipulation to get type_type to the right type
coolreader18 Jan 8, 2020
5c63311
Merge pull request #1680 from youknowone/use-slot
youknowone Jan 15, 2020
8c7e01b
pyslot guess slot name from function name
youknowone Jan 14, 2020
3ade61a
Merge pull request #1686 from RustPython/coolreader18/redox-fix
youknowone Jan 15, 2020
d31d0c6
Merge pull request #1685 from youknowone/slot-name
youknowone Jan 15, 2020
1fe526b
hide member of classmethod
youknowone Jan 10, 2020
582e5df
cleanup tuple
youknowone Jan 10, 2020
e5b91c2
Reduce &String usage
youknowone Jan 10, 2020
0b1050e
cleanup PyFunction a little bit
youknowone Jan 11, 2020
44a1701
PyStaticMethodRef -> PyStaticMethod
youknowone Jan 15, 2020
30fc460
PyClassImpl for PyFunction
youknowone Jan 15, 2020
bf0b4dc
Hide PyFunction members by moving methods to objfunction
youknowone Jan 15, 2020
c07e932
Merge pull request #1684 from youknowone/refactor-things
youknowone Jan 15, 2020
44ed27e
Update to newest syn
coolreader18 Jan 15, 2020
8a71c7e
Allow applying pyimpl to a trait
coolreader18 Jan 15, 2020
538e492
Add #[pyimpl(with(...))]
coolreader18 Jan 15, 2020
7f9a8c1
Fix clippy error
youknowone Jan 15, 2020
7c57085
Improve test check for windows platform
alvinlindstam Jan 15, 2020
1c3b4d2
Remove 'regex' from parser/Cargo.toml, as we don't use it
coolreader18 Jan 16, 2020
7f191aa
Merge pull request #1692 from alvinlindstam/os-x-tests
youknowone Jan 16, 2020
5063dd3
Added WAPM badge
syrusakbary Jan 17, 2020
8885e5f
Merge pull request #1693 from syrusakbary/patch-1
palaviv Jan 17, 2020
bdc627e
Add CPython test_dict.py
palaviv Jan 17, 2020
dd8a041
Mark failed and error tests for dict
palaviv Jan 17, 2020
f6e6ef0
objint __pos__ returns Int object
palaviv Jan 17, 2020
8fa009e
Merge pull request #1694 from palaviv/int-pos-fix
palaviv Jan 18, 2020
296f298
Merge pull request #1695 from palaviv/test-dict
palaviv Jan 18, 2020
655834d
Merge pull request #1678 from youknowone/object-cmp
youknowone Jan 18, 2020
59666f7
Make string iterator test include non-ascii
alvinlindstam Jan 19, 2020
9203eda
Skip string char traversal on each next in python str iterator
alvinlindstam Jan 19, 2020
98d942a
Add string iteration benchmark
alvinlindstam Jan 19, 2020
049df44
Fix default import from raw-loader
coolreader18 Jan 20, 2020
5b02a96
Merge pull request #1696 from alvinlindstam/string-performance
coolreader18 Jan 20, 2020
9e936eb
Merge pull request #1688 from RustPython/coolreader18/pyimpl-trait
youknowone Jan 22, 2020
69830bb
Merge pull request #1675 from RustPython/coolreader18/demo-improvements
coolreader18 Jan 23, 2020
5c4c482
Tweak partially_init macro
coolreader18 Jan 23, 2020
4a9e87b
Support keepends in Str.splitlines
palaviv Jan 24, 2020
ad4beab
fix line continuation parsing
palaviv Jan 24, 2020
8bf0d93
Refactor string.splitlines
palaviv Jan 24, 2020
8bc9157
Merge pull request #1698 from palaviv/fix-line-continue
palaviv Jan 24, 2020
d2a3ff8
Fix clippy warning
palaviv Jan 25, 2020
f553155
Add github actions CI
palaviv Jan 25, 2020
5b4dd07
Add snippets tests to github actions
palaviv Jan 25, 2020
6a88efe
Add fmt and clippy to github actions
palaviv Jan 25, 2020
7c82499
Install pipenv directly
palaviv Jan 25, 2020
b184d7c
Run github actions CI on PRs
palaviv Jan 25, 2020
32d544d
Merge pull request #1699 from palaviv/splitlines-keepends
palaviv Jan 25, 2020
3698d0e
Fix comparison operator
youknowone Jan 25, 2020
c114374
Merge pull request #1701 from youknowone/comparison
youknowone Jan 25, 2020
8c5fde9
Merge travis rust lint jobs (rustfmt + clippy)
youknowone Jan 25, 2020
fbb96c5
Fix os.symlink on windows
palaviv Jan 25, 2020
2ff552f
Merge pull request #1702 from youknowone/travis
youknowone Jan 25, 2020
346b9d2
Fix Azure Pipelines build
youknowone Jan 25, 2020
f24c150
Merge pull request #1703 from youknowone/azure
youknowone Jan 25, 2020
d5367d1
#[pymethod(magic)]: pyname as __{sig.ident}__ form
youknowone Jan 15, 2020
106c811
Fix test_bool::test_sane_len
youknowone Jan 12, 2020
bc121d7
Merge pull request #1682 from RustPython/coolreader18/compare_digest
coolreader18 Jan 25, 2020
d7085db
Merge pull request #1689 from youknowone/pymethod-magic
youknowone Jan 26, 2020
e2e5c7a
Add PyBuiltinCallable and call slot
youknowone Jan 15, 2020
80f3da9
vm/src/slots.rs
youknowone Jan 25, 2020
eea157c
Refactor PyWeak to use PyBuiltinCallable
youknowone Jan 25, 2020
9beb442
Add examples showcasing how to embed RustPython in Rust applications
cedric-h Jan 26, 2020
c6aed04
Add note about when output is printed to mini_repl.rs
cedric-h Jan 26, 2020
bebfb67
Use vm.invoke instead of calling `__call__`
youknowone Jan 26, 2020
d1f74f9
Make suggested improvements to mini_repl.rs
cedric-h Jan 26, 2020
93ccc69
Replace 'pointer' with 'memory'
cedric-h Jan 26, 2020
62de954
Use more specific scoping in hello_embed.rs
cedric-h Jan 26, 2020
e8e76fc
Merge pull request #1691 from youknowone/call-descriptor
youknowone Jan 27, 2020
d8a0eec
Merge pull request #1707 from cedric-h/embed-examples
youknowone Jan 27, 2020
88d4f62
Utility ClassItemMeta for class item meta parsing
youknowone Jan 26, 2020
e5cac96
Replace lazy_static! macro with once_cell
dralley Jan 27, 2020
750cb7e
Merge pull request #1708 from youknowone/class-item-meta
youknowone Jan 27, 2020
dc98ea6
Merge pull request #1711 from dralley/once-cell
coolreader18 Jan 27, 2020
4e2afe7
Remove wtf8 dependency
dralley Jan 27, 2020
b6e3b02
Merge pull request #1710 from dralley/remove-wtf8
coolreader18 Jan 27, 2020
ac4af12
Merge pull request #1700 from palaviv/github-actions
coolreader18 Jan 28, 2020
e6a431a
Merge pull request #1676 from youknowone/fix-cpytest
coolreader18 Jan 28, 2020
3a8f2aa
Only build the necessary rust target for test_snippets
coolreader18 Jan 24, 2020
ff97ac5
Fix subprocess test and byte{s,array}.{,l,r}strip
coolreader18 Jan 24, 2020
aa76054
Only run GH actions CI on push when branch is master
coolreader18 Jan 28, 2020
f1cf568
Merge pull request #1713 from RustPython/coolreader18/no-azure
coolreader18 Jan 28, 2020
5cc2b3c
Add branch safelist to travis
coolreader18 Jan 28, 2020
ad2d82c
cleanup objtype
youknowone Jan 26, 2020
b2ba6b2
objtype::class_*_attr into PyClassRef methods
youknowone Jan 27, 2020
421d78e
strip_prefix for tp_ and set_
youknowone Jan 27, 2020
1ecc822
PySlots::flags
youknowone Jan 27, 2020
8696452
cpython compatible type_new
youknowone Jan 27, 2020
7fd92fc
Py_TPFLAGS_BASETYPE
youknowone Jan 27, 2020
2071743
Merge pull request #1712 from youknowone/basetype
youknowone Jan 30, 2020
9685b77
Add repr for dict_keys, dict_values and dict_items
palaviv Jan 30, 2020
d1b7d65
Fix clippy warning
palaviv Jan 30, 2020
dfb3588
Add python lint to github actions
palaviv Jan 30, 2020
3b47bb2
Add CPython tests to github actions
palaviv Jan 30, 2020
24304a9
cleanup unused import warning for macOS
youknowone Jan 30, 2020
acc47ee
Merge pull request #1717 from palaviv/dict_iterator-repr
palaviv Jan 30, 2020
6440761
Add wasm test to github actions
palaviv Jan 30, 2020
3fb6fb8
Merge pull request #1718 from youknowone/macos-whence
palaviv Jan 30, 2020
c9227cd
Split rust test and snippets
palaviv Jan 30, 2020
487c742
Merge pull request #1720 from palaviv/split-github-actions
palaviv Jan 30, 2020
bd08950
Merge pull request #1719 from palaviv/more-actions
youknowone Jan 30, 2020
ee354ba
Merge pull request #1687 from RustPython/coolreader18/purge-ub
coolreader18 Jan 30, 2020
aa98bb4
Ugrade dependencies and update lockfile format
coolreader18 Jan 31, 2020
19ce0c6
Add missing assert
palaviv Jan 31, 2020
1272b91
Merge pull request #1723 from palaviv/missing-assert
youknowone Jan 31, 2020
41b6794
test_types.py from CPython v3.8.1
Jan 30, 2020
cebca9e
Add test_copy.py from CPython v3.8.1
Jan 30, 2020
c8e5040
mark failing tests from test_copy.py
youknowone Jan 30, 2020
1b9ba7c
mark failing tests of test_types.py
youknowone Jan 30, 2020
696d2de
Merge pull request #1633 from youknowone/test-copy
youknowone Jan 31, 2020
c335791
Merge pull request #1721 from youknowone/test-types
youknowone Jan 31, 2020
2a47785
Fix bytecode::CallType::Ex to raise non-str type error
youknowone Jan 31, 2020
fc0c8fd
Fix int.from_bytes type
youknowone Jan 31, 2020
f420e6c
Cache Cargo dependencies in Github Actions
coolreader18 Jan 31, 2020
72fd354
Merge pull request #1727 from youknowone/int-frombytes
youknowone Jan 31, 2020
53e27eb
Merge pull request #1728 from RustPython/coolreader18/update-lockfile
youknowone Jan 31, 2020
5d2ddc7
Check runner.os instead of matrix.os
coolreader18 Feb 1, 2020
7cdaba7
Merge pull request #1726 from youknowone/calltype-ex
youknowone Feb 1, 2020
c366c20
Fix type() error message and BaseException.__str__
youknowone Jan 31, 2020
9c12b95
Support timeout in Popen.communicate
palaviv Jan 31, 2020
3e56b3f
PyBaseObject
youknowone Feb 1, 2020
17fdc19
Merge pull request #1724 from palaviv/subprocess-timeout
palaviv Feb 1, 2020
1c2b01f
parse_number can raise error about length
youknowone Jan 31, 2020
584b0da
Merge pull request #1729 from RustPython/coolreader18/cache-actions
coolreader18 Feb 2, 2020
6c3231e
Deploy the demo using Github Actions
coolreader18 Feb 2, 2020
77e7208
github actions run pytest with -v option
youknowone Feb 1, 2020
ddfec3a
Merge pull request #1739 from youknowone/pytest-v
coolreader18 Feb 2, 2020
8272e47
Merge pull request #1737 from RustPython/coolreader18/deploy-gh-actions
coolreader18 Feb 2, 2020
52c5eec
Merge pull request #1725 from youknowone/fix-parse-number
youknowone Feb 3, 2020
e46d38e
Merge pull request #1733 from youknowone/py-base-object
coolreader18 Feb 4, 2020
3595f4e
Merge pull request #1730 from youknowone/type-error
coolreader18 Feb 4, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Lib/* linguist-vendored
159 changes: 159 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
on:
push:
branches: [master, release]
pull_request:

name: CI

jobs:
rust_tests:
name: Run rust tests
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest, ubuntu-latest, windows-latest]
fail-fast: false
steps:
- uses: actions/checkout@master
- name: Convert symlinks to hardlink (windows only)
run: powershell.exe scripts/symlinks-to-hardlinks.ps1
if: runner.os == 'Windows'
- name: Cache cargo dependencies
uses: actions/cache@v1
with:
key: ${{ runner.os }}-rust_tests-${{ hashFiles('Cargo.lock') }}
path: target
restore-keys: |
${{ runner.os }}-rust_tests-
- name: run rust tests
uses: actions-rs/cargo@v1
with:
command: test
args: --verbose --all

snippets:
name: Run snippets tests
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest, ubuntu-latest, windows-latest]
fail-fast: false
steps:
- uses: actions/checkout@master
- name: Convert symlinks to hardlink (windows only)
run: powershell.exe scripts/symlinks-to-hardlinks.ps1
if: runner.os == 'Windows'
- name: Cache cargo dependencies
uses: actions/cache@v1
with:
key: ${{ runner.os }}-snippets-${{ hashFiles('Cargo.lock') }}
path: target
restore-keys: |
${{ runner.os }}-snippets-
- name: build rustpython
uses: actions-rs/cargo@v1
with:
command: build
args: --release --verbose --all
- uses: actions/setup-python@v1
with:
python-version: 3.6
- name: Install pipenv
run: |
python -V
python -m pip install --upgrade pip
python -m pip install pipenv
- run: pipenv install
working-directory: ./tests
- name: run snippets
run: pipenv run pytest -v
working-directory: ./tests

format:
name: Check Rust code with rustfmt and clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
components: rustfmt
override: true
- name: run rustfmt
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- name: run clippy
uses: actions-rs/cargo@v1
with:
command: clippy
args: --all -- -Dwarnings

lint:
name: Lint Python code with flake8
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/setup-python@v1
with:
python-version: 3.6
- name: install flake8
run: python -m pip install flake8
- name: run lint
run: flake8 . --count --exclude=./.*,./Lib,./vm/Lib --select=E9,F63,F7,F82 --show-source --statistics

cpython:
name: Run CPython test suite
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: build rustpython
uses: actions-rs/cargo@v1
with:
command: build
args: --verbose --all
- name: run tests
run: |
export RUSTPYTHONPATH=`pwd`/Lib
cargo run -- -m test -v

wasm:
name: Check the WASM package and demo
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: install wasm-pack
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
- name: install geckodriver
run: |
wget https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-linux32.tar.gz
mkdir geckodriver
tar -xzf geckodriver-v0.24.0-linux32.tar.gz -C geckodriver
- uses: actions/setup-python@v1
with:
python-version: 3.6
- name: Install pipenv
run: |
python -V
python -m pip install --upgrade pip
python -m pip install pipenv
- run: pipenv install
working-directory: ./wasm/tests
- uses: actions/setup-node@v1
- name: run test
run: |
export PATH=$PATH:`pwd`/../../geckodriver
npm install
npm run test
working-directory: ./wasm/demo
- name: Deploy demo to Github Pages
if: success() && github.ref == 'refs/heads/release'
uses: peaceiris/actions-gh-pages@v2
env:
ACTIONS_DEPLOY_KEY: ${{ secrets.ACTIONS_DEMO_DEPLOY_KEY }}
PUBLISH_DIR: ./wasm/demo/dist
EXTERNAL_REPOSITORY: RustPython/demo
PUBLISH_BRANCH: master

2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@ tests/snippets/resources
flame-graph.html
flame.txt
flamescope.json
/wapm.lock
/wapm_packages
145 changes: 94 additions & 51 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,26 @@
before_cache: |
if command -v cargo; then
! command -v cargo-sweep && cargo install cargo-sweep
cargo sweep -i
cargo sweep -t 15
fi
branches:
only:
- master
- release
- redox-release

matrix:
before_cache:
- |
if command -v cargo; then
if ! command -v cargo-sweep; then
cargo install cargo-sweep
fi
cargo sweep -i
cargo sweep -t 15
fi
- rm -rf ~/.cargo/registry/src

jobs:
fast_finish: true
include:
- name: Run Rust tests
- name: Run Rust tests(linux)
language: rust
os: linux
rust: stable
cache: cargo
script:
Expand All @@ -20,11 +31,24 @@ matrix:
# See: https://docs.travis-ci.com/user/caching/#caches-and-build-matrices
- JOBCACHE=1

- name: Run Rust tests(osx)
language: rust
os: osx
rust: stable
cache: cargo
script:
- cargo build --verbose --all
- cargo test --verbose --all
env:
# Prevention of cache corruption.
# See: https://docs.travis-ci.com/user/caching/#caches-and-build-matrices
- JOBCACHE=11

# To test the snippets, we use Travis' Python environment (because
# installing rust ourselves is a lot easier than installing Python)
- name: Python test snippets
language: python
python: 3.6
python: 3.8
cache:
- pip
- cargo
Expand All @@ -34,31 +58,22 @@ matrix:
- CODE_COVERAGE=false
script: tests/.travis-runner.sh

- name: Check Rust code style with rustfmt
- name: Check Rust code with rustfmt and clippy
language: rust
rust: stable
cache: cargo
before_script:
- rustup component add rustfmt
script:
- cargo fmt --all -- --check
env:
- JOBCACHE=3

- name: Lint Rust code with clippy
language: rust
rust: stable
cache: cargo
before_script:
- rustup component add clippy
script:
- cargo fmt --all -- --check
- cargo clippy --all -- -Dwarnings
env:
- JOBCACHE=8
- JOBCACHE=3

- name: Lint Python code with flake8
language: python
python: 3.6
python: 3.8
cache: pip
env: JOBCACHE=9
install: pip install flake8
Expand Down Expand Up @@ -87,36 +102,9 @@ matrix:
on:
branch: release

- name: WASM online demo
language: rust
rust: stable
cache: cargo
install:
- nvm install node
# install wasm-pack
- curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
script:
- cd wasm/demo
- npm install
- npm run dist
if: branch = release
env:
- JOBCACHE=5
deploy:
- provider: pages
repo: RustPython/demo
target-branch: master
local-dir: wasm/demo/dist
skip-cleanup: true
# Set in the settings page of your repository, as a secure variable
github-token: $WEBSITE_GITHUB_TOKEN
keep-history: true
on:
branch: release

- name: Code Coverage
language: python
python: 3.6
python: 3.8
cache:
- pip
- cargo
Expand All @@ -131,7 +119,7 @@ matrix:

- name: Test WASM
language: python
python: 3.6
python: 3.8
cache:
- pip
- cargo
Expand All @@ -145,3 +133,58 @@ matrix:
env:
- JOBCACHE=7
- TRAVIS_RUST_VERSION=stable

- name: Ensure compilation on Redox OS with Redoxer
# language: minimal so that it actually uses bionic rather than xenial;
# rust isn't yet available on bionic
language: minimal
dist: bionic
if: type = cron
cache:
cargo: true
directories:
- $HOME/.redoxer
- $HOME/.cargo
before_install:
# install rust as travis does for language: rust
- curl -sSf https://build.travis-ci.org/files/rustup-init.sh | sh -s --
--default-toolchain=$TRAVIS_RUST_VERSION -y
- export PATH=${TRAVIS_HOME}/.cargo/bin:$PATH
- rustc --version
- rustup --version
- cargo --version

- sudo apt-get update -qq
- sudo apt-get install libfuse-dev
install:
- if ! command -v redoxer; then cargo install redoxfs redoxer; fi
- redoxer install
script:
- bash redox/uncomment-cargo.sh
- redoxer build --verbose
- bash redox/comment-cargo.sh
before_cache:
- |
if ! command -v cargo-sweep; then
rustup install stable
cargo +stable install cargo-sweep
fi
- cargo sweep -t 15
- rm -rf ~/.cargo/registry/src
env:
- JOBCACHE=10
- TRAVIS_RUST_VERSION=nightly

- name: Run CPython test suite
language: rust
os: linux
rust: stable
cache: cargo
script:
- cargo build --verbose --all
- export RUSTPYTHONPATH=`pwd`/Lib
- cargo run -- -m test -v
env:
# Prevention of cache corruption.
# See: https://docs.travis-ci.com/user/caching/#caches-and-build-matrices
- JOBCACHE=12
Loading