Skip to content

ci: introduce the deff check for rust #5356

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

Closed

Conversation

vincenzopalazzo
Copy link
Collaborator

@vincenzopalazzo vincenzopalazzo commented Jun 29, 2022

This is a monkey patch, just to be sure that we did not release inconsistent code, but we can evaluate to remove the generated file? or make rust a requirements (we all love rust 🦀 )

Updating also some rust model

Rebased on top of #5364

Signed-off-by: Vincenzo Palazzo vincenzopalazzodev@gmail.com

@vincenzopalazzo vincenzopalazzo force-pushed the macros/rust_diff branch 3 times, most recently from 3047a88 to d58bb1e Compare June 29, 2022 12:31
@vincenzopalazzo vincenzopalazzo marked this pull request as ready for review June 29, 2022 12:34
@vincenzopalazzo vincenzopalazzo requested a review from cdecker as a code owner June 29, 2022 12:34
@vincenzopalazzo vincenzopalazzo changed the title ci: introduce the safety check for rust ci: introduce the deff check for rust Jun 29, 2022
@vincenzopalazzo
Copy link
Collaborator Author

vincenzopalazzo commented Jun 29, 2022

Need to look inside the CI but looks like there is some collision between Valgrind and rust?

2022-06-29T14:19:41.183Z DEBUG   lightningd: Command returned result after jcon close
------------------------------- Valgrind errors --------------------------------
Valgrind error file: valgrind-errors.55581
==55581== Syscall param statx(file_name) points to unaddressable byte(s)
==55581==    at 0x4B0188E: statx (statx.c:29)
==55581==    by 0x1133481: std::sys::unix::fs::try_statx (weak.rs:178)
==55581==    by 0x11265E0: std::fs::buffer_capacity_required (fs.rs:851)
==55581==    by 0x112675B: <std::fs::File as std::io::Read>::read_to_string (fs.rs:644)
==55581==    by 0x10DACA8: num_cpus::linux::Cgroup::param (linux.rs:214)
==55581==    by 0x10DAB39: num_cpus::linux::Cgroup::quota_us (linux.rs:203)
==55581==    by 0x10DA9C2: num_cpus::linux::Cgroup::cpu_quota (linux.rs:188)
==55581==    by 0x10DA5A1: num_cpus::linux::load_cgroups (linux.rs:149)
==55581==    by 0x10DA23D: num_cpus::linux::init_cgroups (linux.rs:129)
==55581==    by 0x10DCDC8: core::ops::function::FnOnce::call_once (function.rs:227)
==55581==    by 0x10DC749: std::sync::once::Once::call_once::{{closure}} (once.rs:276)
==55581==    by 0x21EE89: std::sync::once::Once::call_inner (once.rs:434)
==55581==  Address 0x0 is not stack'd, malloc'd or (recently) free'd
==55581== 
==55581== Syscall param statx(buf) points to unaddressable byte(s)
==55581==    at 0x4B0188E: statx (statx.c:29)
==55581==    by 0x1133481: std::sys::unix::fs::try_statx (weak.rs:178)
==55581==    by 0x11265E0: std::fs::buffer_capacity_required (fs.rs:851)
==55581==    by 0x112675B: <std::fs::File as std::io::Read>::read_to_string (fs.rs:644)
==55581==    by 0x10DACA8: num_cpus::linux::Cgroup::param (linux.rs:214)
==55581==    by 0x10DAB39: num_cpus::linux::Cgroup::quota_us (linux.rs:203)
==55581==    by 0x10DA9C2: num_cpus::linux::Cgroup::cpu_quota (linux.rs:188)
==55581==    by 0x10DA5A1: num_cpus::linux::load_cgroups (linux.rs:149)
==55581==    by 0x10DA23D: num_cpus::linux::init_cgroups (linux.rs:129)
==55581==    by 0x10DCDC8: core::ops::function::FnOnce::call_once (function.rs:227)
==55581==    by 0x10DC749: std::sync::once::Once::call_once::{{closure}} (once.rs:276)
==55581==    by 0x21EE89: std::sync::once::Once::call_inner (once.rs:434)
==55581==  Address 0x0 is not stack'd, malloc'd or (recently) free'd
==55581==
--------------------------------------------------------------------------------
Leaving base_dir /tmp/ltests-hzt9ppqp intact, it still has test sub-directories with failure details: ['test_peers_1']

@vincenzopalazzo vincenzopalazzo force-pushed the macros/rust_diff branch 2 times, most recently from 4cdc56f to 0ac24b8 Compare July 3, 2022 13:15
@niftynei niftynei added this to the v0.12 milestone Jul 11, 2022
Signed-off-by: Vincenzo Palazzo <vincenzopalazzodev@gmail.com>
Signed-off-by: Vincenzo Palazzo <vincenzopalazzodev@gmail.com>
Signed-off-by: Vincenzo Palazzo <vincenzopalazzodev@gmail.com>
@vincenzopalazzo
Copy link
Collaborator Author

Trivial Rebase

@cdecker
Copy link
Member

cdecker commented Jul 12, 2022

There is already a target called check-gen-updated, called in many of the smoke test configurations, that should be amended, before we add yet another CI configuration (a scarce resource seeing our CI backlog at the moment).

I opened #5415 as counterproposal :-)

@vincenzopalazzo
Copy link
Collaborator Author

There is already a target called check-gen-updated, called in many of the smoke test configurations, that should be amended, before we add yet another CI configuration (a scarce resource seeing our CI backlog at the moment).

I admit that I'm not a big fan of mixing required stuff with not required stuff when we are working with not standard build system for the only reason a new dev that did not know how we use rust can fall in some strange error, the #5415 is fair enough to close this!

@vincenzopalazzo vincenzopalazzo deleted the macros/rust_diff branch July 12, 2022 16:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants