containers / podman-desktop-extension-ai-lab

Work with LLMs on a local environment using containers
https://podman-desktop.io/extensions/ai-lab
Apache License 2.0
181 stars 41 forks source link

fix(MessageProxy): timeout channels list #2036

Closed axel7083 closed 3 weeks ago

axel7083 commented 3 weeks ago

What does this PR do?

Following https://github.com/containers/podman-desktop-extension-ai-lab/pull/1838, the noTimeoutChannels was not working anymore. It is an hardcoded list of channels that should not have a timeout. However we now prefix the channel for each api with the class CHANNEL property.

To avoid having ${StudioAPI.CHANNEL}-openDialog I added a getChannel method, taking a class, a keyof this class, to ensure typescript prevent us from adding invalid channels.

Screenshot / video of UI

N/A

What issues does this PR fix or reference?

Fixes https://github.com/containers/podman-desktop-extension-ai-lab/issues/1991

How to test this PR?

Manually

  1. Go to models liste page
  2. Click on import (top right corner)
  3. Wait 10 seconds
  4. assert no timeout