chitralverma commented on code in PR #6490:
URL: https://github.com/apache/opendal/pull/6490#discussion_r2499113010


##########
bindings/python/src/operator.rs:
##########
@@ -70,12 +70,13 @@ impl Operator {
                     .set_source(err)
             })
             .map_err(format_pyerr)?;
-        let map = map
-            .map(|v| {
-                v.extract::<HashMap<String, String>>()
-                    .expect("must be valid hashmap")
-            })
-            .unwrap_or_default();
+        let map = if let Some(v) = map {
+            v.iter()
+                .map(|(k, v)| Ok((k.extract::<String>()?, 
v.str()?.to_string())))

Review Comment:
   this point is kind of resolved via stubs dont you think?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to