chrisrude / oobabot-plugin

A Discord bot plugin to text-generation-webui, based on oobabot.
https://github.com/chrisrude/oobabot
MIT License
41 stars 11 forks source link

Plugin Won't Work on latest OobaBooga (8/28) without Updating #33

Open Kinglord opened 1 year ago

Kinglord commented 1 year ago

UPDATE:

I was able to get the plugin working by following the install directions and then re-updating Ooba which replaced some of the files. The output made me think it would not work but so far, things seem to be ok. So for now if you want the plugin to work you need to follow the instructions but then make sure to run the update script (if using 1-click installers) and then things should work!


Hello,

I followed the instructions and got everything installed on the most recent version of oobabooga as of 8/28.

Unfortunately, the plugin UI is totally unresponsive (the tab is there and content displayed) and breaks all dropdowns in ooba. I cannot seem to save the Bot Token (there's no feedback at all and when I reload and open the token menu it's blank) and the character drop down does not display anything (none of my characters, doesn't even open a dropdown). Hitting the Save Settings button also does nothing with no error, but I assume that's because it's not saving/including required fields like the token and the character.

I don't have any other extensions running, just the api and listen flags.

I had to re-update ooba to get it working again and I found this output that might be the cause:

oobabot-plugin 0.2.2 requires fastapi<0.100.0,>=0.99.1, but you have fastapi 0.95.2 which is incompatible.
oobabot-plugin 0.2.2 requires gradio<3.35.0,>=3.34.0, but you have gradio 3.33.1 which is incompatible.

I'll include the server output for an error that happens when I try to interact with the Character setting dropdown it seems to be some exception with a dataset key? There's no output error when I hit the save button on the bot token, so can't help anymore on that one.

2023-08-28 11:39:13,436 DEBUG oobabot_plugin: inside Oobabooga, using script.py version: 0.1.8
2023-08-28 11:39:13,436 DEBUG oobabot_plugin version: 0.2.2
2023-08-28 11:39:13,436 DEBUG oobabot version: 0.2.1
Running on local URL:  http://0.0.0.0:7860

To create a public link, set `share=True` in `launch()`.
ERROR:    Exception in ASGI application

Traceback (most recent call last):
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 408, in run_asgi
    result = await app(  # type: ignore[func-returns-value]
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/fastapi/applications.py", line 290, in __call__
    await super().__call__(scope, receive, send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in __call__
    raise exc
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/middleware/cors.py", line 83, in __call__
    await self.app(scope, receive, send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in __call__
    raise exc
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 20, in __call__
    raise e
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 17, in __call__
    await self.app(scope, receive, send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle
    await self.app(scope, receive, send)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/routing.py", line 66, in app
    response = await func(request)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/fastapi/routing.py", line 241, in app
    raw_response = await run_endpoint_function(
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/fastapi/routing.py", line 169, in run_endpoint_function
    return await run_in_threadpool(dependant.call, **values)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool
    return await anyio.to_thread.run_sync(func, *args)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread
    return await future
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run
    result = context.run(func, *args)
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/gradio/routes.py", line 289, in api_info
    return gradio.blocks.get_api_info(config, serialize)  # type: ignore
  File "/Users/deich/AI/oobabooga/installer_files/env/lib/python3.10/site-packages/gradio/blocks.py", line 568, in get_api_info
    serializer = serializing.COMPONENT_MAPPING[type]()
KeyError: 'dataset'
chrisrude commented 1 year ago

Thanks for the update! This issue is fixed in main, but not yet in a release. I'll cut a release in the next few days to spread it more broadly.