Andrushika commented on code in PR #76890:
URL: https://github.com/apache/airflow/pull/76890#discussion_r4536059981


##########
shared/module_loading/src/airflow_shared/module_loading/__init__.py:
##########
@@ -178,8 +178,11 @@ def _get_grouped_entry_points() -> dict[str, list[EPnD]]:
             # A distribution is yielded once per sys.path entry it is found on 
(e.g. RHEL/Fedora
             # venvs list both lib64/ and lib/ site-packages), possibly in 
different versions.
             # Only the first one is importable, so it is the only one whose 
entry points count.
-            dist_metadata = dist.metadata
-            if dist_metadata and (name := dist_metadata.get("Name")):
+            try:
+                name = dist._normalized_name  # type: ignore[attr-defined]
+            except Exception:
+                name = None
+            if name:
                 normalized_name = _normalize_dist_name(name)

Review Comment:
   Fixed, thanks



-- 
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]

Reply via email to