Skip to content

Commit

Permalink
FIX app_status query for mlflow view (#291)
Browse files Browse the repository at this point in the history
Signed-off-by: Nikita Churikov <nikita@chur.ru>
  • Loading branch information
churnikov authored Feb 27, 2025
1 parent 6346293 commit 65d9947
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions apps/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

from .app_registry import APP_REGISTRY
from .helpers import create_instance_from_form
from .models import BaseAppInstance
from .tasks import delete_resource

logger = get_logger(__name__)
Expand Down Expand Up @@ -313,10 +314,10 @@ class SecretsView(View):
template = "apps/secrets_view.html"

def get(self, request, project, app_slug, app_id):
instance = APP_REGISTRY.get_orm_model(app_slug).objects.get(pk=app_id)
instance: BaseAppInstance = APP_REGISTRY.get_orm_model(app_slug).objects.get(pk=app_id)

username, password = None, None
if instance.app_status.status == "Running":
if instance.get_app_status() == "Running":
subdomain = instance.subdomain
username = subprocess.run(
(
Expand Down

0 comments on commit 65d9947

Please sign in to comment.