@@ -325,17 +325,29 @@ impl PyEnvironmentActions {
325325 /// schema. If both flavours of the same field are passed, the
326326 /// snake-case form wins.
327327 #[ new]
328- #[ pyo3( signature = ( * , on_enter=None , on_exit=None , onEnter=None , onExit=None ) ) ]
328+ #[ pyo3( signature = ( * , on_enter=None , on_exit=None , on_wrap_env_enter= None , on_wrap_task_run= None , on_wrap_env_exit= None , onEnter=None , onExit= None , onWrapEnvEnter= None , onWrapTaskRun= None , onWrapEnvExit =None ) ) ]
329329 fn new (
330330 on_enter : Option < PyAction > ,
331331 on_exit : Option < PyAction > ,
332+ on_wrap_env_enter : Option < PyAction > ,
333+ on_wrap_task_run : Option < PyAction > ,
334+ on_wrap_env_exit : Option < PyAction > ,
332335 #[ allow( non_snake_case) ] onEnter : Option < PyAction > ,
333336 #[ allow( non_snake_case) ] onExit : Option < PyAction > ,
337+ #[ allow( non_snake_case) ] onWrapEnvEnter : Option < PyAction > ,
338+ #[ allow( non_snake_case) ] onWrapTaskRun : Option < PyAction > ,
339+ #[ allow( non_snake_case) ] onWrapEnvExit : Option < PyAction > ,
334340 ) -> Self {
335341 let on_enter = on_enter. or ( onEnter) ;
336342 let on_exit = on_exit. or ( onExit) ;
343+ let on_wrap_env_enter = on_wrap_env_enter. or ( onWrapEnvEnter) ;
344+ let on_wrap_task_run = on_wrap_task_run. or ( onWrapTaskRun) ;
345+ let on_wrap_env_exit = on_wrap_env_exit. or ( onWrapEnvExit) ;
337346 PyEnvironmentActions {
338347 inner : EnvironmentActions {
348+ on_wrap_env_enter : on_wrap_env_enter. map ( |a| a. inner ) ,
349+ on_wrap_task_run : on_wrap_task_run. map ( |a| a. inner ) ,
350+ on_wrap_env_exit : on_wrap_env_exit. map ( |a| a. inner ) ,
339351 on_enter : on_enter. map ( |a| a. inner ) ,
340352 on_exit : on_exit. map ( |a| a. inner ) ,
341353 } ,
@@ -370,6 +382,48 @@ impl PyEnvironmentActions {
370382 self . on_exit ( )
371383 }
372384
385+ #[ getter]
386+ fn on_wrap_env_enter ( & self ) -> Option < PyAction > {
387+ self . inner
388+ . on_wrap_env_enter
389+ . as_ref ( )
390+ . map ( |a| PyAction { inner : a. clone ( ) } )
391+ }
392+
393+ #[ getter]
394+ #[ pyo3( name = "onWrapEnvEnter" ) ]
395+ fn on_wrap_env_enter_camel ( & self ) -> Option < PyAction > {
396+ self . on_wrap_env_enter ( )
397+ }
398+
399+ #[ getter]
400+ fn on_wrap_task_run ( & self ) -> Option < PyAction > {
401+ self . inner
402+ . on_wrap_task_run
403+ . as_ref ( )
404+ . map ( |a| PyAction { inner : a. clone ( ) } )
405+ }
406+
407+ #[ getter]
408+ #[ pyo3( name = "onWrapTaskRun" ) ]
409+ fn on_wrap_task_run_camel ( & self ) -> Option < PyAction > {
410+ self . on_wrap_task_run ( )
411+ }
412+
413+ #[ getter]
414+ fn on_wrap_env_exit ( & self ) -> Option < PyAction > {
415+ self . inner
416+ . on_wrap_env_exit
417+ . as_ref ( )
418+ . map ( |a| PyAction { inner : a. clone ( ) } )
419+ }
420+
421+ #[ getter]
422+ #[ pyo3( name = "onWrapEnvExit" ) ]
423+ fn on_wrap_env_exit_camel ( & self ) -> Option < PyAction > {
424+ self . on_wrap_env_exit ( )
425+ }
426+
373427 fn __repr__ ( & self ) -> String {
374428 format ! (
375429 "EnvironmentActions(on_enter={}, on_exit={})" ,
@@ -398,6 +452,15 @@ impl PyEnvironmentActions {
398452 if let Some ( a) = slf. on_exit ( ) {
399453 kwargs. set_item ( "on_exit" , a) ?;
400454 }
455+ if let Some ( a) = slf. on_wrap_env_enter ( ) {
456+ kwargs. set_item ( "on_wrap_env_enter" , a) ?;
457+ }
458+ if let Some ( a) = slf. on_wrap_task_run ( ) {
459+ kwargs. set_item ( "on_wrap_task_run" , a) ?;
460+ }
461+ if let Some ( a) = slf. on_wrap_env_exit ( ) {
462+ kwargs. set_item ( "on_wrap_env_exit" , a) ?;
463+ }
401464 let cls = py. get_type :: < PyEnvironmentActions > ( ) ;
402465 let args = PyTuple :: new ( py, [ cls. into_any ( ) , kwargs. into_any ( ) ] ) ?;
403466 Ok ( ( helper, args. into ( ) ) )
0 commit comments