streamlit-nightly 1.52.3.dev20260112__py3-none-any.whl → 1.53.1.dev20260114__py3-none-any.whl

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.
Files changed (225) hide show
  1. streamlit/__init__.py +1 -1
  2. streamlit/auth_util.py +1 -1
  3. streamlit/cli_util.py +1 -1
  4. streamlit/commands/logo.py +2 -0
  5. streamlit/commands/page_config.py +16 -16
  6. streamlit/components/v2/__init__.py +2 -2
  7. streamlit/components/v2/bidi_component/main.py +2 -2
  8. streamlit/connections/base_connection.py +16 -4
  9. streamlit/connections/snowflake_connection.py +255 -206
  10. streamlit/dataframe_util.py +1 -3
  11. streamlit/elements/arrow.py +5 -1
  12. streamlit/elements/form.py +2 -2
  13. streamlit/elements/lib/color_util.py +1 -1
  14. streamlit/elements/lib/image_utils.py +1 -1
  15. streamlit/elements/metric.py +49 -48
  16. streamlit/elements/vega_charts.py +4 -1
  17. streamlit/elements/widgets/button.py +9 -9
  18. streamlit/elements/widgets/chat.py +5 -9
  19. streamlit/elements/widgets/data_editor.py +3 -3
  20. streamlit/elements/widgets/file_uploader.py +10 -11
  21. streamlit/elements/widgets/multiselect.py +1 -1
  22. streamlit/elements/widgets/select_slider.py +4 -0
  23. streamlit/elements/widgets/time_widgets.py +1 -1
  24. streamlit/elements/write.py +1 -2
  25. streamlit/errors.py +2 -0
  26. streamlit/external/langchain/streamlit_callback_handler.py +1 -1
  27. streamlit/proto/Alert_pb2.pyi +31 -31
  28. streamlit/proto/AppPage_pb2.pyi +30 -30
  29. streamlit/proto/ArrowData_pb2.pyi +15 -15
  30. streamlit/proto/ArrowNamedDataSet_pb2.pyi +25 -25
  31. streamlit/proto/ArrowVegaLiteChart_pb2.pyi +45 -45
  32. streamlit/proto/Arrow_pb2.pyi +126 -97
  33. streamlit/proto/AudioInput_pb2.pyi +39 -39
  34. streamlit/proto/Audio_pb2.pyi +39 -39
  35. streamlit/proto/AuthRedirect_pb2.pyi +15 -15
  36. streamlit/proto/AutoRerun_pb2.pyi +18 -18
  37. streamlit/proto/BackMsg_pb2.pyi +64 -64
  38. streamlit/proto/Balloons_pb2.pyi +15 -15
  39. streamlit/proto/BidiComponent_pb2.pyi +100 -100
  40. streamlit/proto/Block_pb2.pyi +295 -264
  41. streamlit/proto/BokehChart_pb2.pyi +21 -21
  42. streamlit/proto/ButtonGroup_pb2.pyi +96 -96
  43. streamlit/proto/ButtonLikeIconPosition_pb2.pyi +12 -12
  44. streamlit/proto/Button_pb2.pyi +63 -50
  45. streamlit/proto/CameraInput_pb2.pyi +34 -34
  46. streamlit/proto/ChatInput_pb2.pyi +63 -63
  47. streamlit/proto/Checkbox_pb2.pyi +49 -49
  48. streamlit/proto/ClientState_pb2.pyi +85 -85
  49. streamlit/proto/Code_pb2.pyi +41 -28
  50. streamlit/proto/ColorPicker_pb2.pyi +43 -43
  51. streamlit/proto/Common_pb2.pyi +175 -175
  52. streamlit/proto/Components_pb2.pyi +110 -110
  53. streamlit/proto/DataFrame_pb2.pyi +209 -209
  54. streamlit/proto/DateInput_pb2.pyi +59 -59
  55. streamlit/proto/DateTimeInput_pb2.pyi +62 -62
  56. streamlit/proto/DeckGlJsonChart_pb2.pyi +91 -56
  57. streamlit/proto/Delta_pb2.pyi +44 -44
  58. streamlit/proto/DocString_pb2.pyi +51 -51
  59. streamlit/proto/DownloadButton_pb2.pyi +59 -59
  60. streamlit/proto/Element_pb2.pyi +319 -319
  61. streamlit/proto/Empty_pb2.pyi +10 -10
  62. streamlit/proto/Exception_pb2.pyi +37 -37
  63. streamlit/proto/Favicon_pb2.pyi +15 -15
  64. streamlit/proto/FileUploader_pb2.pyi +49 -49
  65. streamlit/proto/ForwardMsg_pb2.pyi +176 -170
  66. streamlit/proto/GapSize_pb2.pyi +23 -23
  67. streamlit/proto/GitInfo_pb2.pyi +37 -37
  68. streamlit/proto/GraphVizChart_pb2.pyi +38 -25
  69. streamlit/proto/Heading_pb2.pyi +30 -30
  70. streamlit/proto/HeightConfig_pb2.pyi +31 -31
  71. streamlit/proto/Html_pb2.pyi +18 -18
  72. streamlit/proto/IFrame_pb2.pyi +76 -47
  73. streamlit/proto/Image_pb2.pyi +49 -36
  74. streamlit/proto/Json_pb2.pyi +25 -25
  75. streamlit/proto/LabelVisibilityMessage_pb2.pyi +18 -18
  76. streamlit/proto/LinkButton_pb2.pyi +43 -43
  77. streamlit/proto/Logo_pb2.pyi +24 -24
  78. streamlit/proto/Markdown_pb2.pyi +30 -30
  79. streamlit/proto/Metric_pb2.pyi +59 -59
  80. streamlit/proto/MetricsEvent_pb2.pyi +171 -171
  81. streamlit/proto/MultiSelect_pb2.pyi +72 -66
  82. streamlit/proto/NamedDataSet_pb2.pyi +25 -25
  83. streamlit/proto/Navigation_pb2.pyi +35 -35
  84. streamlit/proto/NewSession_pb2.pyi +511 -498
  85. streamlit/proto/NumberInput_pb2.pyi +79 -79
  86. streamlit/proto/PageConfig_pb2.pyi +71 -71
  87. streamlit/proto/PageInfo_pb2.pyi +15 -15
  88. streamlit/proto/PageLink_pb2.pyi +47 -47
  89. streamlit/proto/PageNotFound_pb2.pyi +15 -15
  90. streamlit/proto/PageProfile_pb2.pyi +85 -85
  91. streamlit/proto/PagesChanged_pb2.pyi +19 -19
  92. streamlit/proto/ParentMessage_pb2.pyi +15 -15
  93. streamlit/proto/PlotlyChart_pb2.pyi +79 -64
  94. streamlit/proto/Progress_pb2.pyi +18 -18
  95. streamlit/proto/Radio_pb2.pyi +62 -62
  96. streamlit/proto/RootContainer_pb2.pyi +12 -12
  97. streamlit/proto/Selectbox_pb2.pyi +80 -70
  98. streamlit/proto/SessionEvent_pb2.pyi +27 -27
  99. streamlit/proto/SessionStatus_pb2.pyi +18 -18
  100. streamlit/proto/Skeleton_pb2.pyi +25 -25
  101. streamlit/proto/Slider_pb2.pyi +74 -74
  102. streamlit/proto/Snow_pb2.pyi +15 -15
  103. streamlit/proto/Space_pb2.pyi +10 -10
  104. streamlit/proto/Spinner_pb2.pyi +21 -21
  105. streamlit/proto/TextAlignmentConfig_pb2.pyi +18 -18
  106. streamlit/proto/TextArea_pb2.pyi +72 -59
  107. streamlit/proto/TextInput_pb2.pyi +67 -67
  108. streamlit/proto/Text_pb2.pyi +18 -18
  109. streamlit/proto/TimeInput_pb2.pyi +52 -52
  110. streamlit/proto/Toast_pb2.pyi +25 -25
  111. streamlit/proto/Transient_pb2.pyi +19 -19
  112. streamlit/proto/VegaLiteChart_pb2.pyi +32 -32
  113. streamlit/proto/Video_pb2.pyi +65 -65
  114. streamlit/proto/WidgetStates_pb2.pyi +91 -85
  115. streamlit/proto/WidthConfig_pb2.pyi +31 -31
  116. streamlit/proto/openmetrics_data_model_pb2.pyi +269 -269
  117. streamlit/runtime/app_session.py +1 -1
  118. streamlit/runtime/caching/cache_data_api.py +25 -21
  119. streamlit/runtime/caching/cache_resource_api.py +69 -41
  120. streamlit/runtime/connection_factory.py +67 -41
  121. streamlit/runtime/credentials.py +2 -2
  122. streamlit/runtime/metrics_util.py +3 -3
  123. streamlit/runtime/secrets.py +1 -1
  124. streamlit/runtime/stats.py +1 -3
  125. streamlit/static/index.html +1 -1
  126. streamlit/static/manifest.json +304 -304
  127. streamlit/static/static/js/{ErrorOutline.esm.BjVqd_6R.js → ErrorOutline.esm.BAZUU4id.js} +1 -1
  128. streamlit/static/static/js/{FileDownload.esm.DJCSsghl.js → FileDownload.esm.C6tTTniR.js} +1 -1
  129. streamlit/static/static/js/{FileHelper.C---TH7o.js → FileHelper.BOHlwlc9.js} +1 -1
  130. streamlit/static/static/js/{FormClearHelper.C-6BC487.js → FormClearHelper.D4lty7rT.js} +1 -1
  131. streamlit/static/static/js/{InputInstructions.sxc3InCI.js → InputInstructions.BWw9lhud.js} +1 -1
  132. streamlit/static/static/js/{Particles.S8yD7iW-.js → Particles.BDi7fIn-.js} +1 -1
  133. streamlit/static/static/js/{ProgressBar.BiYsyZCC.js → ProgressBar.DCHh4N3P.js} +1 -1
  134. streamlit/static/static/js/{StreamlitSyntaxHighlighter.9jZF8jX1.js → StreamlitSyntaxHighlighter.BRydQwEj.js} +1 -1
  135. streamlit/static/static/js/{TableChart.esm.BdA4Q1rZ.js → TableChart.esm.7KFX5I_G.js} +1 -1
  136. streamlit/static/static/js/{Toolbar.B9DaaDfN.js → Toolbar.guIuiwEF.js} +1 -1
  137. streamlit/static/static/js/{WidgetLabelHelpIconInline.DxODTLS2.js → WidgetLabelHelpIconInline.CzodezAH.js} +1 -1
  138. streamlit/static/static/js/{base-input.Gf1cKuQR.js → base-input.Cg7NpsfS.js} +1 -1
  139. streamlit/static/static/js/{checkbox.CnoNruf3.js → checkbox.Bs20OTna.js} +1 -1
  140. streamlit/static/static/js/{createDownloadLinkElement.B48AepiL.js → createDownloadLinkElement.DSqCyu38.js} +1 -1
  141. streamlit/static/static/js/{data-grid-overlay-editor.Cmdq9aqU.js → data-grid-overlay-editor.Ch4SqNfY.js} +1 -1
  142. streamlit/static/static/js/{downloader.CQLoQdMX.js → downloader.Oj5CTGJA.js} +1 -1
  143. streamlit/static/static/js/{embed.oKwocwU8.js → embed.CqzzUq73.js} +1 -1
  144. streamlit/static/static/js/{es6.BRxlY_y5.js → es6.CYrlw0Vn.js} +2 -2
  145. streamlit/static/static/js/{formatNumber.DaagZyZe.js → formatNumber.CT_v8e75.js} +1 -1
  146. streamlit/static/static/js/{iconPosition.Q3hNvmK4.js → iconPosition.DPAvXTmd.js} +1 -1
  147. streamlit/static/static/js/{iframeResizer.contentWindow.B6EBvI9L.js → iframeResizer.contentWindow.T4DvQsIf.js} +1 -1
  148. streamlit/static/static/js/{index.BoX8d5rK.js → index.AGYZDQZm.js} +1 -1
  149. streamlit/static/static/js/{index.KtjGDGY5.js → index.B3HdcUdo.js} +1 -1
  150. streamlit/static/static/js/{index.B9kZB0o1.js → index.B8ZZdPqF.js} +1 -1
  151. streamlit/static/static/js/{index.CFCBhOfx.js → index.B9Oowxt8.js} +1 -1
  152. streamlit/static/static/js/{index.CCQ5p_WC.js → index.BEzgNZOm.js} +1 -1
  153. streamlit/static/static/js/{index.D1pK_Vw2.js → index.BJnWg9Jq.js} +1 -1
  154. streamlit/static/static/js/{index.na9UBuse.js → index.BPxuKK0S.js} +1 -1
  155. streamlit/static/static/js/{index.QTaWooav.js → index.BTA0d5oq.js} +1 -1
  156. streamlit/static/static/js/{index.pU9mQeVC.js → index.BTqav7_K.js} +1 -1
  157. streamlit/static/static/js/{index.BXEC4cf3.js → index.BZ8xp-w9.js} +1 -1
  158. streamlit/static/static/js/{index.BF23fbfs.js → index.BoWBzl6h.js} +1 -1
  159. streamlit/static/static/js/index.Bqgt60FU.js +1 -0
  160. streamlit/static/static/js/{index.Dh5SAThV.js → index.BsYYrijt.js} +1 -1
  161. streamlit/static/static/js/{index.19_qtO6t.js → index.CGRIbGGV.js} +1 -1
  162. streamlit/static/static/js/{index.CSfsEKCF.js → index.CJQq5LcR.js} +1 -1
  163. streamlit/static/static/js/{index.Fu73QtkD.js → index.CPYB1awG.js} +1 -1
  164. streamlit/static/static/js/{index.BzwlrgZO.js → index.CVKk1nkB.js} +1 -1
  165. streamlit/static/static/js/{index.B03eQZoH.js → index.CVXiBeDI.js} +1 -1
  166. streamlit/static/static/js/{index.BRfGUOQ-.js → index.CXVpBAvU.js} +4 -4
  167. streamlit/static/static/js/{index.slgxPafU.js → index.Cfe-tCQJ.js} +1 -1
  168. streamlit/static/static/js/{index.D6X2coHR.js → index.ClFk8x0U.js} +1 -1
  169. streamlit/static/static/js/{index.WXybx2Xq.js → index.CnXxoVEM.js} +1 -1
  170. streamlit/static/static/js/{index.j4fnjyHo.js → index.Cw4eSvJ7.js} +1 -1
  171. streamlit/static/static/js/{index.KN1VmyYN.js → index.D6HCANv6.js} +1 -1
  172. streamlit/static/static/js/{index.CP-hoxJM.js → index.D7KbBAWb.js} +1 -1
  173. streamlit/static/static/js/{index.CCFwVy90.js → index.D84XHt50.js} +1 -1
  174. streamlit/static/static/js/{index.BkSwGJoh.js → index.DL_Ooizi.js} +1 -1
  175. streamlit/static/static/js/{index.QHnxuesF.js → index.DNyw7S7Z.js} +1 -1
  176. streamlit/static/static/js/{index.BAI9aHCq.js → index.DPlPEuq6.js} +1 -1
  177. streamlit/static/static/js/{index.CJ4oJe0V.js → index.DQzRwgrT.js} +1 -1
  178. streamlit/static/static/js/{index.CVlg41MB.js → index.DXRGd--0.js} +1 -1
  179. streamlit/static/static/js/{index.CIbgt5wY.js → index.DZDt5hYD.js} +1 -1
  180. streamlit/static/static/js/{index.BVT89mQw.js → index.DesNeXSA.js} +1 -1
  181. streamlit/static/static/js/{index.Boa0Egng.js → index.Dg9k4R8B.js} +1 -1
  182. streamlit/static/static/js/{index.43b777iP.js → index.Do9A7QCt.js} +1 -1
  183. streamlit/static/static/js/{index.DJ7P09eb.js → index.DrSH3pK3.js} +1 -1
  184. streamlit/static/static/js/{index.OpATzEaW.js → index.Dtd5z2rM.js} +1 -1
  185. streamlit/static/static/js/{index.BnfTPrHb.js → index.DzldU3Hy.js} +1 -1
  186. streamlit/static/static/js/{index.C0fSEz-3.js → index.GZi6GTJa.js} +1 -1
  187. streamlit/static/static/js/{index.CYE7b5Du.js → index.LOA31DFn.js} +1 -1
  188. streamlit/static/static/js/{index.Ca7MUNWJ.js → index.MtwRNvlS.js} +1 -1
  189. streamlit/static/static/js/{index.BbSFVZ3p.js → index.XHtvnZ0-.js} +1 -1
  190. streamlit/static/static/js/{index.CvIqsWy1.js → index.Yj6vcyFD.js} +1 -1
  191. streamlit/static/static/js/{index.BGBTkulf.js → index.b-MrPulo.js} +1 -1
  192. streamlit/static/static/js/{index.DGYHxruh.js → index.hcUYvTqs.js} +1 -1
  193. streamlit/static/static/js/{index.CvB9JBqS.js → index.tLZuZM89.js} +6 -6
  194. streamlit/static/static/js/{index.Xg-Qttib.js → index.wngeYhKj.js} +1 -1
  195. streamlit/static/static/js/{index.whRT3Vm3.js → index.xCV2qwtw.js} +1 -1
  196. streamlit/static/static/js/{input.CPzINTl-.js → input.CYXuTqoa.js} +1 -1
  197. streamlit/static/static/js/{main.DSPn8dUe.js → main.BE-siVKv.js} +1 -1
  198. streamlit/static/static/js/{memory.CfD8IGoU.js → memory.V554ztRg.js} +1 -1
  199. streamlit/static/static/js/{number-overlay-editor.4Ae0qegV.js → number-overlay-editor.BiUTOXIl.js} +1 -1
  200. streamlit/static/static/js/{pandasStylerUtils.D2EjZ7k6.js → pandasStylerUtils.Dej3Tstq.js} +1 -1
  201. streamlit/static/static/js/{sandbox.C6vcPIm0.js → sandbox.gpd7KGMo.js} +1 -1
  202. streamlit/static/static/js/{styled-components.BBmp8buj.js → styled-components.Coj4dr6D.js} +1 -1
  203. streamlit/static/static/js/{throttle.BPcPpy-S.js → throttle.gZUdtYp7.js} +1 -1
  204. streamlit/static/static/js/{timepicker.ryzkTs2C.js → timepicker.B-Y4aU15.js} +1 -1
  205. streamlit/static/static/js/{toConsumableArray.Dg1nDaB_.js → toConsumableArray.CcKcKvEd.js} +1 -1
  206. streamlit/static/static/js/uniqueId.PRn3V1WU.js +1 -0
  207. streamlit/static/static/js/{useBasicWidgetState.A4U5lzAm.js → useBasicWidgetState.D-fc_aIL.js} +1 -1
  208. streamlit/static/static/js/{useIntlLocale.DWJgLlNz.js → useIntlLocale.CY32IeNt.js} +1 -1
  209. streamlit/static/static/js/{useTextInputAutoExpand.BrBonw8t.js → useTextInputAutoExpand.C0jK7TwF.js} +1 -1
  210. streamlit/static/static/js/{useUpdateUiValue.BkOWyNVX.js → useUpdateUiValue.CDQloDgB.js} +1 -1
  211. streamlit/static/static/js/{useWaveformController.CBlvXlgZ.js → useWaveformController.BLEIAIDo.js} +1 -1
  212. streamlit/static/static/js/{withCalculatedWidth.D4cpOyNe.js → withCalculatedWidth.B3oSlRC0.js} +1 -1
  213. streamlit/static/static/js/{withFullScreenWrapper.BMim3w94.js → withFullScreenWrapper.Cw_ebNmr.js} +1 -1
  214. streamlit/testing/v1/app_test.py +1 -1
  215. streamlit/user_info.py +225 -166
  216. streamlit/web/server/starlette/starlette_routes.py +1 -3
  217. streamlit/web/server/stats_request_handler.py +1 -3
  218. {streamlit_nightly-1.52.3.dev20260112.dist-info → streamlit_nightly-1.53.1.dev20260114.dist-info}/METADATA +1 -1
  219. {streamlit_nightly-1.52.3.dev20260112.dist-info → streamlit_nightly-1.53.1.dev20260114.dist-info}/RECORD +223 -223
  220. streamlit/static/static/js/index.CrPjcPY1.js +0 -1
  221. streamlit/static/static/js/uniqueId.BFHzT5KQ.js +0 -1
  222. {streamlit_nightly-1.52.3.dev20260112.data → streamlit_nightly-1.53.1.dev20260114.data}/scripts/streamlit.cmd +0 -0
  223. {streamlit_nightly-1.52.3.dev20260112.dist-info → streamlit_nightly-1.53.1.dev20260114.dist-info}/WHEEL +0 -0
  224. {streamlit_nightly-1.52.3.dev20260112.dist-info → streamlit_nightly-1.53.1.dev20260114.dist-info}/entry_points.txt +0 -0
  225. {streamlit_nightly-1.52.3.dev20260112.dist-info → streamlit_nightly-1.53.1.dev20260114.dist-info}/top_level.txt +0 -0
