-
Notifications
You must be signed in to change notification settings - Fork 15
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
Draft integration tests for Ark #542
Conversation
c141f24
to
acba1cb
Compare
.github/workflows/amalthea-ci.yml
Outdated
@@ -42,4 +42,4 @@ jobs: | |||
- name: Run Unit Tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Candidate integration test #536 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
quote(
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa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aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
)
It should error after processing the 2nd line
0f1e2f7
to
5729312
Compare
.github/workflows/amalthea-ci.yml
Outdated
@@ -19,7 +19,10 @@ jobs: | |||
- { rust: 'nightly' } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Candidate integration test #536 (comment)
It should error when processing the extremely long arbitrary user input
readline("hi")
hi
# provide the text below as the reply
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa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aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
f33d1c3
to
ea8dda0
Compare
|
It's probably worth merging in this state because I'm encountering protocol issues when trying to make a test for errors. |
Would you mind using the new testing global to get rid of the |
Good idea, done! |
3129047
to
1ab75fe
Compare
@@ -65,6 +65,7 @@ tracing-error = "0.2.0" | |||
|
|||
[dev-dependencies] | |||
insta = { version = "1.39.0" } | |||
harp = { path = "../harp", features = ["testing"]} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So a dev-dependency takes priority over a normal dependency?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In tests dev-deps are taken into account. Then, IIUC, feature unification (https://doc.rust-lang.org/cargo/reference/features.html#feature-unification) causes the testing
flag to be added.
Now if we were able to set that path
to something completely different without causing a conflict, then I guess the normal dep is overridden by the dev-dep as you suggest.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://doc.rust-lang.org/cargo/reference/resolver.html#feature-resolver-version-2 suggests that it's indeed a matter of unification. And for this to work correctly (no unification with dev-deps when not building tests), we need the version 2 of the resolver, which we were already using.
I've now documented our new reliance on that version:
# Was necessary after switching to dev tree-sitter to fix this warning:
# > some crates are on edition 2021 which defaults to `resolver = "2"`, but
# > virtual workspaces default to `resolver = "1"`.
#
# Also necessary to enable the `testing` feature of harp only when testing
# (i.e. when building downstream packages like Ark with Harp's `testing`
# feature set in `dev-dependencies`).
resolver = "2"
crates/ark/src/interface.rs
Outdated
// Get `R_HOME`, set by Positron / CI / kernel specification | ||
let r_home = match std::env::var("R_HOME") { | ||
Ok(home) => PathBuf::from(home), | ||
Err(_) => { | ||
// Get `R_HOME` from `PATH`, via R | ||
let Ok(result) = std::process::Command::new("R").arg("RHOME").output() else { | ||
panic!("Can't find R or `R_HOME`"); | ||
}; | ||
let r_home = String::from_utf8(result.stdout).unwrap(); | ||
let r_home = r_home.trim(); | ||
std::env::set_var("R_HOME", r_home); | ||
PathBuf::from(r_home) | ||
}, | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addresses posit-dev/positron#2111?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep!
crates/ark/src/interface.rs
Outdated
// Internal initialisation flag, should only be used on the R thread | ||
self.initializing = false; | ||
|
||
// Used as thread-safe initialisation flag | ||
R_INIT.set(()).unwrap(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we get rid of initializing
and add a is_r_initialized()
helper that we use in the 2 places we check self.initializing
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would make sense but we'd get into naming conflicts with the static methods so probably not worth changing.
This is only used in WriteConsole
so I've decided we don't need to worry about synchronisation overhead here, and we now use the thread-safe RMain::is_r_initialized()
instead of the boolean flag to make things simpler.
crates/ark/src/interface.rs
Outdated
/// Wait for `RMain` singleton initialization | ||
/// | ||
/// Note that R might still not have finished starting up. | ||
/// See `wait_r_initialized()`. | ||
/// | ||
/// Thread-safe. But note you can only get access to the singleton on the R | ||
/// thread. | ||
pub fn wait_initialized() { | ||
R_MAIN_INIT.wait(); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am noting that currently we don't use this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added it for #506, though we eventually determined we could just assume R and RMain are both initialized. I think it makes sense to keep it in the API.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After writing this documentation:
/// Thread-safe, but note:
/// - Shouldn't be called from the R thread. If you're on the R thread, it
/// means that either R is initialized, or something is very wrong and waiting
/// would cause a deadlock anyway.
/// - You can wait for `RMAIN` to be initialized in another thread, but you
/// can only get access to the singleton on the R thread.
I decided to remove it from the API 🤣
Checks for crumbs on drop
Let Ark detect it from the search path via `R RHOME`
And rename `RMain::initialized()` to `RMain::is_initialized()` and make it thread-safe. It seems safer for static methods of `RMain` should be made thread-safe.
And use `RMain::is_r_initialized()` instead
0196e97
to
1f5753d
Compare
DummyFrontend
.start_r
so it can be used in unit tests. Moved frommain.rs
tostart.rs
(I took the opportunity to move things around inmain.rs
for clarity but no changes to the code).ark/tests/kernel.rs
.TODO: Flesh out tests so that we can be confident we don't break anything in #536