Python 3.14 with Dash

Has anyone tried recently released python 3.14? I get an error on app.run(debug=True), with a message that says “AttributeError: module ‘pkgutil’ has no attribute ‘find_loader’”. If anyone has advice on how to get past this (even if your advice is to use python 3.13 for now) I would appreciate hearing from you.

Here is minimal, reproducible example:


import dash
from dash import dcc, html
import plotly.express as px
import pandas as pd

# Sample data
df = pd.DataFrame({
    "Year": [2018, 2019, 2020, 2021, 2022],
    "Sales": [100, 200, 300, 400, 500]
})

# Create a Plotly figure
fig = px.line(df, x='Year', y='Sales', title='Sales by Year')

# Initialize the Dash app
app = dash.Dash(__name__)

# Define the layout of the app
app.layout = html.Div([
    html.H1("Simple Plotly Dash Dashboard"),
    dcc.Graph(figure=fig)
])

# Run the app
if __name__ == "__main__":
    app.run(debug=True)
1 Like

Hi Mike,
I talked to my colleague @Philippe . We just need to finish this PR, which should fix it.
Thank you for reporting.

2 Likes

Thank you @adamschroeder, I appreciate it.

1 Like