@@ -341,8 +341,8 @@ class FormMixin:
341
341
  - ``"spinner"``: Displays a spinner as an icon.
342
342
 
343
343
  icon_position : "left" or "right"
344
- The position of the icon relative to the button label. Defaults to
345
- ``"left"``.
344
+ The position of the icon relative to the button label. This
345
+ defaults to ``"left"``.
346
346
 
347
347
  disabled : bool
348
348
  Whether to disable the button. If this is ``False`` (default), the
@@ -245,7 +245,7 @@ def _float_formatter(component: float, color: MaybeColor) -> float:
245
245
  Anything too small will become 0.0, and anything too large will become 1.0.
246
246
  """
247
247
  if isinstance(component, int):
248
- component = component / 255.0
248
+ component /= 255.0
249
249
 
250
250
  if isinstance(component, float):
251
251
  return min(1.0, max(component, 0.0))
@@ -265,7 +265,7 @@ def image_to_url(
265
265
 
266
266
  if image.endswith(".svg") and os.path.isfile(image):
267
267
  # Unpack local SVG image file to an SVG string
268
- with open(image) as textfile:
268
+ with open(image, encoding="utf-8") as textfile:
269
269
  image = textfile.read()
270
270
 
271
271
  # Following regex allows svg image files to start either via a "<?xml...>" tag
@@ -108,11 +108,6 @@ class MetricMixin:
108
108
  ) -> DeltaGenerator:
109
109
  r"""Display a metric in big bold font, with an optional indicator of how the metric changed.
