Skip to content

Commit

Permalink
Cease using InventoryFileReader (apache#45391)
Browse files Browse the repository at this point in the history
  • Loading branch information
AA-Turner authored and got686-yandex committed Jan 30, 2025
1 parent f6fd21b commit 532f54c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions docs/exts/docs_build/fetch_inventories.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
import requests
import urllib3.exceptions
from requests.adapters import DEFAULT_POOLSIZE
from sphinx.util.inventory import InventoryFileReader

from airflow.utils.helpers import partition
from docs.exts.docs_build.docs_builder import get_available_providers_packages
Expand Down Expand Up @@ -73,7 +72,7 @@ def _fetch_file(session: requests.Session, package_name: str, url: str, path: st
tf.flush()
tf.seek(0, 0)

line = InventoryFileReader(tf).readline()
line = tf.readline().decode()
if not line.startswith("# Sphinx inventory version"):
print(f"{package_name}: Response contain unexpected Sphinx Inventory header: {line!r}.")
return package_name, False
Expand Down

0 comments on commit 532f54c

Please sign in to comment.