mirror of
https://gitlab.com/allianceauth/allianceauth.git
synced 2025-07-17 00:10:15 +02:00
Last fixes
This commit is contained in:
parent
fd84f7fe15
commit
c9b07c12a0
@ -16,7 +16,7 @@ from .models import NameFormatConfig
|
||||
def get_extension_logger(name):
|
||||
"""
|
||||
Takes the name of a plugin/extension and generates a child logger of the extensions logger
|
||||
to be used by the extension to log events to the extensions
|
||||
to be used by the extension to log events to the extensions logger.
|
||||
|
||||
The logging level is determined by the level defined for the parent logger.
|
||||
|
||||
|
@ -20,7 +20,7 @@ register = template.Library()
|
||||
|
||||
# cache timers
|
||||
TAG_CACHE_TIME = 3600 # 1 hours
|
||||
NOTIFICATION_CACHE_TIME = 10 # 5 minutes
|
||||
NOTIFICATION_CACHE_TIME = 300 # 5 minutes
|
||||
# timeout for all requests
|
||||
REQUESTS_TIMEOUT = 5 # 5 seconds
|
||||
# max pages to be fetched from gitlab
|
||||
@ -213,7 +213,7 @@ def _current_version_summary() -> dict:
|
||||
has_current_beta = \
|
||||
current_version <= latest_beta_version \
|
||||
and latest_patch_version <= latest_beta_version \
|
||||
if latest_beta_version else False
|
||||
if latest_beta_version else False
|
||||
|
||||
response = {
|
||||
'latest_patch': has_latest_patch,
|
||||
@ -319,7 +319,7 @@ def _fetch_list_from_github(url: str, max_pages: int = MAX_PAGES) -> list:
|
||||
logger.debug(request.json())
|
||||
|
||||
# https://docs.github.com/en/rest/using-the-rest-api/using-pagination-in-the-rest-api?apiVersion=2022-11-28
|
||||
# See Example creating a pagination metho
|
||||
# See Example creating a pagination method
|
||||
if not ('link' in request.headers and 'rel=\"next\"' in request.headers['link']):
|
||||
break
|
||||
|
||||
|
@ -38,6 +38,8 @@ A repository with the url `https://gitlab.com/username/appname` will have a name
|
||||
|
||||
This variable is an enumeration of the class `AppAnnouncemementHook.RepositoryKind`
|
||||
|
||||
It is mandatory to specify this variable so alliance auth contacts the correct API when fetching your repository issues.
|
||||
|
||||
```{eval-rst}
|
||||
.. autoclass:: allianceauth.services.hooks.AppAnnouncementHook.RepositoryKind
|
||||
:members: GITLAB, GITHUB
|
||||
|
Loading…
x
Reference in New Issue
Block a user