-
Notifications
You must be signed in to change notification settings - Fork 9
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
Cleanup samples output #22
Conversation
Alex Recommends ReportAlex recommends the following language changes, but Alex is a regular expression based algorithm, so take them with a grain of salt. ✨ 🚀 ✨ Nothing to Report ✨ 🚀 ✨ |
samples/command/consumer/src/main.rs
Outdated
@@ -28,6 +31,10 @@ fn start_show_notification_repeater(provider_uri: String, consumer_uri: String) | |||
debug!("Starting the Consumer's show notification repeater."); | |||
tokio::spawn(async move { | |||
loop { | |||
let payload: String = String::from("The show-notification request."); | |||
|
|||
info!("Sending an invoke request on entity {} with payload '{payload} to provider URI {provider_uri}", sdv::vehicle::cabin::infotainment::hmi::show_notification::ID,); |
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.
this should maybe be formatted with a new line, and the trailing comma looks strange here too
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 fixed the comma. I will let cargo fmt decide when to wrap lines.
samples/command/consumer/src/main.rs
Outdated
|
||
// Obtain the DTDL for the send_notification command. | ||
info!("Sending a find_by_id request to the Digital Twin Service for the DTDL for the send_notification command."); | ||
let mut client = DigitalTwinClient::connect("http://[::1]:50010").await?; // Devskim: ignore DS137138 | ||
info!("Sending a find_by_id request for entity id {} to the In-Vehicle Digital Twin Service URI {IN_VEHICLE_DIGITAL_TWIN_SERVICE_URI}", sdv::vehicle::cabin::infotainment::hmi::show_notification::ID); |
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 would also suggest a new line here
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 think that it is fine.
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.
Done
@@ -127,7 +133,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> { | |||
let provider_uri = String::from(uri_str_option.unwrap()); | |||
info!("The URI for the show-notification command's provider is {provider_uri}"); | |||
|
|||
let consumer_uri = format!("http://{consumer_authority}"); // Devskim: ignore DS137138 | |||
let consumer_uri = format!("http://{CONSUMER_ADDR}"); // Devskim: ignore DS137138 |
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.
do we still need the devskim comment here?
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.
We do when it is accompanied by a "http://".
samples/mixed/consumer/src/main.rs
Outdated
@@ -28,6 +32,10 @@ fn start_show_notification_repeater(provider_uri: String, consumer_uri: String) | |||
debug!("Starting the Consumer's show-notification repeater."); | |||
tokio::spawn(async move { | |||
loop { | |||
let payload: String = String::from("show-notification request"); | |||
|
|||
info!("Sending an invoke request on entity {} with payload '{payload} to provider URI {provider_uri}", sdv::vehicle::cabin::infotainment::hmi::show_notification::ID,); |
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.
suggest a newline
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.
Done
* Cleanup samples output * Cleanup samples output * Cleanup samples output * Cleanup samples output * Cleanup samples output * Cleanup samples output
No description provided.