You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Having rfesi log errors results in a lot of unnecessary messages, when I'm handling them in the code that's calling rfesi.
For example: rfesi logs every 404, but intentionally encountering 404s is the only way to make sure that every page of data is retrieved until the response headers (#34) are exposed to end users.
letmut esi = EsiBuilder::new().user_agent("Your user agent").build()?;
esi.update_spec().await?;let new_market_data = crate::eve_client::fetch_all_pages(async_owned_closure_mut!({
esi: Esi = esi,
region: i32 = region,
};
async |page_no: i32| -> std::result::Result<Vec<MarketOrder>, EveClientError> {
debug!("Fetching market orders for region {region} page {page_no}.");
esi.group_market().get_region_orders(*region, None, Some(page_no), None).await.map_err(Into::into)})).await?;
It seems that having rfesi return a Result (as it already does) should be sufficient, and it shouldn't need to also log at the error level internally, especially when it's an error that is able to be handled by the user of the library.
The text was updated successfully, but these errors were encountered:
Having
rfesi
log errors results in a lot of unnecessary messages, when I'm handling them in the code that's callingrfesi
.For example:
rfesi
logs every404
, but intentionally encountering404
s is the only way to make sure that every page of data is retrieved until the response headers (#34) are exposed to end users.Wrapper to retrieve every page
Example usage
It seems that having
rfesi
return aResult
(as it already does) should be sufficient, and it shouldn't need to also log at the error level internally, especially when it's an error that is able to be handled by the user of the library.The text was updated successfully, but these errors were encountered: