codeant-ai-for-open-source[bot] commented on PR #38172:
URL: https://github.com/apache/superset/pull/38172#issuecomment-4035312822

   ## **Sequence Diagram**
   
   This PR changes how Superset processes query results so that JSON and array 
columns are preserved as Python objects through the result set, pandas 
DataFrame, and record serialization, instead of being converted to strings, 
enabling templates like Handlebars to access nested properties.
   
   ```mermaid
   sequenceDiagram
       participant Client
       participant API
       participant Database
       participant ResultSet
       participant DataFrameUtils
   
       Client->>API: Request chart using dataset with JSON column
       API->>Database: Execute SQL query
       Database-->>API: Return rows with JSON and array values
       API->>ResultSet: Build SupersetResultSet from rows
       ResultSet->>ResultSet: Detect nested JSON and array columns and back up 
original values
       ResultSet->>DataFrameUtils: Convert to pandas DataFrame and restore 
nested columns
       DataFrameUtils->>DataFrameUtils: Convert DataFrame to records, treating 
NaN as None but keeping JSON and arrays as objects
       DataFrameUtils-->>API: Records with JSON and array objects
       API-->>Client: Response with JSON fields preserved as structured data
   ```
   
   ---
   *Generated by [CodeAnt AI](https://codeant.ai)*
   


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to