Skip to content

Latest commit

 

History

History
58 lines (32 loc) · 3.21 KB

File metadata and controls

58 lines (32 loc) · 3.21 KB
graph LR
    dtale_app_DtaleFlask["dtale.app.DtaleFlask"]
    dtale_views_code_export["dtale.views.code_export"]
    dtale_global_state_DtaleBaseStore["dtale.global_state.DtaleBaseStore"]
    dtale_views_build_query["dtale.views.build_query"]
    dtale_app_DtaleFlask -- "sends HTTP Request to" --> dtale_views_code_export
    dtale_views_code_export -- "reads state from" --> dtale_global_state_DtaleBaseStore
    dtale_views_code_export -- "constructs query using" --> dtale_views_build_query
Loading

CodeBoardingDemoContact

Details

This analysis maps the conceptual roles involved in the code export feature to specific, verifiable components within the dtale codebase.

dtale.app.DtaleFlask

The main Flask application class that serves as the web server entry point. It is responsible for routing incoming HTTP requests for code generation to the appropriate view function.

Related Classes/Methods:

dtale.views.code_export

The core function that orchestrates the code generation process. Triggered by a frontend request, it retrieves the history of user actions from the session state, constructs the corresponding pandas operations, and assembles them into a complete, executable Python script. This function is the concrete implementation of the "Code Generation Service".

Related Classes/Methods:

  • dtale.views.code_export

dtale.global_state.DtaleBaseStore

An abstract base class defining the interface for session state management. It stores the sequence of data transformations, filters, and other operations performed by the user. Concrete implementations (DtaleShelf, DtaleRedis) provide the actual storage mechanism.

Related Classes/Methods:

dtale.views.build_query

A utility function that constructs a pandas DataFrame.query() string from the filter state stored in the user's session. It iterates through active filters, invoking the appropriate filter logic to build the final query expression. This function is a key part of the "Query Builder" role.

Related Classes/Methods: