Log when a non-server-url is passed to check_server
This commit is contained in:
parent
12f9a012f7
commit
7b72ced147
1 changed files with 2 additions and 0 deletions
|
@ -496,7 +496,9 @@ class Ollama(commands.Cog):
|
||||||
async def check_server(self, url: str) -> bool:
|
async def check_server(self, url: str) -> bool:
|
||||||
"""Checks that a server is online and responding."""
|
"""Checks that a server is online and responding."""
|
||||||
if url in SERVER_KEYS:
|
if url in SERVER_KEYS:
|
||||||
|
_u = url
|
||||||
url = CONFIG["ollama"][url]["base_url"]
|
url = CONFIG["ollama"][url]["base_url"]
|
||||||
|
self.log.warning("Resolved 'url' %s to %s", _u, url)
|
||||||
async with aiohttp.ClientSession(timeout=aiohttp.ClientTimeout(10)) as session:
|
async with aiohttp.ClientSession(timeout=aiohttp.ClientTimeout(10)) as session:
|
||||||
self.log.debug("Checking if %r is online.", url)
|
self.log.debug("Checking if %r is online.", url)
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in a new issue