Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

[BUG]-Pages redirection doesn't on DE workspace

Đang mở
#3,549 1 bình luận 0 reaction 1 người được giao Xem trên GitHub

@T4rk1n đang làm issue này rồi.

Từ ngày 7/1/2026.

Đánh giá

Issue này chưa được đánh giá.

Mô tả

Describe your context
when using redirect_from in one of the pages it return 404 on the DE workspace, however, it works fine once the app is deployed.

dash                 3.3.0

pages/overview.py

from dash import html
import dash

dash.register_page(
    __name__,
    title="New Home Page",
    path="/overview",
    redirect_from=['/home']
)


layout = html.Div([
        html.H1('This is our Overview page'),
        html.Div('This is our Overview page content.'),
    ])

app.py

import dash_mantine_components as dmc
import dash
from dash import dash, Dash, dcc
from dash_iconify import DashIconify
import os
from flask import  redirect


app = Dash(__name__, use_pages=True)

server = app.server

logo = "2026_renewal_logo.svg"

def create_main_nav_link(icon, label, href):
    return dcc.Link(
        dmc.Group(
            align='center',
            gap=10,
            style={'margin-bottom':5},
            children=[
                dmc.ThemeIcon(
                    DashIconify(icon=icon, width=36, color = 'white'),
                    size=48,
                    radius=5,
                    color='red',
                    variant="filled",
                    style={'margin-left':10}
                ),
                dmc.Text(label, size="xl", c="gray", style={'font-family':'IntegralCF-Regular'}),
            ]
        ),
        href=app.get_relative_path(href),
        style={"textDecoration": "none"},
    )

layout = dmc.AppShell(
    [
        dmc.AppShellNavbar(
            id="navbar",
            children=[
                dmc.Center(
                    dmc.Image(src=app.get_asset_url(logo), h=280, flex=0),
                ),
                dmc.Divider(),
                create_main_nav_link('bi:speedometer2','Overview', '/overview')
            ],
            p="md",
        ),
        dmc.AppShellMain(dash.page_container),
    ],
    navbar={
        "width": 500,
        "breakpoint": "sm",
        "collapsed": {"mobile": True, "desktop": False},
    },
    padding="md",
    id="appshell",
)

app.layout = dmc.MantineProvider(layout)


if __name__ == "__main__":
    app.run(debug=True) 

FYI: When I changed fullname for the routes path it worked https://github.com/plotly/dash/blob/f7bb86624badf1d175dd596c6096138c2902c327/dash/_pages.py#L164

Ngôn ngữ chính
Python
Star
24.4k
Fork
2.3k
Merge trung bình
1 ngày 21 giờ
Pull request đã merge (30 ngày)
19

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của plotly/dash

Tất cả issue của plotly/dash

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.