1
Fork 0
mirror of https://github.com/RGBCube/GitHubWrapper synced 2025-05-16 14:15:00 +00:00

Fix typos

This commit is contained in:
RGBCube 2022-06-25 16:08:54 +03:00
parent c04b69fcb7
commit a2a582dd5b
4 changed files with 7 additions and 7 deletions

View file

@ -20,7 +20,7 @@ class BaseHTTPError(GitHubError):
class HTTPError(BaseHTTPError): class HTTPError(BaseHTTPError):
"""Raised when an HTTP request doesn't respond with a successfull code.""" """Raised when an HTTP request doesn't respond with a successful code."""
def __init__(self, response: ClientResponse, /) -> None: def __init__(self, response: ClientResponse, /) -> None:
self.method = response.method self.method = response.method
@ -30,7 +30,7 @@ class HTTPError(BaseHTTPError):
def __str__(self) -> str: def __str__(self) -> str:
return ( return (
f"An HTTP error with the code {self.code} has occured while trying to do a" f"An HTTP error with the code {self.code} has occurred while trying to do a"
f" {self.method} request to the URL {self.url}" f" {self.method} request to the URL {self.url}"
) )

View file

@ -21,7 +21,7 @@ if TYPE_CHECKING:
from typing_extensions import Self from typing_extensions import Self
from ..objects import File from ..objects import File
from ..types import SecurtiyAndAnalysis from ..types import SecurityAndAnalysis
log = logging.getLogger("github") log = logging.getLogger("github")
@ -371,7 +371,7 @@ class HTTPClient:
homepage: Optional[str] = None, homepage: Optional[str] = None,
private: Optional[bool] = None, private: Optional[bool] = None,
visibility: Optional[Literal["public", "private", "internal"]] = None, visibility: Optional[Literal["public", "private", "internal"]] = None,
security_and_analysis: Optional[SecurtiyAndAnalysis] = None, security_and_analysis: Optional[SecurityAndAnalysis] = None,
has_issues: Optional[bool] = None, has_issues: Optional[bool] = None,
has_projects: Optional[bool] = None, has_projects: Optional[bool] = None,
has_wiki: Optional[bool] = None, has_wiki: Optional[bool] = None,

View file

@ -1,4 +1,4 @@
__all__ = ("SecurtiyAndAnalysis",) __all__ = ("SecurityAndAnalysis",)
from typing import TYPE_CHECKING, Literal, TypedDict from typing import TYPE_CHECKING, Literal, TypedDict
@ -18,7 +18,7 @@ class SecretScanningPushProtection(TypedDict):
status: Literal["enabled", "disabled"] status: Literal["enabled", "disabled"]
class SecurtiyAndAnalysis(TypedDict): class SecurityAndAnalysis(TypedDict):
advanced_security: NotRequired[AdvancedSecurity] advanced_security: NotRequired[AdvancedSecurity]
secret_scanning: NotRequired[SecretScanning] secret_scanning: NotRequired[SecretScanning]
secret_scanning_push_protection: NotRequired[SecretScanningPushProtection] secret_scanning_push_protection: NotRequired[SecretScanningPushProtection]

View file

@ -19,7 +19,7 @@ def human_readable_time_until(td: timedelta, /) -> str:
hours, seconds = divmod(seconds, 3600) hours, seconds = divmod(seconds, 3600)
minutes, seconds = divmod(seconds, 60) minutes, seconds = divmod(seconds, 60)
return f"{hours} hours, {minutes} minues, {seconds} seconds" return f"{hours} hours, {minutes} minutes, {seconds} seconds"
def str_to_datetime(time: Optional[str], /) -> Optional[datetime]: def str_to_datetime(time: Optional[str], /) -> Optional[datetime]: