pierrejeambrun commented on issue #21:
URL: 
https://github.com/apache/airflow-client-python/issues/21#issuecomment-1444643460

   `dag_id`, `state` and `external_trigger` are now read only. They should not 
be provided in the `DagRun` object. With the latest client (2.5.1) we can 
trigger dag runs like this:
   
   ```python
       # DagRun
       dag_run_api_instance = dag_run_api.DAGRunApi(api_client)
       try:
           api_response = dag_run_api_instance.post_dag_run(
               "25616-bug", 
dag_run_api.DAGRun(dag_run_id="run_from_python_api_client")
           )
           pprint(api_response)
       except airflow_client.client.OpenApiException as e:
           print("Exception when calling DagRunApi->post_dag_run: %s\n" % e)
   ```
   
![image](https://user-images.githubusercontent.com/14861206/221316351-10b441a4-7be9-42c6-94c4-27d3608fc9dc.png)
   
   Closing for now, feel free to reopen if needed.


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