Closed zsiciarz closed 3 years ago
As of now we explicitly check entrypoint types in worker_result(). We could dispatch on the entrypoint type instead.
worker_result()
Note: singledispatchmethod was added in Python 3.8. If we want to dispatch to PrometheusMetrics methods, we need to provide backport for 3.6-3.7.
PrometheusMetrics
There's a backport on PyPI: https://pypi.org/project/singledispatchmethod/
Released in 1.1.0.
As of now we explicitly check entrypoint types in
worker_result()
. We could dispatch on the entrypoint type instead.Note: singledispatchmethod was added in Python 3.8. If we want to dispatch to
PrometheusMetrics
methods, we need to provide backport for 3.6-3.7.