110
110
 
111
- Tip: If you want to display a large number, it may be a good idea to
112
- shorten it using packages like `millify <https://github.com/azaitsev/millify>`_
113
- or `numerize <https://github.com/davidsa03/numerize>`_. E.g. ``1234`` can be
114
- displayed as ``1.2k`` using ``st.metric("Short number", millify(1234))``.
115
-
116
111
  Parameters
117
112
  ----------
118
113
  label : str
@@ -135,35 +130,38 @@ class MetricMixin:
135
130
  value : int, float, decimal.Decimal, str, or None
136
131
  Value of the metric. ``None`` is rendered as a long dash.
137
132
 
138
- The value can optionally contain GitHub-flavored Markdown,
139
- including the Markdown directives described in the ``body``
140
- parameter of ``st.markdown``.
133
+ The value can optionally contain GitHub-flavored Markdown, subject
134
+ to the same limitations described in the ``label`` parameter.
141
135
 
142
136
  delta : int, float, decimal.Decimal, str, or None
143
- Indicator of how the metric changed, rendered with an arrow below
144
- the metric. If delta is negative (int/float) or starts with a minus
145
- sign (str), the arrow points down and the text is red; else the
146
- arrow points up and the text is green. If None (default), no delta
147
- indicator is shown.
137
+ Amount or indicator of change in the metric. An arrow is shown next
138
+ to the delta, oriented according to its sign:
148
139
 
