eyalezer commented on code in PR #28522: URL: https://github.com/apache/superset/pull/28522#discussion_r1605857527
########## superset/utils/json.py: ########## @@ -0,0 +1,211 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +import decimal +import json +import logging +import uuid +from datetime import date, datetime, time, timedelta +from typing import Any, Callable, Optional, Union + +import numpy as np +import pandas as pd +import simplejson +from flask_babel.speaklater import LazyString + +from superset.exceptions import SupersetException +from superset.utils.dates import datetime_to_epoch, EPOCH + +logging.getLogger("MARKDOWN").setLevel(logging.INFO) +logger = logging.getLogger(__name__) + + +def dumps( + obj: Any, + default: Optional[Callable[[Any], Any]] = None, Review Comment: well... since most of the cases within superset should probably use this as the a "default" default 😆 i guess we should use it, i agree. i'll add another commit for it -- 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: notifications-unsubscr...@superset.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@superset.apache.org For additional commands, e-mail: notifications-h...@superset.apache.org