reflex 0.8.12a1__tar.gz → 0.8.12a2__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.
Potentially problematic release.
This version of reflex might be problematic. Click here for more details.
- {reflex-0.8.12a1 → reflex-0.8.12a2}/PKG-INFO +1 -1
- {reflex-0.8.12a1 → reflex-0.8.12a2}/pyproject.toml +1 -1
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/state.js +48 -17
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/app.py +10 -10
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/app_mixins/lifespan.py +11 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/compiler/compiler.py +4 -1
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/upload.py +53 -14
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/istate/proxy.py +36 -36
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/reflex.py +18 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/state.py +2 -2
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/testing.py +14 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/build.py +67 -53
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/exec.py +1 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/export.py +4 -1
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/token_manager.py +10 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/types.py +2 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/.gitignore +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/LICENSE +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/README.md +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/apps/blank/assets/favicon.ico +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/apps/blank/code/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/apps/blank/code/blank.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/.gitignore +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/app/entry.client.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/app/routes.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/components/reflex/radix_themes_color_mode_provider.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/components/shiki/code.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/jsconfig.json +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/postcss.config.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/react-router.config.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/styles/__reflex_style_reset.css +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/helpers/dataeditor.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/helpers/debounce.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/helpers/paste.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/helpers/range.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/helpers/throttle.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/helpers/upload.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/utils/react-theme.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/.templates/web/vite-plugin-safari-cachebust.js +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/__main__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/admin.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/app_mixins/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/app_mixins/middleware.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/app_mixins/mixin.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/assets.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/compiler/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/compiler/templates.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/compiler/utils.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/app_wrap.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/app_wrap.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/bare.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/body.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/body.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/document.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/document.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/error_boundary.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/error_boundary.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/fragment.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/fragment.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/link.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/link.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/meta.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/meta.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/script.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/script.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/strict_mode.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/base/strict_mode.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/component.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/auto_scroll.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/auto_scroll.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/banner.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/banner.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/breakpoints.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/clipboard.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/clipboard.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/colors.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/cond.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/debounce.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/debounce.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/foreach.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/helmet.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/helmet.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/html.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/html.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/layout/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/match.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/responsive.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/sticky.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/sticky.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/upload.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/window_events.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/core/window_events.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/code.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/code.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/dataeditor.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/dataeditor.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/logo.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/shiki_code_block.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/datadisplay/shiki_code_block.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/dynamic.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/element.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/element.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/base.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/forms.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/forms.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/inline.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/inline.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/media.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/media.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/metadata.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/metadata.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/other.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/other.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/scripts.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/scripts.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/sectioning.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/sectioning.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/tables.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/tables.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/typography.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/el/elements/typography.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/field.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/gridjs/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/gridjs/datatable.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/gridjs/datatable.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/literals.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/lucide/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/lucide/icon.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/lucide/icon.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/markdown/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/markdown/markdown.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/markdown/markdown.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/moment/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/moment/moment.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/moment/moment.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/plotly/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/plotly/plotly.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/plotly/plotly.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/props.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/accordion.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/accordion.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/base.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/drawer.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/drawer.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/form.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/form.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/progress.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/progress.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/slider.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/primitives/slider.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/base.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/color_mode.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/color_mode.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/alert_dialog.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/alert_dialog.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/aspect_ratio.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/aspect_ratio.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/avatar.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/avatar.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/badge.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/badge.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/button.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/button.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/callout.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/callout.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/card.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/card.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/checkbox.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/checkbox.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/checkbox_cards.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/checkbox_cards.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/checkbox_group.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/checkbox_group.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/context_menu.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/context_menu.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/data_list.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/data_list.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/dialog.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/dialog.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/dropdown_menu.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/dropdown_menu.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/hover_card.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/hover_card.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/icon_button.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/icon_button.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/inset.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/inset.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/popover.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/popover.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/progress.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/progress.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/radio.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/radio.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/radio_cards.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/radio_cards.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/radio_group.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/radio_group.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/scroll_area.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/scroll_area.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/segmented_control.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/segmented_control.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/select.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/select.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/separator.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/separator.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/skeleton.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/skeleton.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/slider.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/slider.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/spinner.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/spinner.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/switch.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/switch.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/table.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/table.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/tabs.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/tabs.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/text_area.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/text_area.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/text_field.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/text_field.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/tooltip.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/components/tooltip.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/base.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/box.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/box.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/center.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/center.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/container.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/container.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/flex.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/flex.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/grid.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/grid.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/list.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/list.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/section.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/section.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/spacer.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/spacer.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/stack.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/layout/stack.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/blockquote.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/blockquote.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/code.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/code.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/heading.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/heading.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/link.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/link.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/text.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/radix/themes/typography/text.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_player/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_player/audio.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_player/audio.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_player/react_player.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_player/react_player.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_player/video.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_player/video.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_router/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_router/dom.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/react_router/dom.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/__init__.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/cartesian.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/cartesian.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/charts.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/charts.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/general.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/general.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/polar.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/polar.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/recharts.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/recharts/recharts.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/sonner/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/sonner/toast.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/sonner/toast.pyi +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/tags/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/tags/cond_tag.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/tags/iter_tag.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/tags/match_tag.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/tags/tag.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/components/tags/tagless.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/config.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/colors.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/compiler.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/config.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/custom_components.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/event.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/installer.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/route.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/state.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/constants/utils.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/custom_components/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/custom_components/custom_components.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/environment.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/event.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/experimental/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/experimental/client_state.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/experimental/hooks.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/istate/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/istate/data.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/istate/dynamic.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/istate/manager.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/istate/storage.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/istate/wrappers.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/middleware/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/middleware/hydrate_middleware.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/middleware/middleware.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/model.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/page.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/plugins/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/plugins/_screenshot.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/plugins/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/plugins/shared_tailwind.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/plugins/sitemap.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/plugins/tailwind_v3.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/plugins/tailwind_v4.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/py.typed +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/route.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/style.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/codespaces.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/compat.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/console.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/decorator.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/exceptions.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/format.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/frontend_skeleton.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/imports.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/js_runtimes.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/lazy_loader.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/misc.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/monitoring.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/net.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/path_ops.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/prerequisites.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/processes.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/pyi_generator.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/redir.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/registry.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/rename.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/serializers.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/telemetry.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/utils/templates.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/__init__.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/base.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/datetime.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/dep_tracking.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/function.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/number.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/object.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/reflex/vars/sequence.py +0 -0
- {reflex-0.8.12a1 → reflex-0.8.12a2}/scripts/hatch_build.py +0 -0
|
@@ -531,6 +531,7 @@ export const connect = async (
|
|
|
531
531
|
) => {
|
|
532
532
|
// Get backend URL object from the endpoint.
|
|
533
533
|
const endpoint = getBackendURL(EVENTURL);
|
|
534
|
+
const on_hydrated_queue = [];
|
|
534
535
|
|
|
535
536
|
// Create the socket.
|
|
536
537
|
socket.current = io(endpoint.href, {
|
|
@@ -552,7 +553,17 @@ export const connect = async (
|
|
|
552
553
|
|
|
553
554
|
function checkVisibility() {
|
|
554
555
|
if (document.visibilityState === "visible") {
|
|
555
|
-
if (!socket.current
|
|
556
|
+
if (!socket.current) {
|
|
557
|
+
connect(
|
|
558
|
+
socket,
|
|
559
|
+
dispatch,
|
|
560
|
+
transports,
|
|
561
|
+
setConnectErrors,
|
|
562
|
+
client_storage,
|
|
563
|
+
navigate,
|
|
564
|
+
params,
|
|
565
|
+
);
|
|
566
|
+
} else if (!socket.current.connected) {
|
|
556
567
|
console.log("Socket is disconnected, attempting to reconnect ");
|
|
557
568
|
socket.current.connect();
|
|
558
569
|
} else {
|
|
@@ -593,6 +604,7 @@ export const connect = async (
|
|
|
593
604
|
|
|
594
605
|
// When the socket disconnects reset the event_processing flag
|
|
595
606
|
socket.current.on("disconnect", () => {
|
|
607
|
+
socket.current = null; // allow reconnect to occur automatically
|
|
596
608
|
event_processing = false;
|
|
597
609
|
window.removeEventListener("unload", disconnectTrigger);
|
|
598
610
|
window.removeEventListener("beforeunload", disconnectTrigger);
|
|
@@ -603,6 +615,14 @@ export const connect = async (
|
|
|
603
615
|
socket.current.on("event", async (update) => {
|
|
604
616
|
for (const substate in update.delta) {
|
|
605
617
|
dispatch[substate](update.delta[substate]);
|
|
618
|
+
// handle events waiting for `is_hydrated`
|
|
619
|
+
if (
|
|
620
|
+
substate === state_name &&
|
|
621
|
+
update.delta[substate]?.is_hydrated_rx_state_
|
|
622
|
+
) {
|
|
623
|
+
queueEvents(on_hydrated_queue, socket, false, navigate, params);
|
|
624
|
+
on_hydrated_queue.length = 0;
|
|
625
|
+
}
|
|
606
626
|
}
|
|
607
627
|
applyClientStorageDelta(client_storage, update.delta);
|
|
608
628
|
event_processing = !update.final;
|
|
@@ -612,7 +632,8 @@ export const connect = async (
|
|
|
612
632
|
});
|
|
613
633
|
socket.current.on("reload", async (event) => {
|
|
614
634
|
event_processing = false;
|
|
615
|
-
|
|
635
|
+
on_hydrated_queue.push(event);
|
|
636
|
+
queueEvents(initialEvents(), socket, true, navigate, params);
|
|
616
637
|
});
|
|
617
638
|
socket.current.on("new_token", async (new_token) => {
|
|
618
639
|
token = new_token;
|
|
@@ -774,10 +795,32 @@ export const useEventLoop = (
|
|
|
774
795
|
}
|
|
775
796
|
}, [paramsR]);
|
|
776
797
|
|
|
798
|
+
const ensureSocketConnected = useCallback(async () => {
|
|
799
|
+
// only use websockets if state is present and backend is not disabled (reflex cloud).
|
|
800
|
+
if (
|
|
801
|
+
Object.keys(initialState).length > 1 &&
|
|
802
|
+
!isBackendDisabled() &&
|
|
803
|
+
!socket.current
|
|
804
|
+
) {
|
|
805
|
+
// Initialize the websocket connection.
|
|
806
|
+
await connect(
|
|
807
|
+
socket,
|
|
808
|
+
dispatch,
|
|
809
|
+
["websocket"],
|
|
810
|
+
setConnectErrors,
|
|
811
|
+
client_storage,
|
|
812
|
+
navigate,
|
|
813
|
+
() => params.current,
|
|
814
|
+
);
|
|
815
|
+
}
|
|
816
|
+
}, [socket, dispatch, setConnectErrors, client_storage, navigate, params]);
|
|
817
|
+
|
|
777
818
|
// Function to add new events to the event queue.
|
|
778
819
|
const addEvents = useCallback((events, args, event_actions) => {
|
|
779
820
|
const _events = events.filter((e) => e !== undefined && e !== null);
|
|
780
821
|
|
|
822
|
+
ensureSocketConnected();
|
|
823
|
+
|
|
781
824
|
if (!(args instanceof Array)) {
|
|
782
825
|
args = [args];
|
|
783
826
|
}
|
|
@@ -870,21 +913,8 @@ export const useEventLoop = (
|
|
|
870
913
|
|
|
871
914
|
// Handle socket connect/disconnect.
|
|
872
915
|
useEffect(() => {
|
|
873
|
-
//
|
|
874
|
-
|
|
875
|
-
// Initialize the websocket connection.
|
|
876
|
-
if (!socket.current) {
|
|
877
|
-
connect(
|
|
878
|
-
socket,
|
|
879
|
-
dispatch,
|
|
880
|
-
["websocket"],
|
|
881
|
-
setConnectErrors,
|
|
882
|
-
client_storage,
|
|
883
|
-
navigate,
|
|
884
|
-
() => params.current,
|
|
885
|
-
);
|
|
886
|
-
}
|
|
887
|
-
}
|
|
916
|
+
// Initialize the websocket connection.
|
|
917
|
+
ensureSocketConnected();
|
|
888
918
|
|
|
889
919
|
// Cleanup function.
|
|
890
920
|
return () => {
|
|
@@ -903,6 +933,7 @@ export const useEventLoop = (
|
|
|
903
933
|
(async () => {
|
|
904
934
|
// Process all outstanding events.
|
|
905
935
|
while (event_queue.length > 0 && !event_processing) {
|
|
936
|
+
await ensureSocketConnected();
|
|
906
937
|
await processEvent(socket.current, navigate, () => params.current);
|
|
907
938
|
}
|
|
908
939
|
})();
|
|
@@ -97,6 +97,7 @@ from reflex.state import (
|
|
|
97
97
|
State,
|
|
98
98
|
StateManager,
|
|
99
99
|
StateUpdate,
|
|
100
|
+
_split_substate_key,
|
|
100
101
|
_substate_key,
|
|
101
102
|
all_base_state_classes,
|
|
102
103
|
code_uses_state_contexts,
|
|
@@ -1559,7 +1560,7 @@ class App(MiddlewareMixin, LifespanMixin):
|
|
|
1559
1560
|
state._clean()
|
|
1560
1561
|
await self.event_namespace.emit_update(
|
|
1561
1562
|
update=StateUpdate(delta=delta),
|
|
1562
|
-
|
|
1563
|
+
token=token,
|
|
1563
1564
|
)
|
|
1564
1565
|
|
|
1565
1566
|
def _process_background(
|
|
@@ -1599,7 +1600,7 @@ class App(MiddlewareMixin, LifespanMixin):
|
|
|
1599
1600
|
# Send the update to the client.
|
|
1600
1601
|
await self.event_namespace.emit_update(
|
|
1601
1602
|
update=update,
|
|
1602
|
-
|
|
1603
|
+
token=event.token,
|
|
1603
1604
|
)
|
|
1604
1605
|
|
|
1605
1606
|
task = asyncio.create_task(
|
|
@@ -2061,20 +2062,19 @@ class EventNamespace(AsyncNamespace):
|
|
|
2061
2062
|
and console.error(f"Token cleanup error: {t.exception()}")
|
|
2062
2063
|
)
|
|
2063
2064
|
|
|
2064
|
-
async def emit_update(self, update: StateUpdate,
|
|
2065
|
+
async def emit_update(self, update: StateUpdate, token: str) -> None:
|
|
2065
2066
|
"""Emit an update to the client.
|
|
2066
2067
|
|
|
2067
2068
|
Args:
|
|
2068
2069
|
update: The state update to send.
|
|
2069
|
-
|
|
2070
|
+
token: The client token (tab) associated with the event.
|
|
2070
2071
|
"""
|
|
2071
|
-
|
|
2072
|
+
client_token, _ = _split_substate_key(token)
|
|
2073
|
+
sid = self.token_to_sid.get(client_token)
|
|
2074
|
+
if sid is None:
|
|
2072
2075
|
# If the sid is None, we are not connected to a client. Prevent sending
|
|
2073
2076
|
# updates to all clients.
|
|
2074
|
-
|
|
2075
|
-
token = self.sid_to_token.get(sid)
|
|
2076
|
-
if token is None:
|
|
2077
|
-
console.warn(f"Attempting to send delta to disconnected websocket {sid}")
|
|
2077
|
+
console.warn(f"Attempting to send delta to disconnected client {token!r}")
|
|
2078
2078
|
return
|
|
2079
2079
|
# Creating a task prevents the update from being blocked behind other coroutines.
|
|
2080
2080
|
await asyncio.create_task(
|
|
@@ -2165,7 +2165,7 @@ class EventNamespace(AsyncNamespace):
|
|
|
2165
2165
|
# Process the events.
|
|
2166
2166
|
async for update in updates_gen:
|
|
2167
2167
|
# Emit the update from processing the event.
|
|
2168
|
-
await self.emit_update(update=update,
|
|
2168
|
+
await self.emit_update(update=update, token=event.token)
|
|
2169
2169
|
|
|
2170
2170
|
async def on_ping(self, sid: str):
|
|
2171
2171
|
"""Event for testing the API endpoint.
|
|
@@ -60,6 +60,17 @@ class LifespanMixin(AppMixin):
|
|
|
60
60
|
for task in running_tasks:
|
|
61
61
|
console.debug(f"Canceling lifespan task: {task}")
|
|
62
62
|
task.cancel(msg="lifespan_cleanup")
|
|
63
|
+
# Disassociate sid / token pairings so they can be reconnected properly.
|
|
64
|
+
try:
|
|
65
|
+
event_namespace = self.event_namespace # pyright: ignore[reportAttributeAccessIssue]
|
|
66
|
+
except AttributeError:
|
|
67
|
+
pass
|
|
68
|
+
else:
|
|
69
|
+
try:
|
|
70
|
+
if event_namespace:
|
|
71
|
+
await event_namespace._token_manager.disconnect_all()
|
|
72
|
+
except Exception as e:
|
|
73
|
+
console.error(f"Error during lifespan cleanup: {e}")
|
|
63
74
|
|
|
64
75
|
def register_lifespan_task(self, task: Callable | asyncio.Task, **task_kwargs):
|
|
65
76
|
"""Register a task to run during the lifespan of the app.
|
|
@@ -621,7 +621,10 @@ def purge_web_pages_dir():
|
|
|
621
621
|
return
|
|
622
622
|
|
|
623
623
|
# Empty out the web pages directory.
|
|
624
|
-
utils.empty_dir(
|
|
624
|
+
utils.empty_dir(
|
|
625
|
+
get_web_dir() / constants.Dirs.PAGES,
|
|
626
|
+
keep_files=["routes.js", "entry.client.js"],
|
|
627
|
+
)
|
|
625
628
|
|
|
626
629
|
|
|
627
630
|
if TYPE_CHECKING:
|
|
@@ -17,6 +17,7 @@ from reflex.components.component import (
|
|
|
17
17
|
from reflex.components.core.cond import cond
|
|
18
18
|
from reflex.components.el.elements.forms import Input
|
|
19
19
|
from reflex.components.radix.themes.layout.box import Box
|
|
20
|
+
from reflex.components.sonner.toast import toast
|
|
20
21
|
from reflex.constants import Dirs
|
|
21
22
|
from reflex.constants.compiler import Hooks, Imports
|
|
22
23
|
from reflex.environment import environment
|
|
@@ -36,7 +37,8 @@ from reflex.utils.imports import ImportVar
|
|
|
36
37
|
from reflex.vars import VarData
|
|
37
38
|
from reflex.vars.base import Var, get_unique_variable_name
|
|
38
39
|
from reflex.vars.function import FunctionVar
|
|
39
|
-
from reflex.vars.
|
|
40
|
+
from reflex.vars.object import ObjectVar
|
|
41
|
+
from reflex.vars.sequence import ArrayVar, LiteralStringVar
|
|
40
42
|
|
|
41
43
|
DEFAULT_UPLOAD_ID: str = "default"
|
|
42
44
|
|
|
@@ -178,6 +180,34 @@ def _on_drop_spec(files: Var) -> tuple[Var[Any]]:
|
|
|
178
180
|
return (files,)
|
|
179
181
|
|
|
180
182
|
|
|
183
|
+
def _default_drop_rejected(rejected_files: ArrayVar[list[dict[str, Any]]]) -> EventSpec:
|
|
184
|
+
"""Event handler for showing a toast with rejected file info.
|
|
185
|
+
|
|
186
|
+
Args:
|
|
187
|
+
rejected_files: The files that were rejected.
|
|
188
|
+
|
|
189
|
+
Returns:
|
|
190
|
+
An event spec that shows a toast with the rejected file info when triggered.
|
|
191
|
+
"""
|
|
192
|
+
|
|
193
|
+
def _format_rejected_file_record(rf: ObjectVar[dict[str, Any]]) -> str:
|
|
194
|
+
rf = rf.to(ObjectVar, dict[str, dict[str, Any]])
|
|
195
|
+
file = rf["file"].to(ObjectVar, dict[str, Any])
|
|
196
|
+
errors = rf["errors"].to(ArrayVar, list[dict[str, Any]])
|
|
197
|
+
return (
|
|
198
|
+
f"{file['path']}: {errors.foreach(lambda err: err['message']).join(', ')}"
|
|
199
|
+
)
|
|
200
|
+
|
|
201
|
+
return toast.error(
|
|
202
|
+
title="Files not Accepted",
|
|
203
|
+
description=rejected_files.to(ArrayVar)
|
|
204
|
+
.foreach(_format_rejected_file_record)
|
|
205
|
+
.join("\n\n"),
|
|
206
|
+
close_button=True,
|
|
207
|
+
style={"white_space": "pre-line"},
|
|
208
|
+
)
|
|
209
|
+
|
|
210
|
+
|
|
181
211
|
class UploadFilesProvider(Component):
|
|
182
212
|
"""AppWrap component that provides a dict of selected files by ID via useContext."""
|
|
183
213
|
|
|
@@ -191,6 +221,9 @@ class GhostUpload(Fragment):
|
|
|
191
221
|
# Fired when files are dropped.
|
|
192
222
|
on_drop: EventHandler[_on_drop_spec]
|
|
193
223
|
|
|
224
|
+
# Fired when dropped files do not meet the specified criteria.
|
|
225
|
+
on_drop_rejected: EventHandler[_on_drop_spec]
|
|
226
|
+
|
|
194
227
|
|
|
195
228
|
class Upload(MemoizationLeaf):
|
|
196
229
|
"""A file upload component."""
|
|
@@ -234,6 +267,9 @@ class Upload(MemoizationLeaf):
|
|
|
234
267
|
# Fired when files are dropped.
|
|
235
268
|
on_drop: EventHandler[_on_drop_spec]
|
|
236
269
|
|
|
270
|
+
# Fired when dropped files do not meet the specified criteria.
|
|
271
|
+
on_drop_rejected: EventHandler[_on_drop_spec]
|
|
272
|
+
|
|
237
273
|
# Style rules to apply when actively dragging.
|
|
238
274
|
drag_active_style: Style | None = field(default=None, is_javascript_property=False)
|
|
239
275
|
|
|
@@ -295,6 +331,10 @@ class Upload(MemoizationLeaf):
|
|
|
295
331
|
on_drop[ix] = event
|
|
296
332
|
upload_props["on_drop"] = on_drop
|
|
297
333
|
|
|
334
|
+
if upload_props.get("on_drop_rejected") is None:
|
|
335
|
+
# If on_drop_rejected is not provided, show an error toast.
|
|
336
|
+
upload_props["on_drop_rejected"] = _default_drop_rejected
|
|
337
|
+
|
|
298
338
|
input_props_unique_name = get_unique_variable_name()
|
|
299
339
|
root_props_unique_name = get_unique_variable_name()
|
|
300
340
|
is_drag_active_unique_name = get_unique_variable_name()
|
|
@@ -313,22 +353,22 @@ class Upload(MemoizationLeaf):
|
|
|
313
353
|
),
|
|
314
354
|
)
|
|
315
355
|
|
|
316
|
-
|
|
317
|
-
GhostUpload.create(
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
356
|
+
event_triggers = StatefulComponent._get_memoized_event_triggers(
|
|
357
|
+
GhostUpload.create(
|
|
358
|
+
on_drop=upload_props["on_drop"],
|
|
359
|
+
on_drop_rejected=upload_props["on_drop_rejected"],
|
|
360
|
+
)
|
|
361
|
+
)
|
|
362
|
+
callback_hooks = []
|
|
363
|
+
for trigger_name, (event_var, callback_str) in event_triggers.items():
|
|
364
|
+
upload_props[trigger_name] = event_var
|
|
365
|
+
callback_hooks.append(callback_str)
|
|
321
366
|
|
|
322
367
|
upload_props = {
|
|
323
368
|
format.to_camel_case(key): value for key, value in upload_props.items()
|
|
324
369
|
}
|
|
325
370
|
|
|
326
|
-
use_dropzone_arguments = Var.create(
|
|
327
|
-
{
|
|
328
|
-
"onDrop": event_var,
|
|
329
|
-
**upload_props,
|
|
330
|
-
}
|
|
331
|
-
)
|
|
371
|
+
use_dropzone_arguments = Var.create(upload_props)
|
|
332
372
|
|
|
333
373
|
left_side = (
|
|
334
374
|
"const { "
|
|
@@ -344,11 +384,10 @@ class Upload(MemoizationLeaf):
|
|
|
344
384
|
imports=Imports.EVENTS,
|
|
345
385
|
hooks={Hooks.EVENTS: None},
|
|
346
386
|
),
|
|
347
|
-
event_var._get_all_var_data(),
|
|
348
387
|
use_dropzone_arguments._get_all_var_data(),
|
|
349
388
|
VarData(
|
|
350
389
|
hooks={
|
|
351
|
-
|
|
390
|
+
**dict.fromkeys(callback_hooks, None),
|
|
352
391
|
f"{left_side} = {right_side};": None,
|
|
353
392
|
},
|
|
354
393
|
imports={
|
|
@@ -71,10 +71,15 @@ class StateProxy(wrapt.ObjectProxy):
|
|
|
71
71
|
state_instance: The state instance to proxy.
|
|
72
72
|
parent_state_proxy: The parent state proxy, for linked mutability and context tracking.
|
|
73
73
|
"""
|
|
74
|
+
from reflex.state import _substate_key
|
|
75
|
+
|
|
74
76
|
super().__init__(state_instance)
|
|
75
|
-
# compile is not relevant to backend logic
|
|
76
77
|
self._self_app = prerequisites.get_and_validate_app().app
|
|
77
78
|
self._self_substate_path = tuple(state_instance.get_full_name().split("."))
|
|
79
|
+
self._self_substate_token = _substate_key(
|
|
80
|
+
state_instance.router.session.client_token,
|
|
81
|
+
self._self_substate_path,
|
|
82
|
+
)
|
|
78
83
|
self._self_actx = None
|
|
79
84
|
self._self_mutable = False
|
|
80
85
|
self._self_actx_lock = asyncio.Lock()
|
|
@@ -127,16 +132,9 @@ class StateProxy(wrapt.ObjectProxy):
|
|
|
127
132
|
msg = "The state is already mutable. Do not nest `async with self` blocks."
|
|
128
133
|
raise ImmutableStateError(msg)
|
|
129
134
|
|
|
130
|
-
from reflex.state import _substate_key
|
|
131
|
-
|
|
132
135
|
await self._self_actx_lock.acquire()
|
|
133
136
|
self._self_actx_lock_holder = current_task
|
|
134
|
-
self._self_actx = self._self_app.modify_state(
|
|
135
|
-
token=_substate_key(
|
|
136
|
-
self.__wrapped__.router.session.client_token,
|
|
137
|
-
self._self_substate_path,
|
|
138
|
-
)
|
|
139
|
-
)
|
|
137
|
+
self._self_actx = self._self_app.modify_state(token=self._self_substate_token)
|
|
140
138
|
mutable_state = await self._self_actx.__aenter__()
|
|
141
139
|
super().__setattr__(
|
|
142
140
|
"__wrapped__", mutable_state.get_substate(self._self_substate_path)
|
|
@@ -378,17 +376,6 @@ class MutableProxy(wrapt.ObjectProxy):
|
|
|
378
376
|
pydantic.BaseModel.__dict__
|
|
379
377
|
)
|
|
380
378
|
|
|
381
|
-
# These types will be wrapped in MutableProxy
|
|
382
|
-
__mutable_types__ = (
|
|
383
|
-
list,
|
|
384
|
-
dict,
|
|
385
|
-
set,
|
|
386
|
-
Base,
|
|
387
|
-
DeclarativeBase,
|
|
388
|
-
BaseModelV2,
|
|
389
|
-
BaseModelV1,
|
|
390
|
-
)
|
|
391
|
-
|
|
392
379
|
# Dynamically generated classes for tracking dataclass mutations.
|
|
393
380
|
__dataclass_proxies__: dict[type, type] = {}
|
|
394
381
|
|
|
@@ -469,20 +456,6 @@ class MutableProxy(wrapt.ObjectProxy):
|
|
|
469
456
|
return wrapped(*args, **(kwargs or {}))
|
|
470
457
|
return None
|
|
471
458
|
|
|
472
|
-
@classmethod
|
|
473
|
-
def _is_mutable_type(cls, value: Any) -> bool:
|
|
474
|
-
"""Check if a value is of a mutable type and should be wrapped.
|
|
475
|
-
|
|
476
|
-
Args:
|
|
477
|
-
value: The value to check.
|
|
478
|
-
|
|
479
|
-
Returns:
|
|
480
|
-
Whether the value is of a mutable type.
|
|
481
|
-
"""
|
|
482
|
-
return isinstance(value, cls.__mutable_types__) or (
|
|
483
|
-
dataclasses.is_dataclass(value) and not isinstance(value, Var)
|
|
484
|
-
)
|
|
485
|
-
|
|
486
459
|
@staticmethod
|
|
487
460
|
def _is_called_from_dataclasses_internal() -> bool:
|
|
488
461
|
"""Check if the current function is called from dataclasses helper.
|
|
@@ -514,7 +487,7 @@ class MutableProxy(wrapt.ObjectProxy):
|
|
|
514
487
|
if self._is_called_from_dataclasses_internal():
|
|
515
488
|
return value
|
|
516
489
|
# Recursively wrap mutable types, but do not re-wrap MutableProxy instances.
|
|
517
|
-
if
|
|
490
|
+
if is_mutable_type(type(value)) and not isinstance(value, MutableProxy):
|
|
518
491
|
base_cls = globals()[self.__base_proxy__]
|
|
519
492
|
return base_cls(
|
|
520
493
|
wrapped=value,
|
|
@@ -575,7 +548,7 @@ class MutableProxy(wrapt.ObjectProxy):
|
|
|
575
548
|
self._wrap_recursive_decorator,
|
|
576
549
|
)
|
|
577
550
|
|
|
578
|
-
if
|
|
551
|
+
if is_mutable_type(type(value)) and __name not in (
|
|
579
552
|
"__wrapped__",
|
|
580
553
|
"_self_state",
|
|
581
554
|
"__dict__",
|
|
@@ -764,3 +737,30 @@ class ImmutableMutableProxy(MutableProxy):
|
|
|
764
737
|
return super()._mark_dirty(
|
|
765
738
|
wrapped=wrapped, instance=instance, args=args, kwargs=kwargs
|
|
766
739
|
)
|
|
740
|
+
|
|
741
|
+
|
|
742
|
+
# These types will be wrapped in MutableProxy
|
|
743
|
+
MUTABLE_TYPES = (
|
|
744
|
+
list,
|
|
745
|
+
dict,
|
|
746
|
+
set,
|
|
747
|
+
Base,
|
|
748
|
+
DeclarativeBase,
|
|
749
|
+
BaseModelV2,
|
|
750
|
+
BaseModelV1,
|
|
751
|
+
)
|
|
752
|
+
|
|
753
|
+
|
|
754
|
+
@functools.lru_cache(maxsize=1024)
|
|
755
|
+
def is_mutable_type(type_: type) -> bool:
|
|
756
|
+
"""Check if a type is mutable and should be wrapped.
|
|
757
|
+
|
|
758
|
+
Args:
|
|
759
|
+
type_: The type to check.
|
|
760
|
+
|
|
761
|
+
Returns:
|
|
762
|
+
Whether the type is mutable and should be wrapped.
|
|
763
|
+
"""
|
|
764
|
+
return issubclass(type_, MUTABLE_TYPES) or (
|
|
765
|
+
dataclasses.is_dataclass(type_) and not issubclass(type_, Var)
|
|
766
|
+
)
|
|
@@ -422,6 +422,13 @@ def compile(dry: bool, rich: bool):
|
|
|
422
422
|
default=constants.Env.PROD.value,
|
|
423
423
|
help="The environment to export the app in.",
|
|
424
424
|
)
|
|
425
|
+
@click.option(
|
|
426
|
+
"--exclude-from-backend",
|
|
427
|
+
"backend_excluded_dirs",
|
|
428
|
+
multiple=True,
|
|
429
|
+
type=click.Path(exists=True, path_type=Path, resolve_path=True),
|
|
430
|
+
help="Files or directories to exclude from the backend zip. Can be used multiple times.",
|
|
431
|
+
)
|
|
425
432
|
def export(
|
|
426
433
|
zip: bool,
|
|
427
434
|
frontend_only: bool,
|
|
@@ -429,6 +436,7 @@ def export(
|
|
|
429
436
|
zip_dest_dir: str,
|
|
430
437
|
upload_db_file: bool,
|
|
431
438
|
env: LITERAL_ENV,
|
|
439
|
+
backend_excluded_dirs: tuple[Path, ...] = (),
|
|
432
440
|
):
|
|
433
441
|
"""Export the app to a zip file."""
|
|
434
442
|
from reflex.utils import export as export_utils
|
|
@@ -455,6 +463,7 @@ def export(
|
|
|
455
463
|
upload_db_file=upload_db_file,
|
|
456
464
|
env=constants.Env.DEV if env == constants.Env.DEV else constants.Env.PROD,
|
|
457
465
|
loglevel=config.loglevel.subprocess_level(),
|
|
466
|
+
backend_excluded_dirs=backend_excluded_dirs,
|
|
458
467
|
)
|
|
459
468
|
|
|
460
469
|
|
|
@@ -660,6 +669,13 @@ def makemigrations(message: str | None):
|
|
|
660
669
|
"--config",
|
|
661
670
|
help="path to the config file",
|
|
662
671
|
)
|
|
672
|
+
@click.option(
|
|
673
|
+
"--exclude-from-backend",
|
|
674
|
+
"backend_excluded_dirs",
|
|
675
|
+
multiple=True,
|
|
676
|
+
type=click.Path(exists=True, path_type=Path, resolve_path=True),
|
|
677
|
+
help="Files or directories to exclude from the backend zip. Can be used multiple times.",
|
|
678
|
+
)
|
|
663
679
|
def deploy(
|
|
664
680
|
app_name: str | None,
|
|
665
681
|
app_id: str | None,
|
|
@@ -673,6 +689,7 @@ def deploy(
|
|
|
673
689
|
project_name: str | None,
|
|
674
690
|
token: str | None,
|
|
675
691
|
config_path: str | None,
|
|
692
|
+
backend_excluded_dirs: tuple[Path, ...] = (),
|
|
676
693
|
):
|
|
677
694
|
"""Deploy the app to the Reflex hosting service."""
|
|
678
695
|
from reflex_cli.utils import dependency
|
|
@@ -721,6 +738,7 @@ def deploy(
|
|
|
721
738
|
zipping=zipping,
|
|
722
739
|
loglevel=config.loglevel.subprocess_level(),
|
|
723
740
|
upload_db_file=upload_db,
|
|
741
|
+
backend_excluded_dirs=backend_excluded_dirs,
|
|
724
742
|
)
|
|
725
743
|
),
|
|
726
744
|
regions=list(region),
|
|
@@ -41,7 +41,7 @@ from reflex.event import (
|
|
|
41
41
|
from reflex.istate import HANDLED_PICKLE_ERRORS, debug_failed_pickles
|
|
42
42
|
from reflex.istate.data import RouterData
|
|
43
43
|
from reflex.istate.proxy import ImmutableMutableProxy as ImmutableMutableProxy
|
|
44
|
-
from reflex.istate.proxy import MutableProxy, StateProxy
|
|
44
|
+
from reflex.istate.proxy import MutableProxy, StateProxy, is_mutable_type
|
|
45
45
|
from reflex.istate.storage import ClientStorageBase
|
|
46
46
|
from reflex.model import Model
|
|
47
47
|
from reflex.utils import console, format, prerequisites, types
|
|
@@ -1359,7 +1359,7 @@ class BaseState(EvenMoreBasicBaseState):
|
|
|
1359
1359
|
if parent_state is not None:
|
|
1360
1360
|
return getattr(parent_state, name)
|
|
1361
1361
|
|
|
1362
|
-
if
|
|
1362
|
+
if is_mutable_type(type(value)) and (
|
|
1363
1363
|
name in super().__getattribute__("base_vars") or name in backend_vars
|
|
1364
1364
|
):
|
|
1365
1365
|
# track changes in mutable containers (list, dict, set, etc)
|
|
@@ -47,6 +47,7 @@ from reflex.state import (
|
|
|
47
47
|
)
|
|
48
48
|
from reflex.utils import console, js_runtimes
|
|
49
49
|
from reflex.utils.export import export
|
|
50
|
+
from reflex.utils.token_manager import TokenManager
|
|
50
51
|
from reflex.utils.types import ASGIApp
|
|
51
52
|
|
|
52
53
|
try:
|
|
@@ -774,6 +775,19 @@ class AppHarness:
|
|
|
774
775
|
self.app_instance._state_manager = app_state_manager
|
|
775
776
|
await self.state_manager.close()
|
|
776
777
|
|
|
778
|
+
def token_manager(self) -> TokenManager:
|
|
779
|
+
"""Get the token manager for the app instance.
|
|
780
|
+
|
|
781
|
+
Returns:
|
|
782
|
+
The current token_manager attached to the app's EventNamespace.
|
|
783
|
+
"""
|
|
784
|
+
assert self.app_instance is not None
|
|
785
|
+
app_event_namespace = self.app_instance.event_namespace
|
|
786
|
+
assert app_event_namespace is not None
|
|
787
|
+
app_token_manager = app_event_namespace._token_manager
|
|
788
|
+
assert app_token_manager is not None
|
|
789
|
+
return app_token_manager
|
|
790
|
+
|
|
777
791
|
def poll_for_content(
|
|
778
792
|
self,
|
|
779
793
|
element: WebElement,
|