149
- The delta can optionally contain GitHub-flavored Markdown
150
- including the Markdown directives described in the ``body``
151
- parameter of ``st.markdown``.
140
+ - If the delta is ``None`` or an empty string, no arrow is shown.
141
+ - If the delta is a negative number or starts with a minus sign,
142
+ the arrow points down and the delta is red.
143
+ - Otherwise, the arrow points up and the delta is green.
144
+
145
+ You can modify the display, color, and orientation of the arrow
146
+ using the ``delta_color`` and ``delta_arrow`` parameters.
147
+
148
+ The delta can optionally contain GitHub-flavored Markdown, subject
149
+ to the same limitations described in the ``label`` parameter.
152
150
 
153
151
  delta_color : str
154
- The color of the delta indicator. This can be one of the following:
155
-
156
- - ``"normal"`` (default): The delta indicator is green when
157
- positive and red when negative.
158
- - ``"inverse"``: The delta indicator is red when positive and
159
- green when negative. This is useful when a negative change is
160
- considered good, e.g. if cost decreased.
161
- - ``"off"``: The delta indicator is shown in gray regardless of
162
- its value.
163
- - A named color from the basic palette: ``"red"``, ``"orange"``,
164
- ``"yellow"``, ``"green"``, ``"blue"``, ``"violet"``,
165
- ``"gray"``/``"grey"``, or ``"primary"``. The delta indicator
166
- and chart uses that color regardless of its value.
152
+ The color of the delta and chart. This can be one of the following:
153
+
154
+ - ``"normal"`` (default): The color is red when the delta is
155
+ negative and green otherwise.
156
+ - ``"inverse"``: The color is green when the delta is negative and
157
+ red otherwise. This is useful when a negative change is
158
+ considered good, like a decrease in cost.
159
+ - ``"off"``: The color is gray regardless of the delta.
160
+ - A named color from the basic palette: The chart and delta are the
161
+ specified color regardless of their value. This can be one of the
162
+ following: ``"red"``, ``"orange"``, ``"yellow"``, ``"green"``,
163
+ ``"blue"``, ``"violet"``, ``"gray"``/``"grey"``, or
164
+ ``"primary"``.
167
165
 
