packages feed

net-mqtt-rpc 0.1.1.0 → 0.1.2.0

raw patch · 2 files changed

+4/−5 lines, 2 filesPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

API changes (from Hackage documentation)

- Network.MQTT.RPC: call :: (MonadCatch m, MonadThrow m, MonadIO m) => MQTTClient -> Topic -> ByteString -> m ByteString
+ Network.MQTT.RPC: call :: MonadIO m => MQTTClient -> Topic -> ByteString -> m ByteString

Files

net-mqtt-rpc.cabal view
@@ -4,10 +4,10 @@ -- -- see: https://github.com/sol/hpack ----- hash: da1d3fe3c6516d04fb3e2f8b30e4a1b7d45d7533d80c5e4aea13b9cf4a2d4b3e+-- hash: 8c7bbdf8d12bc49e03d00f8b0e716127bf59b807b6aac96a7ca1ac0f1143070b  name:           net-mqtt-rpc-version:        0.1.1.0+version:        0.1.2.0 synopsis:       Make RPC calls via an MQTT broker. description:    Please see the README on GitHub at <https://github.com/dustin/net-mqtt-rpc#readme> category:       Network
src/Network/MQTT/RPC.hs view
@@ -8,8 +8,7 @@ import           Control.Concurrent.STM (atomically, newTChanIO, readTChan,                                          writeTChan) import           Control.Monad          (when)-import           Control.Monad.Catch    (MonadCatch (..), MonadThrow (..),-                                         bracket, throwM)+import           Control.Monad.Catch    (bracket, throwM) import           Control.Monad.IO.Class (MonadIO (..)) import qualified Data.ByteString.Lazy   as BL import           Data.Text              (Text)@@ -29,7 +28,7 @@ -- Note that this client provides no timeouts or retries.  MQTT will -- guarantee the request message is delivered to the broker, but if -- there's nothing to pick it up, there may never be a response.-call :: (MonadCatch m, MonadThrow m, MonadIO m) => MQTTClient -> Topic -> BL.ByteString -> m BL.ByteString+call :: MonadIO m => MQTTClient -> Topic -> BL.ByteString -> m BL.ByteString call mc topic req = liftIO do   r <- newTChanIO   corr <- BL.fromStrict . UUID.toASCIIBytes <$> randomIO