Enterprise Logging

Connect Mito to your internal logging servers so you can track Python retention at your firm.

Collecting Mito Enterprise Logs requires a Mito Enterprise License.

Why is Mito Enterprise Logging Useful?

Python adoption is often a black box at large enterprises. You might know who has access to Python or even how often they log in to a Python environment like JupyterHub, but you probably don't know for which users their Python code is delivering business value.

Mito Enterprise Logging is designed to help you gain visibility into Python retention at your firm. The logs are designed to help you calculate metrics like:

  • Monthly Active Users of Mito

  • The top 100 most active Mito power users at your firm

  • The teams that have not yet adopted Python and require additional support

  • The most commonly used Mito features at your firm

  • The top 10 most common errors that users were blocked by

Metrics like these open the black box of Python adoption at your firm and make it easy to evaluate and communicate the success of Python automations.

Collecting Mito Enterprise Logs

Collecting Mito Enterprise Logs requires a Mito Enterprise License.

Setting up your log server

Mito is agnostic to the logging infrastructure that you use. Common log monitoring platforms include Datadog, Mixpanel, and Amplitude.

To get the most out of the logs that Mito generates, it may be useful to supplement the logs Mito generates with additional information about each user. For example: username, operating system, browser, environment, etc.

Connecting Mito to your log server

To collect logs, you must set the following environment variables in your user's Python environment:

MITO_CONFIG_LOG_SERVER_BATCH_INTERVAL='<number of seconds between log uploads>'

Once configured, Mito will upload logs to the server:

  1. In a batched manner. This reduces the burden on your log server.

  2. The logs will upload at fixed time intervals, specified by MITO_CONFIG_LOG_SERVER_BATCH_INTERVAL. If no batch interval is provided, logs will be uploaded every 10 seconds by default.

  3. From a separate thread than the main Mito processing thread. This ensures that log collection has a minimal effect on your users' experience.

  4. If log upload fails:

    1. No logs will be lost. Logs will be saved and tried again on the next upload attempt.

    2. An exponential backoff strategy is used, so upload will be retried with double the batch interval. This exponential backoff strategy avoids overburdening the server.

Together, the above mean that logs may sometimes be dropped, especially if the Python process Mito is running in is terminated unexpectedly.

Logs Generated by Mito Enterprise

Mito Usage Events

Log EventDescription


A new or existing Mito spreadsheet was created

Mito Analysis Events

Data Import and Export Events

Log Event Description


At least one sheet from an Excel workbook was imported


A range from an Excel worksheet was imported using either dynamic or static range detection


A CSV file was imported


A dataframe that was defined in the Jupyter notebook was imported using the Import Dataframe Taskpane


Data in Mito was exported to a CSV or Excel file

Data Transformation Events

Log EventDescription


A pivot table was created or updated


A column filter was applied or updated


The dataframe was sorted by a column


A column's data type was changed


Two dataframes were merged together or an existing merge was updated


Dataframes were vertically concatonated on top of eachother to creatre a new dataframe


A column(s) were deleted


A column was renamed


A column was added to the dataframe


A formula was created or updated


A column's order in the dataframe was changed


NaN values were filled using the FillNaN Taskpane


A row(s) were deleted


Duplicate values were removed from the dataframe using the Drop Duplicates Taskpane


A column was split on a delimiter into multiple columns using the Split Text to Columns Taskpane


A row was promoted to the header row


A dataframe was melted (unpivoted)


The dataframe's indexes were reset to the standard 0, 1, ... N


A dataframe was transposed


A dataframe was deleted


A dataframes was duplicated


A dataframe was renamed

Formatting Events

Log EventDescription


A column had its format changed. Ie: From plain text to accounting format


A conditional formatting or dataframe color scheme was updated.

Graphing Events

Log EventDescription


A graph was created or an existing graph had it's configuration updated. For example, a bar chart was changed to a line chart.


A graph was deleted


A graph was renamed


Log EventDescription


All errors in Mito generate an error log event that contains useful information like the error traceback needed to identify and correct a bug. Use the log param params_failed_log_event to identify which event caused the error.


The Mito Spreadsheet has completely crashed. This is the most severe error.

Example Logs

