diff options
| author | Arnaud Bailly <arnaud@pankzsoft.com> | 2025-09-27 19:30:15 +0200 |
|---|---|---|
| committer | Arnaud Bailly <arnaud@pankzsoft.com> | 2025-09-27 19:30:15 +0200 |
| commit | 689f22d0818e4df65ed2766c757db1f78eb34a41 (patch) | |
| tree | b093b2deb577ef777979dda814b191845a1ae842 /lambda-calcul | |
| parent | 3364e6355dd3fa33cfafa0f811a3e455321c2225 (diff) | |
| download | lambda-nantes-689f22d0818e4df65ed2766c757db1f78eb34a41.tar.gz | |
feedback from geek camp
Diffstat (limited to 'lambda-calcul')
| -rw-r--r-- | lambda-calcul/rust/README.md | 20 | ||||
| -rw-r--r-- | lambda-calcul/rust/src/web.rs | 5 |
2 files changed, 24 insertions, 1 deletions
diff --git a/lambda-calcul/rust/README.md b/lambda-calcul/rust/README.md index cf1f26b..f4bced5 100644 --- a/lambda-calcul/rust/README.md +++ b/lambda-calcul/rust/README.md @@ -40,3 +40,23 @@ cargo run --bin server ``` There are `--port` and `--host` arguments should one want to change the default `127.0.0.1:8080` + +# NOTES + +* make command line to register more explicit +* `nc -l` is a simple echo server to show what's sent by the server +* keep the readme exposed by the server +* use JSON formatting for request/response +* debug user address on the leaderboard page + * shows status of client (not connected/connected/replying correctly or not) +* add more logs to server to help troubleshoot users access/registration +* THE SERVER MUST NOT CRASH +* cheatsheet λ-calcul exposed on `/help` +* propose to send JSON or S-Exp +* persist user state to avoid losing connections + +* ask people to implement something +* prepare starter kit to overcome +* différentes couleurs de pistes (verte/rouge/noire) +* pair programming w/ Manu, people do their own stuff if they want +* ne pas oublier le routeur wifi diff --git a/lambda-calcul/rust/src/web.rs b/lambda-calcul/rust/src/web.rs index 3f8f056..e0f0c4b 100644 --- a/lambda-calcul/rust/src/web.rs +++ b/lambda-calcul/rust/src/web.rs @@ -160,7 +160,7 @@ impl Client { fn check_result(&self, expected: &String, response: &Result<String, TestResult>) -> Test { let result = match response { Ok(expr) => { - let vals = parse(expr); + if let Ok(vals) = parse_total(expr) { let actual = eval_all(&vals) .iter() .map(|v| format!("{}", v)) @@ -171,6 +171,9 @@ impl Client { } else { TestResult::TestFailed(actual) } + } else { + TestResult::TestFailed("Could not parse response".to_string()) + } } Err(res) => res.clone(), }; |
