You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2020/11/24 17:59:47 UTC
[GitHub] [incubator-superset] ktmud commented on pull request #11776: fix(reports): dashboard references aren't clear
ktmud commented on pull request #11776:
URL: https://github.com/apache/incubator-superset/pull/11776#issuecomment-733142923
We have [dashboard cache](https://github.com/apache/incubator-superset/blob/4cfcaebb612bd599f5cf29bf43fc75f387f17e76/superset%2Fmodels%2Fdashboard.py#L221). `__str__` and `__repr__` by nature is internal and should not be used directly in user-facing interfaces.
Flask-caching uses [`__str__`](https://github.com/sh4nks/flask-caching/blob/v1.9.0/flask_caching/__init__.py#L512) and unfortunately there is no way to override it---unless we stop using it for instance methods and manually making sure everything passed to the cache key maker has deterministic `str` representation.
We should probably give the CRUD view select a custom renderer instead and keep `str` deterministic. If it is hard to update the renderer, we should at least add dashboard ID to `__str__` as it's not uncommon to see dashboards with the same title in large organizations.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org