2323from pathlib import Path
2424from typing import Any , Optional
2525
26- import httpx
26+ import httpx2
2727import yaml
2828from github import Auth , Github
2929from packaging .version import InvalidVersion , Version
@@ -292,7 +292,7 @@ def update_plugin_version_registry(self, manifest: PluginManifest, relpath: Path
292292 encoding = "utf-8" ,
293293 )
294294
295- def save_manifest_content (self , content : str , path , repo_url : httpx .URL ):
295+ def save_manifest_content (self , content : str , path , repo_url : httpx2 .URL ):
296296 """
297297 write the manifest content to the supplied path relative to the ouptut folder,
298298 injecting the monorepo.package_source value before saving the file.
@@ -333,11 +333,11 @@ def save_catalog_content(self, content: str, path):
333333 """
334334 self .save_content (self .catalog_folder , content , path )
335335
336- def download_contents (self , git_url : str , headers , path : str , repo_url : httpx .URL ):
336+ def download_contents (self , git_url : str , headers , path : str , repo_url : httpx2 .URL ):
337337 """
338338 Download the contents of the file using the github REST API.
339339 """
340- result = httpx .get (git_url , headers = headers , timeout = 30.0 )
340+ result = httpx2 .get (git_url , headers = headers , timeout = 30.0 )
341341 if result .status_code == 200 :
342342 js = result .json ()
343343 b64_content = js ["content" ]
@@ -456,7 +456,7 @@ def _search_github_code(self, repo_path: str, member: str | None, headers) -> li
456456 return None
457457
458458 def _transform_manifest_data (
459- self , manifest_content : dict , name : str , member : str | None , repo_url : httpx .URL
459+ self , manifest_content : dict , name : str , member : str | None , repo_url : httpx2 .URL
460460 ) -> dict :
461461 """Apply standard transformations to manifest data.
462462
@@ -507,7 +507,7 @@ def _process_manifest_item(
507507 item : dict ,
508508 name : str ,
509509 member : str ,
510- repo_url : httpx .URL ,
510+ repo_url : httpx2 .URL ,
511511 headers ,
512512 relpath : Path ,
513513 repo_path : str ,
@@ -548,7 +548,7 @@ def _process_manifest_item(
548548 return True
549549
550550 def _process_version_item (
551- self , item : dict , member : str , name : str , repo_url : httpx .URL , headers , relpath , repo_path , gh_repo
551+ self , item : dict , member : str , name : str , repo_url : httpx2 .URL , headers , relpath , repo_path , gh_repo
552552 ) -> None :
553553 """Find plugin-versions.json files relative to the supplied member folder,
554554 download and save the manifest, updating the monorepo's package_folder, package_source and repo_url attributes
@@ -566,7 +566,7 @@ def _process_version_item(
566566 return
567567 relpath .write_text (version_data , encoding = "utf-8" )
568568
569- def find_and_save_plugin_versions_json (self , member : str , name : str , repo_url : httpx .URL , headers , gh_repo ) -> None :
569+ def find_and_save_plugin_versions_json (self , member : str , name : str , repo_url : httpx2 .URL , headers , gh_repo ) -> None :
570570 """Find plugin-versions.json files relative to the supplied member folder,
571571 download and save the manifest, updating the monorepo's package_folder, package_source and repo_url attributes
572572 Args:
@@ -590,7 +590,7 @@ def find_and_save_plugin_versions_json(self, member: str, name: str, repo_url: h
590590 self ._process_version_item (item , member , name , repo_url , headers , relpath , repo_path , gh_repo )
591591
592592 def find_and_save_plugin_manifest (
593- self , member : str , name : str , repo_url : httpx .URL , headers , gh_repo
593+ self , member : str , name : str , repo_url : httpx2 .URL , headers , gh_repo
594594 ) -> PluginManifest | None :
595595 """Find plugin-manifest*.yaml files relative to the supplied member folder,
596596 download and save the manifest, updating the monorepo's package_folder, package_source and repo_url attributes
@@ -620,7 +620,7 @@ def find_and_save_plugin_manifest(
620620
621621 return None
622622
623- def _process_pyproject (self , gh_repo , item , repo_url : httpx .URL , headers ) -> None :
623+ def _process_pyproject (self , gh_repo , item , repo_url : httpx2 .URL , headers ) -> None :
624624 """Process a single pyproject.toml file.
625625
626626 Args:
@@ -672,7 +672,7 @@ def update_catalog_with_pyproject(self) -> bool:
672672 repo_cache : dict [str , Any ] = {}
673673
674674 for repo in self .monorepos :
675- repo_url = httpx .URL (repo .strip ())
675+ repo_url = httpx2 .URL (repo .strip ())
676676 repo_path = repo_url .path .removeprefix ("/" )
677677
678678 try :
0 commit comments