Bugfix: Update apprise:// token length (#1120)

pull/1121/head
Toni Wells 2024-05-03 05:03:22 -07:00 committed by GitHub
parent b8da1334ab
commit fcd70ff84c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 1 deletions

View File

@ -123,7 +123,7 @@ class NotifyAppriseAPI(NotifyBase):
'type': 'string', 'type': 'string',
'required': True, 'required': True,
'private': True, 'private': True,
'regex': (r'^[A-Z0-9_-]{1,32}$', 'i'), 'regex': (r'^[A-Z0-9_-]{1,128}$', 'i'),
}, },
}) })

View File

@ -70,6 +70,12 @@ apprise_url_tests = (
# Our expected url(privacy=True) startswith() response: # Our expected url(privacy=True) startswith() response:
'privacy_url': 'apprise://localhost/a...a/', 'privacy_url': 'apprise://localhost/a...a/',
}), }),
# A valid URL with long Token
('apprise://localhost/%s' % ('a' * 128), {
'instance': NotifyAppriseAPI,
# Our expected url(privacy=True) startswith() response:
'privacy_url': 'apprise://localhost/a...a/',
}),
# A valid URL with Token (using port) # A valid URL with Token (using port)
('apprise://localhost:8080/%s' % ('b' * 32), { ('apprise://localhost:8080/%s' % ('b' * 32), {
'instance': NotifyAppriseAPI, 'instance': NotifyAppriseAPI,