From ec335748832fe299f45896116a1e23864ed9db38 Mon Sep 17 00:00:00 2001 From: "Jason R. Coombs" Date: Fri, 21 Jun 2024 14:57:42 -0400 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B9=20Feed=20the=20hobgoblins=20(delin?= =?UTF-8?q?t).?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jaraco/develop/git.py | 4 ++-- jaraco/develop/github.py | 4 ++-- jaraco/develop/macos-build-python.py | 2 +- jaraco/develop/rtd.py | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/jaraco/develop/git.py b/jaraco/develop/git.py index 9b88384..2ae2029 100644 --- a/jaraco/develop/git.py +++ b/jaraco/develop/git.py @@ -64,7 +64,7 @@ def apply(self, url): return url.replace(self.value, self.prefix) @classmethod - @functools.lru_cache() + @functools.lru_cache def load(cls): cmd = ['git', 'config', '--get-regexp', r'url\..*\.insteadof'] lines = subprocess.run( @@ -206,7 +206,7 @@ def checkout(project: Project, target: path.Path = path.Path(), **kwargs): return repo -@functools.lru_cache() +@functools.lru_cache def _session(): """ Return a requests session capable of opening files. diff --git a/jaraco/develop/github.py b/jaraco/develop/github.py index e6c2fad..69cc533 100644 --- a/jaraco/develop/github.py +++ b/jaraco/develop/github.py @@ -23,7 +23,7 @@ def __init__(self, name): self.session = self.get_session() @classmethod - @functools.lru_cache() + @functools.lru_cache def get_session(cls): session = sessions.BaseUrlSession('https://api.github.com/repos/') session.headers.update( @@ -45,7 +45,7 @@ def load_token(): def detect(cls): return cls(repo.get_project_metadata().project) - @functools.lru_cache() + @functools.lru_cache def get_public_key(self): data = self.session.get(f'{self}/actions/secrets/public-key').json() key = Key(data['key']) diff --git a/jaraco/develop/macos-build-python.py b/jaraco/develop/macos-build-python.py index f0f3840..0ba7ab8 100644 --- a/jaraco/develop/macos-build-python.py +++ b/jaraco/develop/macos-build-python.py @@ -11,7 +11,7 @@ import autocommand -@functools.lru_cache() +@functools.lru_cache def brew_prefix(name=None): cmd = ['brew', '--prefix'] if name: diff --git a/jaraco/develop/rtd.py b/jaraco/develop/rtd.py index 82fc271..ba07a13 100644 --- a/jaraco/develop/rtd.py +++ b/jaraco/develop/rtd.py @@ -6,7 +6,7 @@ url = 'https://readthedocs.org/' -@functools.lru_cache() +@functools.lru_cache def session(): auth = 'Token ' + keyring.get_password(url, 'token') session = sessions.BaseUrlSession(url + 'api/v3/')