zhongjiajie commented on code in PR #130:
URL: 
https://github.com/apache/dolphinscheduler-sdk-python/pull/130#discussion_r1440010671


##########
src/pydolphinscheduler/tasks/http.py:
##########
@@ -83,7 +84,7 @@ def __init__(
                 "Parameter http_method %s not support.", http_method
             )
         self.http_method = http_method
-        self.http_params = http_params or []
+        self.http_params = ParameterHelper.convert_params(http_params, 
direction=Direction.IN) if http_params else []

Review Comment:
   We should keep init as simple as possible, to make it easy to track when 
some exception is raised.
   
    ```suggestion
           self._http_params = http_params
   ```
   
   and then we can add a property named `http_params` to make the transfer.
   
   we have some sample code in 
https://github.com/apache/dolphinscheduler-sdk-python/blob/e1d15274a6ffc2cf2ee3236d3ba3e8a0b1cf70d3/src/pydolphinscheduler/tasks/sub_workflow.py#L37-L44



-- 
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