Skip to content

Commit

Permalink
Fix leftover http issues
Browse files Browse the repository at this point in the history
  • Loading branch information
henribru committed Nov 19, 2023
1 parent f6e4382 commit 64674e0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions googleapiclient-stubs/http.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import logging
import typing

import httplib2
from _typeshed import Incomplete
from _typeshed import Incomplete, StrPath

from googleapiclient.errors import (
BatchError as BatchError,
Expand Down Expand Up @@ -60,7 +60,7 @@ class MediaIoBaseUpload(MediaUpload):
class MediaFileUpload(MediaIoBaseUpload):
def __init__(
self,
filename: str, # TODO: StrPath?
filename: StrPath,
mimetype: str | None = None,
chunksize: int = 104857600,
resumable: bool = False,
Expand All @@ -76,7 +76,7 @@ class MediaInMemoryUpload(MediaIoBaseUpload):
) -> None: ...

class MediaIoBaseDownload:
def __init__(self, fd, request, chunksize: int = 104857600) -> None: ...
def __init__(self, fd: io.IOBase, request: HttpRequest, chunksize: int = 104857600) -> None: ...
def next_chunk(
self, num_retries: int = 0
) -> tuple[MediaDownloadProgress, bool]: ...
Expand All @@ -85,7 +85,7 @@ class HttpRequest:
uri: str
method: str
body: str | None
headers: dict | None
headers: dict[str, str] | None
methodId: str | None
http: httplib2.Http | HttpMock
postproc: collections.abc.Callable[[httplib2.Response, bytes], typing.Any]
Expand All @@ -101,7 +101,7 @@ class HttpRequest:
uri: str,
method: str = "GET",
body: str | None = None,
headers: dict | None = None,
headers: dict[str, str] | None = None,
methodId: str | None = None,
resumable: MediaUpload | None = None,
) -> None: ...
Expand Down

0 comments on commit 64674e0

Please sign in to comment.