carloea2 opened a new pull request, #5603:
URL: https://github.com/apache/texera/pull/5603

   ### What changes were proposed in this PR?
   
   This PR adds Python runtime support for Python UDF UI parameters.
   
   It introduces:
   
   | Area | Change |
   | --- | --- |
   | PyTexera runtime API | Adds `self.UiParameter(...)` support on Python UDF 
operator base classes. |
   | Runtime injection bridge | Adds the `_texera_injected_ui_parameters` base 
hook that the Scala injector overrides. |
   | Typed parameter parsing | Converts injected UI parameter values into 
Python values using `AttributeType`. |
   | PyTexera exports | Exports `Dict`, `Any`, and `AttributeType` through 
`from pytexera import *`, so generated code from the Scala injector loads 
correctly. |
   | Attribute type compatibility | Adds Python enum aliases for 
`AttributeType.INTEGER` and `AttributeType.BOOLEAN`, matching the frontend 
parser’s accepted tokens. |
   | Follow-up cleanup from PR #5141 | Removes the temporary generated-code 
comment that described this runtime PR as a future dependency. |
   | Test coverage | Adds PyAmber tests for injected values, parsing, duplicate 
declarations, unsupported types, enum aliases, and instance-local state. |
   
   This PR is stacked after the merged frontend foundation PR #5043 and Scala 
backend injection PR #5141. It does not wire UI parameters into operator 
execution end to end; that integration is handled by the next PR in the stack.
   
   ### Any related issues, documentation, discussions?
   
   Part of the Python UDF UI parameter feature split from `feat/ui-parameter`.
   
   Related tracking issue / stack: #5044
   
   Stack order:
   
   1. Frontend UI parameter building blocks: #5043
   2. Scala backend injection model: #5141
   3. Python runtime support: this PR
   4. End-to-end integration
   
   ### How was this PR tested?
   
   Commands run:
   
   ```bash
   cd amber
   ruff check src/main/python/core/models/schema/attribute_type.py 
src/main/python/pytexera/udf/udf_operator.py 
src/test/python/pytexera/udf/test_udf_operator.py
   pytest src/test/python/pytexera/udf/test_udf_operator.py -q
   pytest src/test/python/pytexera/udf -q


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