dash 4.4.0__tar.gz → 4.4.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {dash-4.4.0/dash.egg-info → dash-4.4.1}/PKG-INFO +2 -1
- {dash-4.4.0 → dash-4.4.1}/dash/_callback.py +74 -17
- dash-4.4.1/dash/_callback_signing.py +68 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_dash_renderer.py +2 -2
- {dash-4.4.0 → dash-4.4.1}/dash/_utils.py +68 -1
- {dash-4.4.0 → dash-4.4.1}/dash/backends/_flask.py +10 -0
- {dash-4.4.0 → dash-4.4.1}/dash/backends/_quart.py +9 -0
- {dash-4.4.0 → dash-4.4.1}/dash/background_callback/managers/__init__.py +14 -0
- {dash-4.4.0 → dash-4.4.1}/dash/background_callback/managers/celery_manager.py +10 -0
- {dash-4.4.0 → dash-4.4.1}/dash/background_callback/managers/diskcache_manager.py +6 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash-renderer/build/dash_renderer.dev.js +6 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dash-renderer/build/dash_renderer.min.js +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dash.py +89 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/bundle.js +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/bundle.js.map +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/demo.js +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/demo.js.map +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/package-info.json +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-datepicker.js +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-dropdown.js +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-graph.js +1 -1
- dash-4.4.1/dash/dcc/async-graph.js.map +1 -0
- dash-4.4.1/dash/dcc/async-slider.js +2 -0
- dash-4.4.1/dash/dcc/async-slider.js.map +1 -0
- dash-4.4.1/dash/dcc/dash_core_components-shared.js +3 -0
- dash-4.4.1/dash/dcc/dash_core_components-shared.js.map +1 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/dash_core_components.js +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/dash_core_components.js.map +1 -1
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/package-info.json +5 -5
- {dash-4.4.0 → dash-4.4.1}/dash/html/package-info.json +1 -1
- dash-4.4.1/dash/labextension/dist/dash-jupyterlab.tgz +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/tasks/tasks.py +23 -3
- dash-4.4.1/dash/version.py +1 -0
- {dash-4.4.0 → dash-4.4.1/dash.egg-info}/PKG-INFO +2 -1
- {dash-4.4.0 → dash-4.4.1}/dash.egg-info/SOURCES.txt +1 -0
- {dash-4.4.0 → dash-4.4.1}/dash.egg-info/requires.txt +1 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/install.txt +1 -0
- dash-4.4.0/dash/dcc/async-graph.js.map +0 -1
- dash-4.4.0/dash/dcc/async-slider.js +0 -2
- dash-4.4.0/dash/dcc/async-slider.js.map +0 -1
- dash-4.4.0/dash/dcc/dash_core_components-shared.js +0 -3
- dash-4.4.0/dash/dcc/dash_core_components-shared.js.map +0 -1
- dash-4.4.0/dash/labextension/dist/dash-jupyterlab.tgz +0 -0
- dash-4.4.0/dash/version.py +0 -1
- {dash-4.4.0 → dash-4.4.1}/LICENSE +0 -0
- {dash-4.4.0 → dash-4.4.1}/MANIFEST.in +0 -0
- {dash-4.4.0 → dash-4.4.1}/README.md +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_callback_context.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_configs.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_get_app.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_get_paths.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_grouping.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_hooks.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_jupyter.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_layout_utils.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_no_update.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_obsolete.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_pages.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_patch.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_plotly_cli.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_validate.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/_watch.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/backends/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/backends/_fastapi.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/backends/_utils.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/backends/base_server.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/backends/ws.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/background_callback/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/background_callback/_proxy_set_props.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash-renderer/build/dash-ws-worker.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/.gitkeep +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/DataTable.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/Format.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/FormatTemplate.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/_imports_.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-export.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-export.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-export.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-highlight.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-highlight.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-table.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-table.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/async-table.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/clipboard_test.2006415142.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/commons.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/commons.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/dash_table_queries_test.793109876.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/dateCoercion_test.962579238.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/dateValidation_test.371405921.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/derivedFragmentStyles_test.1414718214.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/derivedSelectedRows_test.191006642.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/derivedViewport_test.1205034743.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/edges_test.967237579.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/editColumnNames.2728755743.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/exportUtils_tests.2912917026.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/exportUtils_tests.2912917026.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/formatting_test.841259566.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/index.html +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/isEditable_test.3783358896.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/lexeme_test.1119087106.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/loadingState.3432615788.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/metadata.json +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/multi_columns_syntactic_tree.2997507671.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/numberCoercion_test.1793174015.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/numberValidation_test.2162365126.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/query_syntactic_tree_test.3221830692.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/reconcile_test.474626241.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/runtime.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/runtime.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/single_column_syntactic_tree_test.654853628.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/sorting_test.2769206697.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/table_clipboard_helper_test.53776781.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/table_clipboard_helper_test.53776781.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/table_update_test.2311585578.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/textCoercion_test.2622183371.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dash_table/textValidation_test.63529138.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/.gitkeep +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Button.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Checklist.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Clipboard.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/ConfirmDialog.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/ConfirmDialogProvider.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/DatePickerRange.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/DatePickerSingle.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Download.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Dropdown.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Geolocation.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Graph.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Input.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Interval.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Link.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Loading.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Location.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Markdown.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/RadioItems.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/RangeSlider.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Slider.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Store.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Tab.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Tabs.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Textarea.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Tooltip.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/Upload.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/_imports_.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-datepicker.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-datepicker.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-dropdown.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-dropdown.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-highlight.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-highlight.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-markdown.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-markdown.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-markdown.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-mathjax.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-slider.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-upload.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-upload.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/async-upload.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/dash_core_components-shared.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/dash_core_components.js.LICENSE.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/express.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/metadata.json +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dcc/proptypes.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/dependencies.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/polyfill@7.12.1.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/prop-types@15.8.1.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/prop-types@15.8.1.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react-dom@16.14.0.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react-dom@16.14.0.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react-dom@18.2.0.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react-dom@18.2.0.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react-dom@18.3.1.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react-dom@18.3.1.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react@16.14.0.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react@16.14.0.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react@18.2.0.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react@18.2.0.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react@18.3.1.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/deps/react@18.3.1.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/_all_keywords.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/_collect_nodes.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/_generate_prop_types.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/_jl_components_generation.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/_py_components_generation.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/_py_prop_typing.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/_r_components_generation.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/base_component.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/build_process.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/component_generator.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/development/update_components.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/exceptions.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/extract-meta.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/favicon.ico +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/fingerprint.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/.gitkeep +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/A.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Abbr.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Acronym.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Address.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Area.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Article.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Aside.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Audio.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/B.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Base.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Basefont.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Bdi.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Bdo.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Big.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Blink.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Blockquote.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Br.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Button.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Canvas.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Caption.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Center.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Cite.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Code.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Col.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Colgroup.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Content.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Data.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Datalist.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Dd.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Del.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Details.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Dfn.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Dialog.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Div.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Dl.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Dt.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Em.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Embed.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Fieldset.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Figcaption.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Figure.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Font.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Footer.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Form.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Frame.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Frameset.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/H1.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/H2.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/H3.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/H4.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/H5.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/H6.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Header.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Hgroup.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Hr.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/I.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Iframe.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Img.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Ins.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Kbd.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Keygen.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Label.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Legend.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Li.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Link.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Main.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/MapEl.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Mark.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Marquee.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Meta.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Meter.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Nav.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Nobr.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Noscript.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/ObjectEl.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Ol.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Optgroup.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Option.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Output.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/P.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Param.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Picture.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Plaintext.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Pre.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Progress.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Q.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Rb.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Rp.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Rt.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Rtc.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Ruby.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/S.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Samp.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Script.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Section.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Select.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Shadow.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Slot.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Small.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Source.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Spacer.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Span.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Strike.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Strong.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Sub.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Summary.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Sup.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Table.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Tbody.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Td.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Template.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Textarea.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Tfoot.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Th.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Thead.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Time.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Title.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Tr.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Track.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/U.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Ul.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Var.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Video.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Wbr.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/Xmp.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/_imports_.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/dash_html_components.min.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/dash_html_components.min.js.map +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/html/metadata.json +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/labextension/package.json +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/_configure.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/_decorator.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/_server.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/resources/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/resources/base.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/resources/resource_clientside_callbacks.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/resources/resource_components.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/resources/resource_layout.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/resources/resource_page_layout.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/resources/resource_pages.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/base.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/callback_adapter.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/callback_adapter_collection.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/callback_utils.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/descriptions/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/descriptions/base.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/descriptions/description_background_callbacks.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/descriptions/description_docstring.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/descriptions/description_outputs.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/base.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/input_descriptions/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/input_descriptions/base.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/input_descriptions/description_component_props.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/input_descriptions/description_docstrings.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/input_descriptions/description_html_labels.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/input_descriptions/description_pattern_matching.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/schema_callback_type_annotations.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/schema_component_proptypes.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/schema_component_proptypes_overrides.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/input_schemas/schema_pattern_matching.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/output_schemas/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/output_schemas/schema_callback_response.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/prop_roles.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/results/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/results/base.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/results/result_dataframe.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/results/result_plotly_figure.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/tool_background_tasks.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/tool_decorated_mcp_functions.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/tool_get_dash_component.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/primitives/tools/tools_callbacks.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/tasks/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/types/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/types/callback_types.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/types/component_types.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/types/exceptions.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/types/protocol.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/mcp/types/typing_utils.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/nbextension/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/nbextension/dash.json +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/nbextension/main.js +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/py.typed +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/resources.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/__init__.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/application_runners.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/browser.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/composite.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/consts.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/dash_page.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/errors.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/newhooks.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/plugin.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/testing/wait.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash/types.py +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash.egg-info/dependency_links.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash.egg-info/entry_points.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/dash.egg-info/top_level.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/ag-grid.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/async.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/celery.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/ci.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/cloud.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/compress.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/dev.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/diskcache.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/fastapi.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/quart.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/requirements/testing.txt +0 -0
- {dash-4.4.0 → dash-4.4.1}/setup.cfg +0 -0
- {dash-4.4.0 → dash-4.4.1}/setup.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dash
|
|
3
|
-
Version: 4.4.
|
|
3
|
+
Version: 4.4.1
|
|
4
4
|
Summary: A Python framework for building reactive web-apps. Developed by Plotly.
|
|
5
5
|
Home-page: https://plotly.com/dash
|
|
6
6
|
Author: Chris Parmer
|
|
@@ -45,6 +45,7 @@ Requires-Dist: nest-asyncio
|
|
|
45
45
|
Requires-Dist: setuptools
|
|
46
46
|
Requires-Dist: janus>=1.0.0
|
|
47
47
|
Requires-Dist: pydantic>=2.10
|
|
48
|
+
Requires-Dist: comm
|
|
48
49
|
Provides-Extra: async
|
|
49
50
|
Requires-Dist: flask[async]; extra == "async"
|
|
50
51
|
Provides-Extra: ci
|
|
@@ -24,6 +24,7 @@ from .exceptions import (
|
|
|
24
24
|
ImportedInsideCallbackError,
|
|
25
25
|
)
|
|
26
26
|
from ._get_app import get_app
|
|
27
|
+
from . import _callback_signing
|
|
27
28
|
from ._grouping import (
|
|
28
29
|
flatten_grouping,
|
|
29
30
|
make_grouping_by_index,
|
|
@@ -387,6 +388,24 @@ def _initialize_context(args, kwargs, inputs_state_indices, has_output, insert_o
|
|
|
387
388
|
)
|
|
388
389
|
|
|
389
390
|
|
|
391
|
+
def get_request_end_id(secret: bytes):
|
|
392
|
+
"""Return the verified end_id for the current request, or ``None``.
|
|
393
|
+
|
|
394
|
+
The renderer echoes the server-signed ``endId`` token on every callback
|
|
395
|
+
request; this verifies the signature and returns the underlying end_id so
|
|
396
|
+
background handles can be checked against it.
|
|
397
|
+
"""
|
|
398
|
+
adapter = get_app().backend.request_adapter()
|
|
399
|
+
if not adapter:
|
|
400
|
+
return None
|
|
401
|
+
token = adapter.args.get("endId")
|
|
402
|
+
return _callback_signing.unsign(secret, _callback_signing.END_SCOPE, token)
|
|
403
|
+
|
|
404
|
+
|
|
405
|
+
def _get_signing_secret() -> bytes:
|
|
406
|
+
return get_app()._get_signing_secret() # pylint: disable=protected-access
|
|
407
|
+
|
|
408
|
+
|
|
390
409
|
def _get_callback_manager(
|
|
391
410
|
kwargs: dict, background: dict
|
|
392
411
|
) -> BaseBackgroundCallbackManager:
|
|
@@ -409,8 +428,14 @@ def _get_callback_manager(
|
|
|
409
428
|
old_job = adapter.args.getlist("oldJob") if hasattr(adapter.args, "getlist") else []
|
|
410
429
|
|
|
411
430
|
if old_job:
|
|
412
|
-
|
|
413
|
-
|
|
431
|
+
secret = _get_signing_secret()
|
|
432
|
+
scope = _callback_signing.job_scope(get_request_end_id(secret))
|
|
433
|
+
for signed_job in old_job:
|
|
434
|
+
# Only terminate jobs whose handle we actually signed for this page
|
|
435
|
+
# load; ignore forged or replayed pids.
|
|
436
|
+
job = _callback_signing.unsign(secret, scope, signed_job)
|
|
437
|
+
if job is not None:
|
|
438
|
+
callback_manager.terminate_job(job)
|
|
414
439
|
|
|
415
440
|
return callback_manager
|
|
416
441
|
|
|
@@ -450,9 +475,18 @@ def _setup_background_callback(
|
|
|
450
475
|
ctx_value,
|
|
451
476
|
)
|
|
452
477
|
|
|
478
|
+
# Sign the handles before handing them to the browser so they cannot be
|
|
479
|
+
# forged (arbitrary pid kill / arbitrary cache read) or replayed from
|
|
480
|
+
# another page load. The renderer treats them as opaque strings.
|
|
481
|
+
secret = _get_signing_secret()
|
|
482
|
+
end_id = get_request_end_id(secret)
|
|
453
483
|
data = {
|
|
454
|
-
"cacheKey":
|
|
455
|
-
|
|
484
|
+
"cacheKey": _callback_signing.sign(
|
|
485
|
+
secret, _callback_signing.cache_scope(end_id), cache_key
|
|
486
|
+
),
|
|
487
|
+
"job": _callback_signing.sign(
|
|
488
|
+
secret, _callback_signing.job_scope(end_id), str(job)
|
|
489
|
+
),
|
|
456
490
|
}
|
|
457
491
|
|
|
458
492
|
cancel = background.get("cancel")
|
|
@@ -467,15 +501,38 @@ def _setup_background_callback(
|
|
|
467
501
|
return to_json(data)
|
|
468
502
|
|
|
469
503
|
|
|
504
|
+
def _read_request_handles():
|
|
505
|
+
"""Read and verify the signed cacheKey/job handles from the current request.
|
|
506
|
+
|
|
507
|
+
Returns ``(cache_key, job_id)`` as the raw (unsigned) values, or ``None`` for
|
|
508
|
+
any handle that is missing or whose signature does not verify against this
|
|
509
|
+
page load's end_id. This is what prevents a client from supplying an
|
|
510
|
+
arbitrary cache key (read/delete) or an arbitrary pid (kill).
|
|
511
|
+
"""
|
|
512
|
+
adapter = get_app().backend.request_adapter()
|
|
513
|
+
if not adapter:
|
|
514
|
+
return None, None
|
|
515
|
+
secret = _get_signing_secret()
|
|
516
|
+
end_id = get_request_end_id(secret)
|
|
517
|
+
cache_key = _callback_signing.unsign(
|
|
518
|
+
secret,
|
|
519
|
+
_callback_signing.cache_scope(end_id),
|
|
520
|
+
adapter.args.get("cacheKey"),
|
|
521
|
+
)
|
|
522
|
+
job_id = _callback_signing.unsign(
|
|
523
|
+
secret,
|
|
524
|
+
_callback_signing.job_scope(end_id),
|
|
525
|
+
adapter.args.get("job"),
|
|
526
|
+
)
|
|
527
|
+
return cache_key, job_id
|
|
528
|
+
|
|
529
|
+
|
|
470
530
|
def _progress_background_callback(
|
|
471
531
|
response, callback_manager, background, cache_key=None
|
|
472
532
|
):
|
|
473
533
|
progress_outputs = background.get("progress")
|
|
474
|
-
if cache_key is None:
|
|
475
|
-
adapter = get_app().backend.request_adapter()
|
|
476
|
-
cache_key = adapter.args.get("cacheKey")
|
|
477
534
|
|
|
478
|
-
if progress_outputs:
|
|
535
|
+
if progress_outputs and cache_key is not None:
|
|
479
536
|
# Get the progress before the result as it would be erased after the results.
|
|
480
537
|
progress = callback_manager.get_progress(cache_key)
|
|
481
538
|
if progress:
|
|
@@ -498,15 +555,19 @@ def _update_background_callback(
|
|
|
498
555
|
callback_manager = _get_callback_manager(kwargs, background)
|
|
499
556
|
|
|
500
557
|
if cache_key is None or job_id is None:
|
|
501
|
-
|
|
502
|
-
cache_key = cache_key or
|
|
503
|
-
job_id = job_id or
|
|
558
|
+
req_cache_key, req_job_id = _read_request_handles()
|
|
559
|
+
cache_key = cache_key or req_cache_key
|
|
560
|
+
job_id = job_id or req_job_id
|
|
504
561
|
|
|
505
562
|
_progress_background_callback(
|
|
506
563
|
response, callback_manager, background, cache_key=cache_key
|
|
507
564
|
)
|
|
508
565
|
|
|
509
|
-
|
|
566
|
+
if cache_key is None:
|
|
567
|
+
# No valid handle for this page load -> read nothing, delete nothing.
|
|
568
|
+
output_value = callback_manager.UNDEFINED
|
|
569
|
+
else:
|
|
570
|
+
output_value = callback_manager.get_result(cache_key, job_id)
|
|
510
571
|
|
|
511
572
|
return _handle_rest_background_callback(
|
|
512
573
|
output_value,
|
|
@@ -531,12 +592,8 @@ def _handle_rest_background_callback(
|
|
|
531
592
|
cache_key=None,
|
|
532
593
|
job_id=None,
|
|
533
594
|
):
|
|
534
|
-
if cache_key is None or job_id is None:
|
|
535
|
-
adapter = get_app().backend.request_adapter()
|
|
536
|
-
cache_key = cache_key or (adapter.args.get("cacheKey") if adapter else None)
|
|
537
|
-
job_id = job_id or (adapter.args.get("job") if adapter else None)
|
|
538
595
|
# Must get job_running after get_result since get_results terminates it.
|
|
539
|
-
job_running = callback_manager.job_running(job_id)
|
|
596
|
+
job_running = callback_manager.job_running(job_id) if job_id is not None else False
|
|
540
597
|
if not job_running and output_value is callback_manager.UNDEFINED:
|
|
541
598
|
# Job canceled -> no output to close the loop.
|
|
542
599
|
output_value = NoUpdate()
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"""Signing helpers for background-callback handles.
|
|
2
|
+
|
|
3
|
+
Background callbacks round-trip two values through the browser: the ``cacheKey``
|
|
4
|
+
(the diskcache/celery result key) and the ``job`` (the OS PID or Celery task id).
|
|
5
|
+
Historically these were sent to the client verbatim and trusted verbatim when
|
|
6
|
+
they came back, which let any HTTP client ask the server to read/delete an
|
|
7
|
+
arbitrary cache entry or to ``SIGKILL`` an arbitrary process id.
|
|
8
|
+
|
|
9
|
+
To close that, the server issues a per-page-load ``end_id`` token (signed so the
|
|
10
|
+
server can recognise the ones it minted), and every ``cacheKey``/``job`` handle
|
|
11
|
+
is HMAC-signed with a server-held secret and bound to that ``end_id``. A forged
|
|
12
|
+
PID or arbitrary cache key never carries a valid signature, and a handle minted
|
|
13
|
+
for one page load cannot be replayed from another. The client treats all of
|
|
14
|
+
these as opaque strings, so nothing about the handshake is visible to or
|
|
15
|
+
forgeable by the browser.
|
|
16
|
+
|
|
17
|
+
(This ``end_id`` is unrelated to the client-generated ``rendererId`` used for
|
|
18
|
+
SharedWorker routing in ``dash-renderer/src/utils/rendererId.ts``.)
|
|
19
|
+
"""
|
|
20
|
+
|
|
21
|
+
import hmac
|
|
22
|
+
from hashlib import sha256
|
|
23
|
+
from typing import Optional
|
|
24
|
+
|
|
25
|
+
# Separates the payload from its signature in a signed token. Chosen because it
|
|
26
|
+
# never appears in the values we sign (hex digests, integers, and gen_salt
|
|
27
|
+
# output are all limited to ``[A-Za-z0-9]``).
|
|
28
|
+
_SEP = "~"
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def _mac(secret: bytes, scope: str, value: str) -> str:
|
|
32
|
+
msg = f"{scope}\x00{value}".encode("utf-8")
|
|
33
|
+
return hmac.new(secret, msg, sha256).hexdigest()
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def sign(secret: bytes, scope: str, value: str) -> str:
|
|
37
|
+
"""Return ``value`` with an HMAC signature appended, bound to ``scope``."""
|
|
38
|
+
return f"{value}{_SEP}{_mac(secret, scope, value)}"
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def unsign(secret: bytes, scope: str, signed: Optional[str]) -> Optional[str]:
|
|
42
|
+
"""Verify a signed token and return the original value, or ``None``.
|
|
43
|
+
|
|
44
|
+
Returns ``None`` when the token is missing, malformed, or the signature does
|
|
45
|
+
not match ``scope`` under ``secret``. Uses a constant-time comparison so the
|
|
46
|
+
check does not leak the expected signature.
|
|
47
|
+
"""
|
|
48
|
+
if not signed or _SEP not in signed:
|
|
49
|
+
return None
|
|
50
|
+
|
|
51
|
+
value, _, mac = signed.rpartition(_SEP)
|
|
52
|
+
expected = _mac(secret, scope, value)
|
|
53
|
+
if hmac.compare_digest(mac, expected):
|
|
54
|
+
return value
|
|
55
|
+
return None
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
# Scope strings. The end_id is folded into the job/cache scopes so a handle is
|
|
59
|
+
# only valid for the page load it was issued to.
|
|
60
|
+
END_SCOPE = "end"
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
def job_scope(end_id: Optional[str]) -> str:
|
|
64
|
+
return f"job:{end_id or ''}"
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
def cache_scope(end_id: Optional[str]) -> str:
|
|
68
|
+
return f"cacheKey:{end_id or ''}"
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import os
|
|
2
2
|
from typing import Any, List, Dict
|
|
3
3
|
|
|
4
|
-
__version__ = "3.4.
|
|
4
|
+
__version__ = "3.4.1"
|
|
5
5
|
|
|
6
6
|
_available_react_versions = {"18.3.1", "18.2.0", "16.14.0"}
|
|
7
7
|
_available_reactdom_versions = {"18.3.1", "18.2.0", "16.14.0"}
|
|
@@ -65,7 +65,7 @@ _js_dist = [
|
|
|
65
65
|
{
|
|
66
66
|
"relative_package_path": "dash-renderer/build/dash_renderer.min.js",
|
|
67
67
|
"dev_package_path": "dash-renderer/build/dash_renderer.dev.js",
|
|
68
|
-
"external_url": "https://unpkg.com/dash-renderer@3.4.
|
|
68
|
+
"external_url": "https://unpkg.com/dash-renderer@3.4.1"
|
|
69
69
|
"/build/dash_renderer.min.js",
|
|
70
70
|
"namespace": "dash",
|
|
71
71
|
},
|
|
@@ -4,6 +4,7 @@ import sys
|
|
|
4
4
|
import uuid
|
|
5
5
|
import hashlib
|
|
6
6
|
import importlib
|
|
7
|
+
import importlib.util
|
|
7
8
|
from collections import abc
|
|
8
9
|
import subprocess
|
|
9
10
|
import logging
|
|
@@ -17,7 +18,7 @@ import os
|
|
|
17
18
|
|
|
18
19
|
from html import escape
|
|
19
20
|
from functools import wraps
|
|
20
|
-
from typing import Union
|
|
21
|
+
from typing import Optional, Union
|
|
21
22
|
from .types import RendererHooks
|
|
22
23
|
|
|
23
24
|
logger = logging.getLogger()
|
|
@@ -395,3 +396,69 @@ def get_root_path(import_name: str) -> str:
|
|
|
395
396
|
|
|
396
397
|
# filepath is import_name.py for a module, or __init__.py for a package.
|
|
397
398
|
return os.path.dirname(os.path.abspath(filepath)) # type: ignore[no-any-return]
|
|
399
|
+
|
|
400
|
+
|
|
401
|
+
def canonical_import_name(module_file: str) -> Optional[str]:
|
|
402
|
+
"""Best-effort dotted import name for a running main module.
|
|
403
|
+
|
|
404
|
+
Mirrors how the FastAPI backend derives the uvicorn import string
|
|
405
|
+
(see ``dash/backends/_fastapi.py``): the path relative to the current
|
|
406
|
+
working directory with the separator replaced by dots, so a nested
|
|
407
|
+
``package/app.py`` is aliased under ``package.app`` rather than just
|
|
408
|
+
``app``. Falls back to the bare basename when the file lives outside the
|
|
409
|
+
cwd (e.g. ``python some/dir/app.py`` where only the script's own directory
|
|
410
|
+
is on ``sys.path``).
|
|
411
|
+
|
|
412
|
+
:meta private:
|
|
413
|
+
"""
|
|
414
|
+
try:
|
|
415
|
+
rel_path = os.path.relpath(os.path.abspath(module_file), os.getcwd())
|
|
416
|
+
except (ValueError, OSError):
|
|
417
|
+
rel_path = os.path.basename(module_file)
|
|
418
|
+
if rel_path == os.pardir or rel_path.startswith(os.pardir + os.sep):
|
|
419
|
+
rel_path = os.path.basename(module_file)
|
|
420
|
+
parts = os.path.splitext(rel_path)[0].split(os.sep)
|
|
421
|
+
if not all(part.isidentifier() for part in parts):
|
|
422
|
+
return None
|
|
423
|
+
return ".".join(parts)
|
|
424
|
+
|
|
425
|
+
|
|
426
|
+
def alias_main_module(caller_name: str) -> None:
|
|
427
|
+
"""Pre-register the running main module under its canonical import name.
|
|
428
|
+
|
|
429
|
+
When the app module runs as a script (``__main__``), or is re-executed by
|
|
430
|
+
multiprocessing's spawn as ``__mp_main__`` (e.g. in the worker process of
|
|
431
|
+
uvicorn's reloader), a later import of the same file by its real name
|
|
432
|
+
("app:server" import strings) would execute the module a second time,
|
|
433
|
+
registering every callback twice. Pre-registering the running module under
|
|
434
|
+
its canonical import name makes that import resolve to this module instead
|
|
435
|
+
of re-executing the file. See issue #3818.
|
|
436
|
+
|
|
437
|
+
:meta private:
|
|
438
|
+
"""
|
|
439
|
+
if caller_name not in ("__main__", "__mp_main__"):
|
|
440
|
+
return
|
|
441
|
+
module = sys.modules.get(caller_name)
|
|
442
|
+
if module is None:
|
|
443
|
+
return
|
|
444
|
+
module_file = getattr(module, "__file__", None)
|
|
445
|
+
if not module_file:
|
|
446
|
+
return
|
|
447
|
+
import_name = canonical_import_name(module_file)
|
|
448
|
+
if import_name is None or import_name in sys.modules:
|
|
449
|
+
return
|
|
450
|
+
try:
|
|
451
|
+
spec = importlib.util.find_spec(import_name)
|
|
452
|
+
if (
|
|
453
|
+
spec is not None
|
|
454
|
+
and spec.origin is not None
|
|
455
|
+
and os.path.samefile(spec.origin, module_file)
|
|
456
|
+
):
|
|
457
|
+
sys.modules[import_name] = module
|
|
458
|
+
except (ImportError, ValueError, OSError):
|
|
459
|
+
# Aliasing is a best-effort optimization to avoid re-executing the
|
|
460
|
+
# module: find_spec may raise ImportError/ValueError if the name isn't
|
|
461
|
+
# importable (e.g. a namespace package or a parent __init__ that errors)
|
|
462
|
+
# and samefile may raise OSError if spec.origin no longer exists. In any
|
|
463
|
+
# of these cases we simply skip the alias and let the normal import run.
|
|
464
|
+
pass
|
|
@@ -285,6 +285,16 @@ class FlaskDashServer(BaseDashServer[Flask]):
|
|
|
285
285
|
response_data = await response_data
|
|
286
286
|
return cb_ctx.dash_response.set_response(data=response_data)
|
|
287
287
|
|
|
288
|
+
# Preserve the view function's identity as `dash.dash.dispatch` so that
|
|
289
|
+
# integrations keying on the fully-qualified view name keep working after
|
|
290
|
+
# the backend refactor moved dispatching out of `dash.dash.Dash.dispatch`.
|
|
291
|
+
# e.g. Flask-WTF CSRFProtect exemptions:
|
|
292
|
+
# csrf._exempt_views.add("dash.dash.dispatch")
|
|
293
|
+
for _fn in (_dispatch, _dispatch_async):
|
|
294
|
+
_fn.__name__ = "dispatch"
|
|
295
|
+
_fn.__qualname__ = "dispatch"
|
|
296
|
+
_fn.__module__ = "dash.dash"
|
|
297
|
+
|
|
288
298
|
if dash_app._use_async: # pylint: disable=protected-access
|
|
289
299
|
return _dispatch_async
|
|
290
300
|
return _dispatch
|
|
@@ -402,6 +402,15 @@ class QuartDashServer(BaseDashServer[Quart]):
|
|
|
402
402
|
response_data = await response_data
|
|
403
403
|
return cb_ctx.dash_response.set_response(data=response_data) # type: ignore[arg-type]
|
|
404
404
|
|
|
405
|
+
# Preserve the view function's identity as `dash.dash.dispatch` so that
|
|
406
|
+
# integrations keying on the fully-qualified view name keep working after
|
|
407
|
+
# the backend refactor moved dispatching out of `dash.dash.Dash.dispatch`.
|
|
408
|
+
# e.g. (Quart-)WTF CSRFProtect exemptions:
|
|
409
|
+
# csrf._exempt_views.add("dash.dash.dispatch")
|
|
410
|
+
_dispatch.__name__ = "dispatch"
|
|
411
|
+
_dispatch.__qualname__ = "dispatch"
|
|
412
|
+
_dispatch.__module__ = "dash.dash"
|
|
413
|
+
|
|
405
414
|
return _dispatch
|
|
406
415
|
|
|
407
416
|
def register_callback_api_routes(
|
|
@@ -55,6 +55,20 @@ class BaseBackgroundCallbackManager(ABC):
|
|
|
55
55
|
def get_updated_props(self, key):
|
|
56
56
|
raise NotImplementedError
|
|
57
57
|
|
|
58
|
+
# Key under which the shared background-callback signing secret is stored in
|
|
59
|
+
# the result store, so all workers agree on one secret without a configured
|
|
60
|
+
# server secret_key. See Dash._get_signing_secret.
|
|
61
|
+
SIGNING_SECRET_KEY = "__dash_background_signing_secret__"
|
|
62
|
+
|
|
63
|
+
def get_or_create_signing_secret(self, generate):
|
|
64
|
+
"""Return a signing secret shared across workers via the result store.
|
|
65
|
+
|
|
66
|
+
``generate`` is a zero-argument callable returning fresh ``bytes``. The
|
|
67
|
+
first worker to reach an empty store wins; every other worker reads back
|
|
68
|
+
the stored value, so all workers converge on a single secret.
|
|
69
|
+
"""
|
|
70
|
+
raise NotImplementedError
|
|
71
|
+
|
|
58
72
|
def build_cache_key(self, fn, args, cache_args_to_ignore, triggered):
|
|
59
73
|
try:
|
|
60
74
|
fn_source = inspect.getsource(fn)
|
|
@@ -92,6 +92,16 @@ CeleryManager requires extra dependencies which can be installed doing
|
|
|
92
92
|
def clear_cache_entry(self, key):
|
|
93
93
|
self.handle.backend.delete(key)
|
|
94
94
|
|
|
95
|
+
def get_or_create_signing_secret(self, generate):
|
|
96
|
+
backend = self.handle.backend
|
|
97
|
+
existing = backend.get(self.SIGNING_SECRET_KEY)
|
|
98
|
+
if existing is not None:
|
|
99
|
+
return existing
|
|
100
|
+
secret = generate()
|
|
101
|
+
backend.set(self.SIGNING_SECRET_KEY, secret)
|
|
102
|
+
# Re-read so workers that raced on the initial set converge on one value.
|
|
103
|
+
return backend.get(self.SIGNING_SECRET_KEY) or secret
|
|
104
|
+
|
|
95
105
|
def call_job_fn(self, key, job_fn, args, context):
|
|
96
106
|
task = job_fn.delay(key, self._make_progress_key(key), args, context)
|
|
97
107
|
return task.task_id
|
|
@@ -118,6 +118,12 @@ DiskcacheManager requires extra dependencies which can be installed doing
|
|
|
118
118
|
def clear_cache_entry(self, key):
|
|
119
119
|
self.handle.delete(key)
|
|
120
120
|
|
|
121
|
+
def get_or_create_signing_secret(self, generate):
|
|
122
|
+
# ``add`` only sets the value if the key is absent (atomic in diskcache),
|
|
123
|
+
# so the first worker wins and the rest read back the stored secret.
|
|
124
|
+
self.handle.add(self.SIGNING_SECRET_KEY, generate())
|
|
125
|
+
return self.handle.get(self.SIGNING_SECRET_KEY)
|
|
126
|
+
|
|
121
127
|
# noinspection PyUnresolvedReferences
|
|
122
128
|
def call_job_fn(self, key, job_fn, args, context):
|
|
123
129
|
"""
|