168
166
  help : str or None
169
167
  A tooltip that gets displayed next to the metric label. Streamlit
@@ -189,26 +187,26 @@ class MetricMixin:
189
187
  The height of the metric element. This can be one of the following:
190
188
 
191
189
  - ``"content"`` (default): The height of the element matches the
192
- height of its content.
190
+ height of its content.
193
191
  - ``"stretch"``: The height of the element matches the height of
194
- its content or the height of the parent container, whichever is
195
- larger. If the element is not in a parent container, the height
196
- of the element matches the height of its content.
192
+ its content or the height of the parent container, whichever is
193
+ larger. If the element is not in a parent container, the height
194
+ of the element matches the height of its content.
197
195
  - An integer specifying the height in pixels: The element has a
198
- fixed height. If the content is larger than the specified
199
- height, scrolling is enabled.
196
+ fixed height. If the content is larger than the specified
197
+ height, scrolling is enabled.
200
198
 
201
199
  width : "stretch", "content", or int
202
200
  The width of the metric element. This can be one of the following:
203
201
 
204
202
  - ``"stretch"`` (default): The width of the element matches the
205
- width of the parent container.
203
+ width of the parent container.
206
204
  - ``"content"``: The width of the element matches the width of its
207
- content, but doesn't exceed the width of the parent container.
205
+ content, but doesn't exceed the width of the parent container.
208
206
  - An integer specifying the width in pixels: The element has a
209
- fixed width. If the specified width is greater than the width of
210
- the parent container, the width of the element matches the width
211
- of the parent container.
207
+ fixed width. If the specified width is greater than the width of
208
+ the parent container, the width of the element matches the width
209
+ of the parent container.
212
210
 
213
211
  chart_data : Iterable or None
214
212
  A sequence of numeric values to display as a sparkline chart. If
@@ -218,6 +216,9 @@ class MetricMixin:
218
216
  be used. Each value will be cast to ``float`` internally by
219
217
  default.
220
218
 
219
+ The chart uses the color of the delta indicator, which can be
220
+ modified using the ``delta_color`` parameter.
221
+
221
222
  chart_type : "line", "bar", or "area"
222
223
  The type of sparkline chart to display. This can be one of the
223
224
  following:
@@ -231,18 +232,18 @@ class MetricMixin:
231
232
  one of the following strings:
232
233
 
233
234
  - ``"auto"`` (default): The arrow direction follows the sign of
234
- ``delta``.
235
+ ``delta``.
235
236
  - ``"up"`` or ``"down"``: The arrow is forced to point in the
236
- specified direction.
237
+ specified direction.
237
238
  - ``"off"``: No arrow is shown, but the delta value remains
238
- visible.
239
+ visible.
239
240
 
240
241
  format : str or None
241
242
  A format string controlling how numbers are displayed for ``value``
242
243
  and ``delta``. The format is only applied if the value or delta is
243
- numeric (int, float, or decimal.Decimal). If the value or delta is
244
- a string with non-numeric characters, the format is ignored.
245
- This can be one of the following values:
244
+ numeric. If the value or delta is a string with non-numeric
245
+ characters, the format is ignored. The format can be one of the
246
+ following values:
246
247
 
247
248
  - ``None`` (default): No formatting is applied.
248
249
  - ``"plain"``: Show the full number without any formatting (e.g. "1234.567").
@@ -257,8 +258,8 @@ class MetricMixin:
257
258
  - ``"scientific"``: Show the number in scientific notation (e.g. "1.235E3").
258
259
  - ``"engineering"``: Show the number in engineering notation (e.g. "1.235E3").
259
260
  - printf-style format string: Format the number with a printf
260
- specifier, like ``"%d"`` to show a signed integer (e.g. "1234") or
261
- ``"%.2f"`` to show a float with 2 decimal places.
261
+ specifier, like ``"%d"`` to show a signed integer (e.g. "1234") or
262
+ ``"%.2f"`` to show a float with 2 decimal places.
262
263
 
263
264
  Examples
264
265
  --------
