villebro commented on a change in pull request #16227:
URL: https://github.com/apache/superset/pull/16227#discussion_r688252811
##########
File path: superset/typing.py
##########
@@ -57,7 +57,7 @@ class AdhocMetricColumn(TypedDict, total=False):
class AdhocMetric(TypedDict, total=False):
aggregate: str
column: Optional[AdhocMetricColumn]
- expressionType: str
+ expressionType: Literal["SIMPLE", "SQL"]
Review comment:
Good idea. In the next iteration I'll see if I can convert some of these
`Literal`'s to `Enum`s. But it may well be that this is the most accurate
representation of this type, as we want to indicate that this is a string that
can only take on two values (equivalent of TypeScript's `expressionType:
'SIMPLE' | 'SQL'`)
--
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]