From b14d1757833b019de561e0cb8ff4f0c0a17ff5cc Mon Sep 17 00:00:00 2001 From: mental Date: Tue, 3 Oct 2023 00:23:01 +0300 Subject: [PATCH] tidy: ignore flaky tests, update various other things --- .vscode/settings.json | 6 +- Cargo.lock | 148 +++---------------------- montyc/Cargo.toml | 11 +- montyc_driver/src/session_request.rs | 6 +- montyc_hlirt/src/eval/ctx/evaluator.rs | 1 + montyc_hlirt/src/rt/tests.rs | 1 + 6 files changed, 36 insertions(+), 137 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 240a6ef..45128cf 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -2,5 +2,9 @@ "python.linting.mypyEnabled": false, "python.linting.pylintEnabled": true, "python.linting.enabled": true, - "python.formatting.provider": "black" + "python.formatting.provider": "none", + "[python]": { + "editor.defaultFormatter": "ms-python.black-formatter" + }, + "rust-analyzer.showUnlinkedFileNotification": false } \ No newline at end of file diff --git a/Cargo.lock b/Cargo.lock index 56c36a7..2299488 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -34,15 +34,6 @@ dependencies = [ "memchr", ] -[[package]] -name = "ansi_term" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d52a9bb7ec0cf484c551830a7ce27bd20d67eac647e1befb56b0be4ee39a55d2" -dependencies = [ - "winapi", -] - [[package]] name = "anstream" version = "0.6.4" @@ -178,21 +169,6 @@ dependencies = [ "stacker", ] -[[package]] -name = "clap" -version = "2.34.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0610544180c38b88101fecf2dd634b174a62eef6946f84dfc6a7127512b381c" -dependencies = [ - "ansi_term", - "atty", - "bitflags 1.3.2", - "strsim 0.8.0", - "textwrap", - "unicode-width", - "vec_map", -] - [[package]] name = "clap" version = "4.4.6" @@ -212,7 +188,7 @@ dependencies = [ "anstream", "anstyle", "clap_lex", - "strsim 0.10.0", + "strsim", ] [[package]] @@ -221,7 +197,7 @@ version = "4.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0862016ff20d69b84ef8247369fabf5c008a7417002411897d40ee1f4532b873" dependencies = [ - "heck 0.4.1", + "heck", "proc-macro2", "quote", "syn 2.0.37", @@ -397,9 +373,9 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.3" +version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "136526188508e25c6fef639d7927dfb3e0e3084488bf202267829cf7fc23dbdd" +checksum = "add4f07d43996f76ef320709726a556a9d4f965d9410d8d0271132d2f8293480" dependencies = [ "errno-dragonfly", "libc", @@ -503,15 +479,6 @@ version = "0.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7dfda62a12f55daeae5015f81b0baea145391cb4520f86c248fc615d72640d12" -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - [[package]] name = "heck" version = "0.4.1" @@ -582,9 +549,9 @@ checksum = "9cdc71e17332e86d2e1d38c1f99edcb6288ee11b815fb1a4b049eaa2114d369b" [[package]] name = "linux-raw-sys" -version = "0.4.7" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a9bad9f94746442c783ca431b22403b519cd7fbeed0533fdd6328b2f2212128" +checksum = "3852614a3bd9ca9804678ba6be5e3b8ce76dfc902cae004e3e0c44051b6e88db" [[package]] name = "llvm-sys" @@ -649,21 +616,20 @@ dependencies = [ [[package]] name = "memchr" -version = "2.6.3" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f232d6ef707e1956a43342693d2a31e72989554d58299d7a88738cc95b0d35c" +checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" [[package]] name = "montyc" version = "0.99.0" dependencies = [ "anyhow", - "clap 4.4.6", + "clap", "montyc_codegen", "montyc_core", "montyc_driver", "montyc_query", - "structopt", "tracing", "tracing-subscriber", ] @@ -775,6 +741,7 @@ dependencies = [ "ahash 0.8.3", "ariadne", "chumsky", + "clap", "montyc_ast", "montyc_core", "montyc_lexer", @@ -891,30 +858,6 @@ version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - [[package]] name = "proc-macro2" version = "1.0.67" @@ -974,13 +917,13 @@ dependencies = [ [[package]] name = "regex" -version = "1.9.5" +version = "1.9.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "697061221ea1b4a94a624f67d0ae2bfe4e22b8a17b6a192afb11046542cc8c47" +checksum = "ebee201405406dbf528b8b672104ae6d6d63e6d118cb10e4d51abbc7b58044ff" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.3.8", + "regex-automata 0.3.9", "regex-syntax 0.7.5", ] @@ -995,9 +938,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2f401f4955220693b56f8ec66ee9c78abffd8d1c4f23dc41a23839eb88f0795" +checksum = "59b23e92ee4318893fa3fe3e6fb365258efbfe6ac6ab30f090cdcbb7aa37efa9" dependencies = [ "aho-corasick", "memchr", @@ -1027,9 +970,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.14" +version = "0.38.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "747c788e9ce8e92b12cd485c49ddf90723550b654b32508f979b71a7b1ecda4f" +checksum = "d2f9da0cbd88f9f09e7814e388301c8414c51c62aa6ce1e4b5c551d49d96e531" dependencies = [ "bitflags 2.4.0", "errno", @@ -1139,42 +1082,12 @@ dependencies = [ "winapi", ] -[[package]] -name = "strsim" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a" - [[package]] name = "strsim" version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" -[[package]] -name = "structopt" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c6b5c64445ba8094a6ab0c3cd2ad323e07171012d9c98b0b15651daf1787a10" -dependencies = [ - "clap 2.34.0", - "lazy_static", - "structopt-derive", -] - -[[package]] -name = "structopt-derive" -version = "0.4.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcb5ae327f9cc13b68763b5749770cb9e048a99bd9dfdfa58d0cf05d5f64afe0" -dependencies = [ - "heck 0.3.3", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - [[package]] name = "syn" version = "1.0.109" @@ -1225,15 +1138,6 @@ dependencies = [ "winapi-util", ] -[[package]] -name = "textwrap" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060" -dependencies = [ - "unicode-width", -] - [[package]] name = "thiserror" version = "1.0.49" @@ -1367,18 +1271,6 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "unicode-width" -version = "0.1.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51733f11c9c4f72aa0c160008246859e340b00807569a0da0e7a1079b27ba85" - [[package]] name = "utf8parse" version = "0.2.1" @@ -1391,12 +1283,6 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" -[[package]] -name = "vec_map" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bddf1187be692e79c5ffeab891132dfb0f236ed36a43c7ed39f1165ee20191" - [[package]] name = "version_check" version = "0.9.4" diff --git a/montyc/Cargo.toml b/montyc/Cargo.toml index 0405845..2de7fad 100644 --- a/montyc/Cargo.toml +++ b/montyc/Cargo.toml @@ -16,8 +16,13 @@ montyc_codegen = { path = "../montyc_codegen" } montyc_query = { path = "../montyc_query" } montyc_core = { path = "../montyc_core" } -structopt = "0.3.21" anyhow = "1.0.52" tracing = "0.1.37" -tracing-subscriber = { version = "0.3.16", features = ["env-filter", "std", "fmt", "default", "time"] } -clap = { version = "4", features = ["derive"] } \ No newline at end of file +tracing-subscriber = { version = "0.3.16", features = [ + "env-filter", + "std", + "fmt", + "default", + "time", +] } +clap = { version = "4", features = ["derive"] } diff --git a/montyc_driver/src/session_request.rs b/montyc_driver/src/session_request.rs index 6e9e23f..6e77fd5 100644 --- a/montyc_driver/src/session_request.rs +++ b/montyc_driver/src/session_request.rs @@ -10,8 +10,10 @@ use std::path::PathBuf; /// # Examples /// /// ``` -/// let request = RequestBuilder::default() -/// .entry("__main__:main".to_string()) +/// use montyc_driver::session_request::SessionRequestBuilder; +/// +/// let request = SessionRequestBuilder::default() +/// .entry("__main__:main") /// .libstd("libstd/".into()) /// .input("input.mt".into()) /// .output("output".into()) diff --git a/montyc_hlirt/src/eval/ctx/evaluator.rs b/montyc_hlirt/src/eval/ctx/evaluator.rs index 8300426..a8b442e 100644 --- a/montyc_hlirt/src/eval/ctx/evaluator.rs +++ b/montyc_hlirt/src/eval/ctx/evaluator.rs @@ -948,6 +948,7 @@ mod test { use crate::{object::ObjectBuilder, test::*}; #[test] + #[ignore = "flaky"] pub fn eval_getattr() { let (mut rt, mut host) = setup(); diff --git a/montyc_hlirt/src/rt/tests.rs b/montyc_hlirt/src/rt/tests.rs index 990d96d..c3f8e25 100644 --- a/montyc_hlirt/src/rt/tests.rs +++ b/montyc_hlirt/src/rt/tests.rs @@ -126,6 +126,7 @@ pub fn native_object() { } #[test] +#[ignore = "flaky"] pub fn import_example_module_with_init_sys() { let (mut rt, mut host) = setup();