@@ -2404,7 +2404,10 @@ class VegaChartsMixin:
2404
2404
  vega_lite_proto.id = compute_and_register_element_id(
2405
2405
  "arrow_vega_lite_chart",
2406
2406
  user_key=key,
2407
- key_as_main_identity=False,
2407
+ # There are some edge cases where selections can become orphaned when the data changes.
2408
+ # The frontend can handle this without errors, but it might be a nice enhancement
2409
+ # to automatically reset the backend & frontend selection state in this case.
2410
+ key_as_main_identity={"selection_mode"},
2408
2411
  dg=self.dg,
2409
2412
  vega_lite_spec=vega_lite_proto.spec,
2410
2413
  # The data is either in vega_lite_proto.data.data
@@ -223,8 +223,8 @@ class ButtonMixin:
223
223
  - ``"spinner"``: Displays a spinner as an icon.
224
224
 
225
225
  icon_position : "left" or "right"
226
- The position of the icon relative to the button label. Defaults to
227
- ``"left"``.
226
+ The position of the icon relative to the button label. This
227
+ defaults to ``"left"``.
228
228
 
229
229
  disabled : bool
230
230
  An optional boolean that disables the button if set to ``True``.
@@ -539,8 +539,8 @@ class ButtonMixin:
539
539
  - ``"spinner"``: Displays a spinner as an icon.
540
540
 
541
541
  icon_position : "left" or "right"
542
- The position of the icon relative to the button label. Defaults to
543
- ``"left"``.
542
+ The position of the icon relative to the button label. This
543
+ defaults to ``"left"``.
544
544
 
545
545
  disabled : bool
546
546
  An optional boolean that disables the download button if set to
@@ -847,8 +847,8 @@ class ButtonMixin:
847
847
  - ``"spinner"``: Displays a spinner as an icon.
848
848
 
849
849
  icon_position : "left" or "right"
850
- The position of the icon relative to the button label. Defaults to
851
- ``"left"``.
850
+ The position of the icon relative to the button label. This
851
+ defaults to ``"left"``.
852
852
 
853
853
  disabled : bool
854
854
  An optional boolean that disables the link button if set to
@@ -990,7 +990,7 @@ class ButtonMixin:
990
990
  .. _st.markdown: https://docs.streamlit.io/develop/api-reference/text/st.markdown
991
991
 
992
992
  icon : str or None
993
- An optional emoji or icon to display next to the button label. If
993
+ An optional emoji or icon to display next to the link label. If
994
994
  ``icon`` is ``None`` (default), the icon is inferred from the
995
995
  ``StreamlitPage`` object or no icon is displayed. If ``icon`` is a
996
996
  string, the following options are valid:
@@ -1010,8 +1010,8 @@ class ButtonMixin:
1010
1010
  - ``"spinner"``: Displays a spinner as an icon.
1011
1011
 
1012
1012
  icon_position : "left" or "right"
1013
- The position of the icon relative to the page link label. Defaults
1014
- to ``"left"``.
1013
+ The position of the icon relative to the link label. This
1014
+ defaults to ``"left"``.
1015
1015
 
1016
1016
  help : str or None
1017
1017
  A tooltip that gets displayed when the link is hovered over. If
@@ -633,16 +633,12 @@ class ChatMixin:
633
633
  ``None`` (default), there will be no maximum.
634
634
 
635
635
  max_upload_size : int or None
636
- The maximum allowed size of each uploaded file for this chat input,
637
- in megabytes.
636
+ The maximum allowed size of each uploaded file in megabytes.
638
637
 
639
- When set to a positive integer, this per-widget limit takes
640
- precedence over the global ``server.maxUploadSize`` configuration
641
- option.
642
-
643
- When this is ``None`` (default), the chat input falls back to
644
- ``server.maxUploadSize`` for its file size limit. For more
645
- information on how to set config options, see |config.toml|_.
638
+ If this is ``None`` (default), the maximum file size is set by the
639
+ ``server.maxUploadSize`` configuration option in your
640
+ ``config.toml`` file. If this is an integer, it must be positive
641
+ and will override the ``server.maxUploadSize`` configuration option.
646
642
 
647
643
  accept_file : bool, "multiple", or "directory"
648
644
  Whether the chat input should accept files. This can be one of the
@@ -792,10 +792,10 @@ class DataEditorMixin:
792
792
  first index column.
793
793
 
794
794
  num_rows : "fixed", "dynamic", "add", or "delete"
795
- Specifies if the user can add and delete rows in the data editor.
795
+ Specifies if the user can add and/or delete rows in the data editor.
796
796
 
797
- - ``"fixed"`` (default): The user cannot add or delete rows.
798
- - ``"dynamic"``: The user can add and delete rows, but column
797
+ - ``"fixed"`` (default): The user can't add or delete rows.
798
+ - ``"dynamic"``: The user can add and delete rows, and column
799
799
  sorting is disabled.
800
800
  - ``"add"``: The user can only add rows (no deleting), and column
801
801
  sorting is disabled.
@@ -266,9 +266,12 @@ class FileUploaderMixin:
266
266
  width: WidthWithoutContent = "stretch",
267
267
  ) -> UploadedFile | list[UploadedFile] | None:
268
268
  r"""Display a file uploader widget.
269
+
269
270
  By default, uploaded files are limited to 200 MB each. You can
270
- configure this using the ``server.maxUploadSize`` config option. For
271
- more information on how to set config options, see |config.toml|_.
271
+ configure this globally using the ``server.maxUploadSize`` configuration
272
+ option. For more information on how to set configuration options, see
273
+ |config.toml|_. Additionally, you can set a per-widget limit using the
274
+ ``max_upload_size`` parameter.
272
275
 
273
276
  .. |config.toml| replace:: ``config.toml``
274
277
  .. _config.toml: https://docs.streamlit.io/develop/api-reference/configuration/config.toml
@@ -315,16 +318,12 @@ class FileUploaderMixin:
315
318
  part of the app developer's responsibility.
316
319
 
317
320
  max_upload_size : int or None
318
- The maximum allowed size of each uploaded file for this uploader,
319
- in megabytes.
320
-
321
- When set to a positive integer, this per-widget limit takes
322
- precedence over the global ``server.maxUploadSize`` configuration
323
- option.
321
+ The maximum allowed size of each uploaded file in megabytes.
324
322
 
325
- When this is ``None`` (default), the uploader falls back to
326
- ``server.maxUploadSize`` for its file size limit. For more
327
- information on how to set config options, see |config.toml|_.
323
+ If this is ``None`` (default), the maximum file size is set by the
324
+ ``server.maxUploadSize`` configuration option in your
325
+ ``config.toml`` file. If this is an integer, it must be positive
326
+ and will override the ``server.maxUploadSize`` configuration option.
328
327
 
329
328
  accept_multiple_files : bool or "directory"
330
329
  Whether to accept more than one file in a submission. This can be one
@@ -247,7 +247,7 @@ class MultiSelectMixin:
247
247
  placeholder: str | None = None,
248
248
  disabled: bool = False,
249
249
  label_visibility: LabelVisibility = "visible",
250
- accept_new_options: Literal[False, True] | bool = False,
250
+ accept_new_options: bool = False,
251
251
  width: WidthWithoutContent = "stretch",
252
252
  ) -> list[T] | list[T | str]:
253
253
  r"""Display a multiselect widget.
@@ -200,6 +200,10 @@ class SelectSliderMixin:
200
200
  ``options`` is dataframe-like, the first column will be used. Each
201
201
  label will be cast to ``str`` internally by default.
202
202
 
203
+ Each item in the iterable can optionally contain GitHub-flavored
204
+ Markdown, subject to the same limitations described in the
205
+ ``label`` parameter.
206
+
203
207
  value : a supported type or a tuple/list of supported types or None
204
208
  The value of the slider when it first renders. If a tuple/list
205
209
  of two values is passed here, then a range slider with those lower
@@ -127,7 +127,7 @@ def _convert_datelike_to_date(
127
127
  if isinstance(value, date):
128
128
  return value
129
129
 
130
- if value in {"today"}:
130
+ if value == "today":
131
131
  return datetime.now().date()
132
132
 
133
133
  if isinstance(value, str):
@@ -178,8 +178,7 @@ class WriteMixin:
178
178
 
179
179
  def flush_stream_response() -> None:
180
180
  """Write the full response to the app."""
181
- nonlocal streamed_response
182
- nonlocal stream_container
181
+ nonlocal streamed_response, stream_container
183
182
 
184
183
  if streamed_response and stream_container:
185
184
  # Replace the stream_container element the full response
streamlit/errors.py CHANGED
@@ -12,6 +12,8 @@
12
12
  # See the License for the specific language governing permissions and
13
13
  # limitations under the License.
14
14
 
15
+ # ruff: noqa: RUF027 - We allow template strings in localizable exception messages instead of f-strings.
16
+
15
17
  from __future__ import annotations
16
18
 
17
19
  import os
@@ -129,7 +129,7 @@ class LLMThoughtLabeler:
129
129
  input_str_len = min(MAX_TOOL_INPUT_STR_LENGTH, len(input_str))
130
130
  input_str = input_str[:input_str_len]
131
131
  if len(tool.input_str) > input_str_len:
132
- input_str = input_str + "..."
132
+ input_str += "..."
133
133
  input_str = input_str.replace("\n", " ")
134
134
  return f"**{name}:** {input_str}"
135
135
 
@@ -17,36 +17,36 @@ See the License for the specific language governing permissions and
17
17
  limitations under the License.
18
18
  """
19
19
 
20
- import builtins
21
- import google.protobuf.descriptor
22
- import google.protobuf.internal.enum_type_wrapper
23
- import google.protobuf.message
24
- import streamlit.proto.WidthConfig_pb2
20
+ from google.protobuf import descriptor as _descriptor
21
+ from google.protobuf import message as _message
22
+ from google.protobuf.internal import enum_type_wrapper as _enum_type_wrapper
23
+ from streamlit.proto import WidthConfig_pb2 as _WidthConfig_pb2
24
+ import builtins as _builtins
25
25
  import sys
26
- import typing
26
+ import typing as _typing
27
27
 
28
28
  if sys.version_info >= (3, 10):
29
- import typing as typing_extensions
29
+ from typing import TypeAlias as _TypeAlias
30
30
  else:
31
- import typing_extensions
31
+ from typing_extensions import TypeAlias as _TypeAlias
32
32
 
33
- DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
33
+ DESCRIPTOR: _descriptor.FileDescriptor
34
34
 
35
- @typing.final
36
- class Alert(google.protobuf.message.Message):
35
+ @_typing.final
36
+ class Alert(_message.Message):
37
37
  """NOTE: This proto type is used by some external services so needs to remain
38
38
  relatively stable. While it isn't entirely set in stone, changing it
39
39
  may require a good amount of effort so should be avoided if possible.
40
40
  """
41
41
 
42
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
42
+ DESCRIPTOR: _descriptor.Descriptor
43
43
 
44
44
  class _Format:
45
- ValueType = typing.NewType("ValueType", builtins.int)
46
- V: typing_extensions.TypeAlias = ValueType
45
+ ValueType = _typing.NewType("ValueType", _builtins.int)
46
+ V: _TypeAlias = ValueType # noqa: Y015
47
47
 
48
- class _FormatEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[Alert._Format.ValueType], builtins.type):
49
- DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
48
+ class _FormatEnumTypeWrapper(_enum_type_wrapper._EnumTypeWrapper[Alert._Format.ValueType], _builtins.type):
49
+ DESCRIPTOR: _descriptor.EnumDescriptor
50
50
  UNUSED: Alert._Format.ValueType # 0
51
51
  """Plain, fixed width text."""
52
52
  ERROR: Alert._Format.ValueType # 1
@@ -72,29 +72,29 @@ class Alert(google.protobuf.message.Message):
72
72
  SUCCESS: Alert.Format.ValueType # 4
73
73
  """Shows a success message."""
74
74
 
75
- BODY_FIELD_NUMBER: builtins.int
76
- FORMAT_FIELD_NUMBER: builtins.int
77
- ICON_FIELD_NUMBER: builtins.int
78
- WIDTH_CONFIG_FIELD_NUMBER: builtins.int
79
- body: builtins.str
75
+ BODY_FIELD_NUMBER: _builtins.int
76
+ FORMAT_FIELD_NUMBER: _builtins.int
77
+ ICON_FIELD_NUMBER: _builtins.int
78
+ WIDTH_CONFIG_FIELD_NUMBER: _builtins.int
79
+ body: _builtins.str
80
80
  """Content to display."""
81
81
  format: Global___Alert.Format.ValueType
82
- icon: builtins.str
83
- @property
84
- def width_config(self) -> streamlit.proto.WidthConfig_pb2.WidthConfig:
82
+ icon: _builtins.str
83
+ @_builtins.property
84
+ def width_config(self) -> _WidthConfig_pb2.WidthConfig:
85
85
  """Indicates the width setting: "stetch", "content" or a pixel value."""
86
86
 
87
87
  def __init__(
88
88
  self,
89
89
  *,
90
- body: builtins.str = ...,
90
+ body: _builtins.str = ...,
91
91
  format: Global___Alert.Format.ValueType = ...,
92
- icon: builtins.str = ...,
93
- width_config: streamlit.proto.WidthConfig_pb2.WidthConfig | None = ...,
92
+ icon: _builtins.str = ...,
93
+ width_config: _WidthConfig_pb2.WidthConfig | None = ...,
94
94
  ) -> None: ...
95
- _HasFieldArgType: typing_extensions.TypeAlias = typing.Literal["width_config", b"width_config"]
96
- def HasField(self, field_name: _HasFieldArgType) -> builtins.bool: ...
97
- _ClearFieldArgType: typing_extensions.TypeAlias = typing.Literal["body", b"body", "format", b"format", "icon", b"icon", "width_config", b"width_config"]
95
+ _HasFieldArgType: _TypeAlias = _typing.Literal["width_config", b"width_config"] # noqa: Y015
96
+ def HasField(self, field_name: _HasFieldArgType) -> _builtins.bool: ...
97
+ _ClearFieldArgType: _TypeAlias = _typing.Literal["body", b"body", "format", b"format", "icon", b"icon", "width_config", b"width_config"] # noqa: Y015
98
98
  def ClearField(self, field_name: _ClearFieldArgType) -> None: ...
99
99
 
100
- Global___Alert: typing_extensions.TypeAlias = Alert
100
+ Global___Alert: _TypeAlias = Alert # noqa: Y015
@@ -17,21 +17,21 @@ See the License for the specific language governing permissions and
17
17
  limitations under the License.
18
18
  """
19
19
 
20
- import builtins
21
- import google.protobuf.descriptor
22
- import google.protobuf.message
20
+ from google.protobuf import descriptor as _descriptor
21
+ from google.protobuf import message as _message
22
+ import builtins as _builtins
23
23
  import sys
24
- import typing
24
+ import typing as _typing
25
25
 
26
26
  if sys.version_info >= (3, 10):
27
- import typing as typing_extensions
27
+ from typing import TypeAlias as _TypeAlias
28
28
  else:
29
- import typing_extensions
29
+ from typing_extensions import TypeAlias as _TypeAlias
30
30
 
31
- DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
31
+ DESCRIPTOR: _descriptor.FileDescriptor
32
32
 
33
- @typing.final
34
- class AppPage(google.protobuf.message.Message):
33
+ @_typing.final
34
+ class AppPage(_message.Message):
35
35
  """A page in the app. Includes both the name of the page as well as the full
36
36
  path to the corresponding script file.
37
37
 
@@ -40,32 +40,32 @@ class AppPage(google.protobuf.message.Message):
40
40
  may require a good amount of effort so should be avoided if possible.
41
41
  """
42
42
 
43
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
43
+ DESCRIPTOR: _descriptor.Descriptor
44
44
 
45
- PAGE_SCRIPT_HASH_FIELD_NUMBER: builtins.int
46
- PAGE_NAME_FIELD_NUMBER: builtins.int
47
- ICON_FIELD_NUMBER: builtins.int
48
- IS_DEFAULT_FIELD_NUMBER: builtins.int
49
- SECTION_HEADER_FIELD_NUMBER: builtins.int
50
- URL_PATHNAME_FIELD_NUMBER: builtins.int
51
- page_script_hash: builtins.str
52
- page_name: builtins.str
53
- icon: builtins.str
54
- is_default: builtins.bool
45
+ PAGE_SCRIPT_HASH_FIELD_NUMBER: _builtins.int
46
+ PAGE_NAME_FIELD_NUMBER: _builtins.int
47
+ ICON_FIELD_NUMBER: _builtins.int
48
+ IS_DEFAULT_FIELD_NUMBER: _builtins.int
49
+ SECTION_HEADER_FIELD_NUMBER: _builtins.int
50
+ URL_PATHNAME_FIELD_NUMBER: _builtins.int
51
+ page_script_hash: _builtins.str
52
+ page_name: _builtins.str
53
+ icon: _builtins.str
54
+ is_default: _builtins.bool
55
55
  """A feature for MPA v2 to inform the frontend what's the default page"""
56
- section_header: builtins.str
57
- url_pathname: builtins.str
56
+ section_header: _builtins.str
57
+ url_pathname: _builtins.str
58
58
  def __init__(
59
59
  self,
60
60
  *,
61
- page_script_hash: builtins.str = ...,
62
- page_name: builtins.str = ...,
63
- icon: builtins.str = ...,
64
- is_default: builtins.bool = ...,
65
- section_header: builtins.str = ...,
66
- url_pathname: builtins.str = ...,
61
+ page_script_hash: _builtins.str = ...,
62
+ page_name: _builtins.str = ...,
63
+ icon: _builtins.str = ...,
64
+ is_default: _builtins.bool = ...,
65
+ section_header: _builtins.str = ...,
66
+ url_pathname: _builtins.str = ...,
67
67
  ) -> None: ...
68
- _ClearFieldArgType: typing_extensions.TypeAlias = typing.Literal["icon", b"icon", "is_default", b"is_default", "page_name", b"page_name", "page_script_hash", b"page_script_hash", "section_header", b"section_header", "url_pathname", b"url_pathname"]
68
+ _ClearFieldArgType: _TypeAlias = _typing.Literal["icon", b"icon", "is_default", b"is_default", "page_name", b"page_name", "page_script_hash", b"page_script_hash", "section_header", b"section_header", "url_pathname", b"url_pathname"] # noqa: Y015
69
69
  def ClearField(self, field_name: _ClearFieldArgType) -> None: ...
70
70
 
71
- Global___AppPage: typing_extensions.TypeAlias = AppPage
71
+ Global___AppPage: _TypeAlias = AppPage # noqa: Y015
@@ -17,37 +17,37 @@ See the License for the specific language governing permissions and
17
17
  limitations under the License.
18
18
  """
19
19
 
20
- import builtins
21
- import google.protobuf.descriptor
22
- import google.protobuf.message
20
+ from google.protobuf import descriptor as _descriptor
21
+ from google.protobuf import message as _message
22
+ import builtins as _builtins
23
23
  import sys
24
- import typing
24
+ import typing as _typing
25
25
 
26
26
  if sys.version_info >= (3, 10):
27
- import typing as typing_extensions
27
+ from typing import TypeAlias as _TypeAlias
28
28
  else:
29
- import typing_extensions
29
+ from typing_extensions import TypeAlias as _TypeAlias
30
30
 
31
- DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
31
+ DESCRIPTOR: _descriptor.FileDescriptor
32
32
 
33
- @typing.final
34
- class ArrowData(google.protobuf.message.Message):
33
+ @_typing.final
34
+ class ArrowData(_message.Message):
35
35
  """Data-only Arrow buffer. This intentionally excludes any UI- or element-
36
36
  specific configuration that exists in Arrow.proto. Use this message when
37
37
  only the serialized Arrow data is required.
38
38
  """
39
39
 
40
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
40
+ DESCRIPTOR: _descriptor.Descriptor
41
41
 
42
- DATA_FIELD_NUMBER: builtins.int
43
- data: builtins.bytes
42
+ DATA_FIELD_NUMBER: _builtins.int
43
+ data: _builtins.bytes
44
44
  """The serialized Apache Arrow buffer (IPC stream or file format bytes)"""
45
45
  def __init__(
46
46
  self,
47
47
  *,
48
- data: builtins.bytes = ...,
48
+ data: _builtins.bytes = ...,
49
49
  ) -> None: ...
50
- _ClearFieldArgType: typing_extensions.TypeAlias = typing.Literal["data", b"data"]
50
+ _ClearFieldArgType: _TypeAlias = _typing.Literal["data", b"data"] # noqa: Y015
51
51
  def ClearField(self, field_name: _ClearFieldArgType) -> None: ...
52
52
 
53
- Global___ArrowData: typing_extensions.TypeAlias = ArrowData
53
+ Global___ArrowData: _TypeAlias = ArrowData # noqa: Y015