codeant-ai-for-open-source[bot] commented on code in PR #45410:
URL: https://github.com/apache/superset/pull/45410#discussion_r4321075101
##########
superset/charts/client_processing.py:
##########
@@ -1237,6 +1250,20 @@ def label_of(name: str) -> str:
# left untouched, matching the browser.
for column in df.columns:
config = config_by_label.get(column) or {}
+
+ # Mirror the Table plugin's first formatter branch
+ # (``if (isTime || config.d3TimeFormat)`` in ``transformProps.ts``):
+ # an explicit per-column ``d3TimeFormat`` formats a temporal column and
+ # takes precedence over number formatting. Scoped to datetime columns
+ # with an explicit format; the bare ``isTime`` fallback,
+ # ``tableTimestampFormat`` default, SMART_DATE granularity, and string
+ # temporal columns are intentionally left to a follow-up, since they
+ # need a full server-side d3-time-format port rather than ``strftime``.
+ time_format = config.get("d3TimeFormat")
+ if time_format and pd.api.types.is_datetime64_any_dtype(df[column]):
+ format_time_column(df, column, time_format)
Review Comment:
✅ **CodeAnt verified this suggestion was addressed in subsequent commits and
marked this thread resolved** as of `d21b2b3`.
Datetime formatting now skips `SMART_DATE` and other
non-`strftime`-expressible aliases, so `smart_date` is not passed to
`format_time_column` as a literal format string.
<sub>If that's not right, unresolve this thread and CodeAnt will leave it
open.</sub>
<!-- codeant-auto-resolve-reply -->
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]