To help you understand the logs that Mito generates, below is a video of a short Mito session accompanied with the logs generated by that session. In this session the user:

  1. Renders a Mito spreadsheet

  2. Adds a column to the end of the dataframe

  3. Renames the new column to New Column

  4. Writes a spreadsheet formula, =LEFT(Last Name0, 2) to get the first two letters from the Last Name column

  5. Generates an error by attempting to create a duplicate column header

        "event": "mitosheet_rendered",
        "params_user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.2.1 Safari/605.1.15", 
        "version_python": "3.9.6", 
        "version_pandas": "2.1.2", 
        "version_mito": "0.3.131", 
        "timestamp_gmt": "2024-01-25T23:07:59Z"
        "event": "add_column_edit",
        "params_sheet_index": 0, 
        "params_column_header": "childworldfall", 
        "params_column_header_index": 5, 
        "params_public_interface_version": 3, 
        "version_python": "3.9.6", 
        "version_pandas": "2.1.2", 
        "version_mito": "0.3.131", 
        "timestamp_gmt": "2024-01-25T23:08:03Z" 
        "event": "rename_column_edit",
        "params_sheet_index": 0, 
        "params_column_id": "childworldfall", 
        "params_new_column_header": "personpersonhat", 
        "params_public_interface_version": 3, 
        "version_python": "3.9.6", 
        "version_pandas": "2.1.2", 
        "version_mito": "0.3.131", 
        "timestamp_gmt": "2024-01-25T23:08:07Z", 
        "event": "set_column_formula_edit",
        "params_sheet_index": 0, 
        "params_column_id": "childworldfall", 
        "params_formula_label": "workfallpoint", 
        "params_new_formula": "=LEFT(companypartcaseI[workfallpoint], 2)", 
        "params_index_labels_formula_is_applied_to": {"type": "timepartcase"}, 
        "params_cell_editor_location": "cell", 
        "params_public_interface_version": 3, 
        "version_python": "3.9.6", 
        "version_pandas": "2.1.2", 
        "version_mito": "0.3.131", 
        "timestamp_gmt": "2024-01-25T23:08:14Z"
        "event": "error"
        "params_sheet_index": 0, 
        "params_column_id": "womancasepoint", 
        "params_new_column_header": "timedogcase", 
        "params_public_interface_version": 3, 
        "params_failed_log_event": "add_column_edit_failed",
        "error_traceback": [
            "Traceback (most recent call last):", "  File 'mito_backend.py', line 253, in receive_message", 
            "    self.handle_edit_event(event)", 
            "    File 'mito_backend.py', line 178, in handle_edit_event", 
            "    self.steps_manager.handle_edit_event(event)", 
            "    File 'steps_manager.py', line 523, in handle_edit_event", 
            "    self.execute_and_update_steps(new_steps)", 
            "    File 'steps_manager.py', line 745, in execute_and_update_steps", 
            "    final_steps = execute_step_list_from_index(", "  File 'steps_manager.py', line 101, in execute_step_list_from_index", 
            "    new_step.set_prev_state_and_execute(last_valid_step.final_defined_state, non_skipped_steps)", 
            "    File 'step.py', line 154, in set_prev_state_and_execute", 
            "    post_state_and_execution_data = self.step_performer.execute(new_prev_state, params)", 
            "    File 'rename_column.py', line 42, in execute", 
            "    raise make_column_exists_error(new_column_header)", 
            "    mitosheet.errors.MitoError: (column_exists_error, Column Already Exists, Sorry, a column already exists with the name application sign date. Try picking a different name!)"
        "error_traceback_last_line": "mitosheet.errors.MitoError: (column_exists_error, Column Already Exists, Sorry, a column already exists with the name application sign date. Try picking a different name!\)", 
        "version_python": "3.9.6", 
        "version_pandas": "2.1.2", 
        "version_mito": "0.3.131", 
        "timestamp_gmt": "2024-01-25T23:08:20Z", 

Debugging your logging configuration

If Mito is unable to upload logs, it will generate useful errors.

To see the logs in JupyterLab, click on View > Show Log Console , and inside of the log console, change the Log Level from Warning to Debug.

For example, with the following invalid enterprise logging configuration, you should see the following error messages:

import os 
os.environ['MITO_CONFIG_VERSION'] = '2'
os.environ['MITO_CONFIG_LOG_SERVER_URL'] = 'https://invalid-url'

Last updated