python: Reformat code with black 22.3.0

Related to T3922
This commit is contained in:
Antoine Lambert 2022-04-08 15:15:09 +02:00
parent 00f1b99ad9
commit d38e05cff7
37 changed files with 265 additions and 144 deletions

View file

@ -28,7 +28,9 @@ class GNULister(StatelessLister[GNUPageType]):
GNU_FTP_URL = "https://ftp.gnu.org"
def __init__(
self, scheduler: SchedulerInterface, credentials: CredentialsType = None,
self,
scheduler: SchedulerInterface,
credentials: CredentialsType = None,
):
super().__init__(
scheduler=scheduler,

View file

@ -19,9 +19,7 @@ logger = logging.getLogger(__name__)
class GNUTree:
"""Gnu Tree's representation
"""
"""Gnu Tree's representation"""
def __init__(self, url: str):
self.url = url # filepath or uri
@ -330,7 +328,5 @@ def load_raw_data(url: str) -> Sequence[Mapping]:
def format_date(timestamp: str) -> str:
"""Format a string timestamp to an isoformat string
"""
"""Format a string timestamp to an isoformat string"""
return datetime.fromtimestamp(int(timestamp), tz=timezone.utc).isoformat()