bikeshedder / sunspec

Rust crate for accessing SunSpec compliant devices in a safe and convenient way.
Apache License 2.0
4 stars 3 forks source link

fix: Replace `Box<dyn Error>` with static version #7

Open jacobsvante opened 1 week ago

jacobsvante commented 1 week ago

Since 0.5 I'm getting (dyn StdError + 'static) cannot be shared between threads safely errors. This should make it easier to use sunspec in multi-threaded environments again.

jacobsvante commented 1 week ago

@bikeshedder Would it be possible to get a release with this? 😇

bikeshedder commented 4 days ago

I've release 0.6.0 which updates tokio-modbus and adds the + Sync fix:

:package: https://crates.io/crates/sunspec/0.6.0

I'm still a bit undecided how to change the API so it doesn't use Box<dyn Error + Send>.

I've created an Issue tracking a new client API. Changing this as part of this new API makes the most sense, what do you think?