skypilot-nightly 1.0.0.dev20250607__py3-none-any.whl → 1.0.0.dev20250609__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- sky/__init__.py +2 -2
- sky/backends/backend_utils.py +18 -2
- sky/check.py +4 -3
- sky/cli.py +5 -6
- sky/client/cli.py +5 -6
- sky/core.py +3 -2
- sky/dashboard/out/404.html +1 -1
- sky/dashboard/out/_next/static/chunks/470-680c19413b8f808b.js +1 -0
- sky/dashboard/out/_next/static/chunks/{614-635a84e87800f99e.js → 63-e2d7b1e75e67c713.js} +8 -8
- sky/dashboard/out/_next/static/chunks/843-16c7194621b2b512.js +11 -0
- sky/dashboard/out/_next/static/chunks/pages/clusters/[cluster]/{[job]-18aed9b56247d074.js → [job]-d31688d3e52736dd.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/clusters/{[cluster]-b919a73aecdfa78f.js → [cluster]-e7d8710a9b0491e5.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/{clusters-4f6b9dd9abcb33ad.js → clusters-3c674e5d970e05cb.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/config-3aac7a015c6eede1.js +6 -0
- sky/dashboard/out/_next/static/chunks/pages/infra/{[context]-3a18d0eeb5119fe4.js → [context]-46d2e4ad6c487260.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/{infra-a1a6abeeb58c1051.js → infra-7013d816a2a0e76c.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/jobs/{[job]-1354e28c81eeb686.js → [job]-f7f0c9e156d328bc.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/{jobs-23bfc8bf373423db.js → jobs-87e60396c376292f.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/users-9355a0f13d1db61d.js +16 -0
- sky/dashboard/out/_next/static/chunks/pages/workspace/{new-e1f9c0c3ff7ac4bd.js → new-9a749cca1813bd27.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/workspaces/{[name]-686590e0ee4b2412.js → [name]-8eeb628e03902f1b.js} +1 -1
- sky/dashboard/out/_next/static/chunks/pages/workspaces-8fbcc5ab4af316d0.js +1 -0
- sky/dashboard/out/_next/static/css/8b1c8321d4c02372.css +3 -0
- sky/dashboard/out/_next/static/xos0euNCptbGAM7_Q3Acl/_buildManifest.js +1 -0
- sky/dashboard/out/clusters/[cluster]/[job].html +1 -1
- sky/dashboard/out/clusters/[cluster].html +1 -1
- sky/dashboard/out/clusters.html +1 -1
- sky/dashboard/out/config.html +1 -1
- sky/dashboard/out/index.html +1 -1
- sky/dashboard/out/infra/[context].html +1 -1
- sky/dashboard/out/infra.html +1 -1
- sky/dashboard/out/jobs/[job].html +1 -1
- sky/dashboard/out/jobs.html +1 -1
- sky/dashboard/out/users.html +1 -1
- sky/dashboard/out/workspace/new.html +1 -1
- sky/dashboard/out/workspaces/[name].html +1 -1
- sky/dashboard/out/workspaces.html +1 -1
- sky/exceptions.py +5 -0
- sky/global_user_state.py +11 -6
- sky/jobs/server/core.py +9 -1
- sky/jobs/server/server.py +0 -95
- sky/jobs/utils.py +2 -1
- sky/models.py +18 -0
- sky/serve/server/core.py +1 -1
- sky/server/common.py +4 -2
- sky/server/constants.py +0 -2
- sky/server/requests/executor.py +10 -2
- sky/server/requests/requests.py +4 -3
- sky/server/server.py +22 -5
- sky/skylet/constants.py +3 -0
- sky/skylet/job_lib.py +2 -1
- sky/skypilot_config.py +9 -0
- sky/users/model.conf +1 -1
- sky/users/permission.py +148 -31
- sky/users/rbac.py +26 -0
- sky/users/server.py +14 -13
- sky/utils/common.py +6 -1
- sky/utils/common_utils.py +21 -3
- sky/utils/schemas.py +9 -0
- sky/workspaces/core.py +100 -8
- sky/workspaces/server.py +15 -2
- sky/workspaces/utils.py +56 -0
- {skypilot_nightly-1.0.0.dev20250607.dist-info → skypilot_nightly-1.0.0.dev20250609.dist-info}/METADATA +1 -1
- {skypilot_nightly-1.0.0.dev20250607.dist-info → skypilot_nightly-1.0.0.dev20250609.dist-info}/RECORD +72 -71
- sky/dashboard/out/_next/static/1qG0HTmVilJPxQdBk0fX5/_buildManifest.js +0 -1
- sky/dashboard/out/_next/static/chunks/470-ad1e0db3afcbd9c9.js +0 -1
- sky/dashboard/out/_next/static/chunks/843-c296541442d4af88.js +0 -11
- sky/dashboard/out/_next/static/chunks/pages/config-fe375a56342cf609.js +0 -6
- sky/dashboard/out/_next/static/chunks/pages/users-5800045bd04e69c2.js +0 -16
- sky/dashboard/out/_next/static/chunks/pages/workspaces-76b07aa5da91b0df.js +0 -1
- sky/dashboard/out/_next/static/css/667d941a2888ce6e.css +0 -3
- /sky/dashboard/out/_next/static/chunks/{856-3a32da4b84176f6d.js → 856-affc52adf5403a3a.js} +0 -0
- /sky/dashboard/out/_next/static/chunks/{973-6d78a0814682d771.js → 973-aed916d5b02d2d63.js} +0 -0
- /sky/dashboard/out/_next/static/chunks/pages/{_app-cb81dc4d27f4d009.js → _app-5f16aba5794ee8e7.js} +0 -0
- /sky/dashboard/out/_next/static/{1qG0HTmVilJPxQdBk0fX5 → xos0euNCptbGAM7_Q3Acl}/_ssgManifest.js +0 -0
- {skypilot_nightly-1.0.0.dev20250607.dist-info → skypilot_nightly-1.0.0.dev20250609.dist-info}/WHEEL +0 -0
- {skypilot_nightly-1.0.0.dev20250607.dist-info → skypilot_nightly-1.0.0.dev20250609.dist-info}/entry_points.txt +0 -0
- {skypilot_nightly-1.0.0.dev20250607.dist-info → skypilot_nightly-1.0.0.dev20250609.dist-info}/licenses/LICENSE +0 -0
- {skypilot_nightly-1.0.0.dev20250607.dist-info → skypilot_nightly-1.0.0.dev20250609.dist-info}/top_level.txt +0 -0
sky/__init__.py
CHANGED
@@ -5,7 +5,7 @@ from typing import Optional
|
|
5
5
|
import urllib.request
|
6
6
|
|
7
7
|
# Replaced with the current commit when building the wheels.
|
8
|
-
_SKYPILOT_COMMIT_SHA = '
|
8
|
+
_SKYPILOT_COMMIT_SHA = 'a2f62cdbc1e7e0e9f9f7f38e01271b040e0ec2f2'
|
9
9
|
|
10
10
|
|
11
11
|
def _get_git_commit():
|
@@ -35,7 +35,7 @@ def _get_git_commit():
|
|
35
35
|
|
36
36
|
|
37
37
|
__commit__ = _get_git_commit()
|
38
|
-
__version__ = '1.0.0.
|
38
|
+
__version__ = '1.0.0.dev20250609'
|
39
39
|
__root_dir__ = os.path.dirname(os.path.abspath(__file__))
|
40
40
|
|
41
41
|
|
sky/backends/backend_utils.py
CHANGED
@@ -51,6 +51,7 @@ from sky.utils import status_lib
|
|
51
51
|
from sky.utils import subprocess_utils
|
52
52
|
from sky.utils import timeline
|
53
53
|
from sky.utils import ux_utils
|
54
|
+
from sky.workspaces import core as workspaces_core
|
54
55
|
|
55
56
|
if typing.TYPE_CHECKING:
|
56
57
|
import requests
|
@@ -2570,19 +2571,34 @@ def get_clusters(
|
|
2570
2571
|
public clouds only, and 'local' for only local clouds.
|
2571
2572
|
cluster_names: If provided, only return records for the given cluster
|
2572
2573
|
names.
|
2574
|
+
all_users: If True, return clusters from all users. If False, only
|
2575
|
+
return clusters from the current user.
|
2573
2576
|
|
2574
2577
|
Returns:
|
2575
2578
|
A list of cluster records. If the cluster does not exist or has been
|
2576
2579
|
terminated, the record will be omitted from the returned list.
|
2577
2580
|
"""
|
2578
2581
|
records = global_user_state.get_clusters()
|
2582
|
+
current_user = common_utils.get_current_user()
|
2583
|
+
|
2584
|
+
# Filter by user if requested
|
2579
2585
|
if not all_users:
|
2580
|
-
current_user_hash = common_utils.get_user_hash()
|
2581
2586
|
records = [
|
2582
2587
|
record for record in records
|
2583
|
-
if record['user_hash'] ==
|
2588
|
+
if record['user_hash'] == current_user.id
|
2584
2589
|
]
|
2585
2590
|
|
2591
|
+
accessible_workspaces = workspaces_core.get_workspaces()
|
2592
|
+
|
2593
|
+
workspace_filtered_records = []
|
2594
|
+
for record in records:
|
2595
|
+
cluster_workspace = record.get('workspace',
|
2596
|
+
constants.SKYPILOT_DEFAULT_WORKSPACE)
|
2597
|
+
if cluster_workspace in accessible_workspaces:
|
2598
|
+
workspace_filtered_records.append(record)
|
2599
|
+
|
2600
|
+
records = workspace_filtered_records
|
2601
|
+
|
2586
2602
|
yellow = colorama.Fore.YELLOW
|
2587
2603
|
bright = colorama.Style.BRIGHT
|
2588
2604
|
reset = colorama.Style.RESET_ALL
|
sky/check.py
CHANGED
@@ -340,18 +340,19 @@ def get_cached_enabled_clouds_or_refresh(
|
|
340
340
|
exceptions.NoCloudAccessError: if no public cloud is enabled and
|
341
341
|
raise_if_no_cloud_access is set to True.
|
342
342
|
"""
|
343
|
+
active_workspace = skypilot_config.get_active_workspace()
|
343
344
|
cached_enabled_clouds = global_user_state.get_cached_enabled_clouds(
|
344
|
-
capability,
|
345
|
+
capability, active_workspace)
|
345
346
|
if not cached_enabled_clouds:
|
346
347
|
try:
|
347
|
-
check_capability(capability, quiet=True)
|
348
|
+
check_capability(capability, quiet=True, workspace=active_workspace)
|
348
349
|
except SystemExit:
|
349
350
|
# If no cloud is enabled, check() will raise SystemExit.
|
350
351
|
# Here we catch it and raise the exception later only if
|
351
352
|
# raise_if_no_cloud_access is set to True.
|
352
353
|
pass
|
353
354
|
cached_enabled_clouds = global_user_state.get_cached_enabled_clouds(
|
354
|
-
capability,
|
355
|
+
capability, active_workspace)
|
355
356
|
if raise_if_no_cloud_access and not cached_enabled_clouds:
|
356
357
|
with ux_utils.print_exception_no_traceback():
|
357
358
|
raise exceptions.NoCloudAccessError(
|
sky/cli.py
CHANGED
@@ -28,7 +28,6 @@ import copy
|
|
28
28
|
import datetime
|
29
29
|
import fnmatch
|
30
30
|
import functools
|
31
|
-
import getpass
|
32
31
|
import os
|
33
32
|
import pathlib
|
34
33
|
import shlex
|
@@ -6243,18 +6242,18 @@ def api_info():
|
|
6243
6242
|
"""Shows the SkyPilot API server URL."""
|
6244
6243
|
url = server_common.get_server_url()
|
6245
6244
|
api_server_info = sdk.api_info()
|
6246
|
-
user_name = os.getenv(constants.USER_ENV_VAR, getpass.getuser())
|
6247
|
-
user_hash = common_utils.get_user_hash()
|
6248
6245
|
api_server_user = api_server_info.get('user')
|
6249
6246
|
if api_server_user is not None:
|
6250
|
-
|
6251
|
-
|
6247
|
+
user = models.User(id=api_server_user['id'],
|
6248
|
+
name=api_server_user['name'])
|
6249
|
+
else:
|
6250
|
+
user = models.User.get_current_user()
|
6252
6251
|
dashboard_url = server_common.get_dashboard_url(url)
|
6253
6252
|
click.echo(f'Using SkyPilot API server: {url}\n'
|
6254
6253
|
f'{ux_utils.INDENT_SYMBOL}Status: {api_server_info["status"]}, '
|
6255
6254
|
f'commit: {api_server_info["commit"]}, '
|
6256
6255
|
f'version: {api_server_info["version"]}\n'
|
6257
|
-
f'{ux_utils.INDENT_SYMBOL}User: {
|
6256
|
+
f'{ux_utils.INDENT_SYMBOL}User: {user.name} ({user.id})\n'
|
6258
6257
|
f'{ux_utils.INDENT_LAST_SYMBOL}Dashboard: {dashboard_url}')
|
6259
6258
|
|
6260
6259
|
|
sky/client/cli.py
CHANGED
@@ -28,7 +28,6 @@ import copy
|
|
28
28
|
import datetime
|
29
29
|
import fnmatch
|
30
30
|
import functools
|
31
|
-
import getpass
|
32
31
|
import os
|
33
32
|
import pathlib
|
34
33
|
import shlex
|
@@ -6243,18 +6242,18 @@ def api_info():
|
|
6243
6242
|
"""Shows the SkyPilot API server URL."""
|
6244
6243
|
url = server_common.get_server_url()
|
6245
6244
|
api_server_info = sdk.api_info()
|
6246
|
-
user_name = os.getenv(constants.USER_ENV_VAR, getpass.getuser())
|
6247
|
-
user_hash = common_utils.get_user_hash()
|
6248
6245
|
api_server_user = api_server_info.get('user')
|
6249
6246
|
if api_server_user is not None:
|
6250
|
-
|
6251
|
-
|
6247
|
+
user = models.User(id=api_server_user['id'],
|
6248
|
+
name=api_server_user['name'])
|
6249
|
+
else:
|
6250
|
+
user = models.User.get_current_user()
|
6252
6251
|
dashboard_url = server_common.get_dashboard_url(url)
|
6253
6252
|
click.echo(f'Using SkyPilot API server: {url}\n'
|
6254
6253
|
f'{ux_utils.INDENT_SYMBOL}Status: {api_server_info["status"]}, '
|
6255
6254
|
f'commit: {api_server_info["commit"]}, '
|
6256
6255
|
f'version: {api_server_info["version"]}\n'
|
6257
|
-
f'{ux_utils.INDENT_SYMBOL}User: {
|
6256
|
+
f'{ux_utils.INDENT_SYMBOL}User: {user.name} ({user.id})\n'
|
6258
6257
|
f'{ux_utils.INDENT_LAST_SYMBOL}Dashboard: {dashboard_url}')
|
6259
6258
|
|
6260
6259
|
|
sky/core.py
CHANGED
@@ -711,9 +711,10 @@ def queue(cluster_name: str,
|
|
711
711
|
exceptions.CommandError: if failed to get the job queue with ssh.
|
712
712
|
"""
|
713
713
|
all_jobs = not skip_finished
|
714
|
-
user_hash: Optional[str] = common_utils.get_user_hash()
|
715
714
|
if all_users:
|
716
715
|
user_hash = None
|
716
|
+
else:
|
717
|
+
user_hash = common_utils.get_current_user().id
|
717
718
|
code = job_lib.JobLibCodeGen.get_job_queue(user_hash, all_jobs)
|
718
719
|
|
719
720
|
handle = backend_utils.check_cluster_available(
|
@@ -829,7 +830,7 @@ def cancel(
|
|
829
830
|
backend.cancel_jobs(handle,
|
830
831
|
job_ids,
|
831
832
|
cancel_all=all or all_users,
|
832
|
-
user_hash=common_utils.
|
833
|
+
user_hash=common_utils.get_current_user().id)
|
833
834
|
|
834
835
|
|
835
836
|
@usage_lib.entrypoint
|
sky/dashboard/out/404.html
CHANGED
@@ -1 +1 @@
|
|
1
|
-
<!DOCTYPE html><html><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width"/><title>404: This page could not be found</title><meta name="next-head-count" content="3"/><link rel="preload" href="/dashboard/_next/static/css/
|
1
|
+
<!DOCTYPE html><html><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width"/><title>404: This page could not be found</title><meta name="next-head-count" content="3"/><link rel="preload" href="/dashboard/_next/static/css/8b1c8321d4c02372.css" as="style"/><link rel="stylesheet" href="/dashboard/_next/static/css/8b1c8321d4c02372.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/dashboard/_next/static/chunks/polyfills-78c92fac7aa8fdd8.js"></script><script src="/dashboard/_next/static/chunks/webpack-65d465f948974c0d.js" defer=""></script><script src="/dashboard/_next/static/chunks/framework-87d061ee6ed71b28.js" defer=""></script><script src="/dashboard/_next/static/chunks/main-e0e2335212e72357.js" defer=""></script><script src="/dashboard/_next/static/chunks/pages/_app-5f16aba5794ee8e7.js" defer=""></script><script src="/dashboard/_next/static/chunks/pages/_error-1be831200e60c5c0.js" defer=""></script><script src="/dashboard/_next/static/xos0euNCptbGAM7_Q3Acl/_buildManifest.js" defer=""></script><script src="/dashboard/_next/static/xos0euNCptbGAM7_Q3Acl/_ssgManifest.js" defer=""></script></head><body><div id="__next"><div style="font-family:system-ui,"Segoe UI",Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div style="line-height:48px"><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding-right:23px;font-size:24px;font-weight:500;vertical-align:top">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:28px">This page could not be found<!-- -->.</h2></div></div></div></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"statusCode":404}},"page":"/_error","query":{},"buildId":"xos0euNCptbGAM7_Q3Acl","assetPrefix":"/dashboard","nextExport":true,"isFallback":false,"gip":true,"scriptLoader":[]}</script></body></html>
|
@@ -0,0 +1 @@
|
|
1
|
+
"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[470],{3850:function(e,t,n){n.d(t,{E9:function(){return w},J$:function(){return l},PC:function(){return x},Ps:function(){return i},QT:function(){return u},Vp:function(){return h},W2:function(){return a},Ye:function(){return c},aD:function(){return j},fp:function(){return d},fy:function(){return m},h0:function(){return f},mU:function(){return g},oy:function(){return y},r7:function(){return p}});var r=n(5893);n(7294);var s=n(8507),o=n(8586);function i(e){return(0,r.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"currentColor",stroke:"currentColor",strokeWidth:"0",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"})})}function a(e){return(0,r.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"currentColor",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("circle",{cx:"10",cy:"10",r:"8"})})}function l(e){return(0,r.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("circle",{cx:"10",cy:"10",r:"8"})})}function c(e){return(0,r.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"5",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M6 12l4 4 8-8"})})}function d(e){return(0,r.jsxs)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"currentColor",stroke:"currentColor",strokeWidth:"0",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("rect",{x:"6",y:"5",width:"4",height:"14",rx:"1"}),(0,r.jsx)("rect",{x:"14",y:"5",width:"4",height:"14",rx:"1"})]})}function u(e){return(0,r.jsxs)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2"}),(0,r.jsx)("rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2"}),(0,r.jsx)("line",{x1:"6",x2:"6.01",y1:"6",y2:"6"}),(0,r.jsx)("line",{x1:"6",x2:"6.01",y1:"18",y2:"18"})]})}function h(e){return(0,r.jsxs)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("path",{d:"M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"}),(0,r.jsx)("rect",{width:"20",height:"14",x:"2",y:"6",rx:"2"})]})}function x(e){return(0,r.jsxs)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",ry:"2"}),(0,r.jsx)("rect",{x:"9",y:"9",width:"6",height:"6"}),(0,r.jsx)("line",{x1:"9",y1:"1",x2:"9",y2:"4"}),(0,r.jsx)("line",{x1:"15",y1:"1",x2:"15",y2:"4"}),(0,r.jsx)("line",{x1:"9",y1:"20",x2:"9",y2:"23"}),(0,r.jsx)("line",{x1:"15",y1:"20",x2:"15",y2:"23"}),(0,r.jsx)("line",{x1:"20",y1:"9",x2:"23",y2:"9"}),(0,r.jsx)("line",{x1:"20",y1:"14",x2:"23",y2:"14"}),(0,r.jsx)("line",{x1:"1",y1:"9",x2:"4",y2:"9"}),(0,r.jsx)("line",{x1:"1",y1:"14",x2:"4",y2:"14"})]})}function f(e){return(0,r.jsxs)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"}),(0,r.jsx)("polyline",{points:"15 3 21 3 21 9"}),(0,r.jsx)("line",{x1:"10",y1:"14",x2:"21",y2:"3"})]})}function m(e){return(0,r.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"currentColor",children:(0,r.jsx)("path",{d:"M12 0c-6.626 0-12 5.373-12 12 0 5.302 3.438 9.8 8.207 11.387.599.111.793-.261.793-.577v-2.234c-3.338.726-4.033-1.416-4.033-1.416-.546-1.387-1.333-1.756-1.333-1.756-1.089-.745.083-.729.083-.729 1.205.084 1.839 1.237 1.839 1.237 1.07 1.834 2.807 1.304 3.492.997.107-.775.418-1.305.762-1.604-2.665-.305-5.467-1.334-5.467-5.931 0-1.311.469-2.381 1.236-3.221-.124-.303-.535-1.524.117-3.176 0 0 1.008-.322 3.301 1.23.957-.266 1.983-.399 3.003-.404 1.02.005 2.047.138 3.006.404 2.291-1.552 3.297-1.23 3.297-1.23.653 1.653.242 2.874.118 3.176.77.84 1.235 1.911 1.235 3.221 0 4.609-2.807 5.624-5.479 5.921.43.372.823 1.102.823 2.222v3.293c0 .319.192.694.801.576 4.765-1.589 8.199-6.086 8.199-11.386 0-6.627-5.373-12-12-12z"})})}function p(e){return(0,r.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"})})}function g(e){return(0,r.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"currentColor",children:(0,r.jsx)("path",{transform:"scale(0.85) translate(1.8, 1.8)",d:"M5.042 15.165a2.528 2.528 0 0 1-2.52 2.523A2.528 2.528 0 0 1 0 15.165a2.527 2.527 0 0 1 2.522-2.52h2.52v2.52zM6.313 15.165a2.527 2.527 0 0 1 2.521-2.52 2.527 2.527 0 0 1 2.521 2.52v6.313A2.528 2.528 0 0 1 8.834 24a2.528 2.528 0 0 1-2.521-2.522v-6.313zM8.834 5.042a2.528 2.528 0 0 1-2.521-2.52A2.528 2.528 0 0 1 8.834 0a2.528 2.528 0 0 1 2.521 2.522v2.52H8.834zM8.834 6.313a2.528 2.528 0 0 1 2.521 2.521 2.528 2.528 0 0 1-2.521 2.521H2.522A2.528 2.528 0 0 1 0 8.834a2.528 2.528 0 0 1 2.522-2.521h6.312zM18.956 8.834a2.528 2.528 0 0 1 2.522-2.521A2.528 2.528 0 0 1 24 8.834a2.528 2.528 0 0 1-2.522 2.521h-2.522V8.834zM17.688 8.834a2.528 2.528 0 0 1-2.523 2.521 2.527 2.527 0 0 1-2.52-2.521V2.522A2.527 2.527 0 0 1 15.165 0a2.528 2.528 0 0 1 2.523 2.522v6.312zM15.165 18.956a2.528 2.528 0 0 1 2.523 2.522A2.528 2.528 0 0 1 15.165 24a2.527 2.527 0 0 1-2.52-2.522v-2.522h2.52zM15.165 17.688a2.527 2.527 0 0 1-2.52-2.523 2.526 2.526 0 0 1 2.52-2.52h6.313A2.527 2.527 0 0 1 24 15.165a2.528 2.528 0 0 1-2.522 2.523h-6.313z"})})}function w(e){return(0,r.jsx)("svg",{...e,stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsxs)("g",{children:[(0,r.jsx)("path",{fill:"none",d:"M0 0h24v24H0z"}),(0,r.jsx)("path",{d:"M3 18.5V5a3 3 0 0 1 3-3h14a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5A3.5 3.5 0 0 1 3 18.5zM19 20v-3H6.5a1.5 1.5 0 0 0 0 3H19zM10 4H6a1 1 0 0 0-1 1v10.337A3.486 3.486 0 0 1 6.5 15H19V4h-2v8l-3.5-2-3.5 2V4z"})]})})}let j=s.Z,y=o.Z},9470:function(e,t,n){n.d(t,{A:function(){return y}});var r=n(5893),s=n(7294),o=n(5675),i=n.n(o),a=n(1163),l=n(1664),c=n.n(l),d=n(3850),u=n(355),h=n(6021),x=n(3225),f=n(6989),m=n(3001);let p=(0,s.createContext)(null);function g(e){let{children:t}=e,[n,o]=(0,s.useState)(!0),[i,a]=(0,s.useState)(null),[l,c]=(0,s.useState)(null);return(0,s.useEffect)(()=>{fetch("".concat(x.f4,"/api/health")).then(e=>e.json()).then(e=>{e.user&&e.user.name&&(a(e.user.name),(async()=>{try{let e=await fetch("".concat(x.f4,"/users/role"));if(e.ok){let t=await e.json();t.role&&c(t.role)}}catch(e){console.log("Could not fetch user role:",e)}})())}).catch(e=>{console.error("Error fetching user data:",e)})},[]),(0,r.jsx)(p.Provider,{value:{isSidebarOpen:n,toggleSidebar:()=>{o(e=>!e)},userEmail:i,userRole:l},children:t})}function w(){let e,t;let n=(0,a.useRouter)(),o=(0,m.X)(),{userEmail:l,userRole:g}=function(){let e=(0,s.useContext)(p);if(!e)throw Error("useSidebar must be used within a SidebarProvider");return e}(),[w,j]=(0,s.useState)(!1),y=(0,s.useRef)(null);(0,s.useEffect)(()=>{function e(e){y.current&&!y.current.contains(e.target)&&j(!1)}return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[y]);let v=e=>"/workspaces"===e?n.pathname.startsWith("/workspaces")||n.pathname.startsWith("/workspace"):n.pathname.startsWith(e),b=e=>{let t=v(e);return"inline-flex items-center border-b-2 ".concat(t?"border-transparent text-blue-600":"border-transparent hover:text-blue-600"," ").concat(o?"px-2 py-1":"px-1 pt-1 space-x-2")};return(0,r.jsx)("div",{className:"fixed top-0 left-0 right-0 bg-white z-30 h-14 px-4 border-b border-gray-200 shadow-sm",children:(0,r.jsxs)("div",{className:"flex items-center h-full",children:[(0,r.jsx)("div",{className:"flex items-center ".concat(o?"space-x-2 mr-2":"space-x-4 mr-6"),children:(0,r.jsx)(c(),{href:"/",className:"flex items-center px-1 pt-1 h-full",prefetch:!1,children:(0,r.jsx)("div",{className:"h-20 w-20 flex items-center justify-center",children:(0,r.jsx)(i(),{src:"".concat(x.GW,"/skypilot.svg"),alt:"SkyPilot Logo",width:80,height:80,priority:!0,className:"w-full h-full object-contain"})})})}),(0,r.jsxs)("div",{className:"flex items-center ".concat(o?"space-x-1":"space-x-2 md:space-x-4"," ").concat(o?"mr-2":"mr-6"),children:[(0,r.jsxs)(c(),{href:"/clusters",className:b("/clusters"),prefetch:!1,children:[(0,r.jsx)(d.QT,{className:"w-4 h-4"}),!o&&(0,r.jsx)("span",{children:"Clusters"})]}),(0,r.jsxs)(c(),{href:"/jobs",className:b("/jobs"),prefetch:!1,children:[(0,r.jsx)(d.Vp,{className:"w-4 h-4"}),!o&&(0,r.jsx)("span",{children:"Jobs"})]}),(0,r.jsx)("div",{className:"border-l border-gray-200 h-6 mx-1"}),(0,r.jsxs)(c(),{href:"/infra",className:b("/infra"),prefetch:!1,children:[(0,r.jsx)(d.PC,{className:"w-4 h-4"}),!o&&(0,r.jsx)("span",{children:"Infra"})]}),(0,r.jsxs)(c(),{href:"/workspaces",className:b("/workspaces"),prefetch:!1,children:[(0,r.jsx)(d.E9,{className:"w-4 h-4"}),!o&&(0,r.jsx)("span",{children:"Workspaces"})]}),(0,r.jsxs)(c(),{href:"/users",className:b("/users"),prefetch:!1,children:[(0,r.jsx)(d.oy,{className:"w-4 h-4"}),!o&&(0,r.jsx)("span",{children:"Users"})]})]}),(0,r.jsxs)("div",{className:"flex items-center space-x-1 ".concat(o?"ml-0":"ml-auto"),children:[(0,r.jsx)(f.WH,{content:"Documentation",className:"text-sm text-muted-foreground",children:(0,r.jsxs)("a",{href:"https://skypilot.readthedocs.io/en/latest/",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center px-2 py-1 text-gray-600 hover:text-blue-600 transition-colors duration-150 cursor-pointer",title:"Docs",children:[!o&&(0,r.jsx)("span",{className:"mr-1",children:"Docs"}),(0,r.jsx)(d.h0,{className:"".concat(o?"w-4 h-4":"w-3.5 h-3.5")})]})}),(0,r.jsx)(f.WH,{content:"GitHub Repository",className:"text-sm text-muted-foreground",children:(0,r.jsx)("a",{href:"https://github.com/skypilot-org/skypilot",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center justify-center p-2 rounded-full text-gray-600 hover:bg-gray-100 transition-colors duration-150 cursor-pointer",title:"GitHub",children:(0,r.jsx)(d.fy,{className:"".concat(o?"w-4 h-4":"w-5 h-5")})})}),(0,r.jsx)(f.WH,{content:"Join Slack",className:"text-sm text-muted-foreground",children:(0,r.jsx)("a",{href:"https://slack.skypilot.co/",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center justify-center p-2 rounded-full text-gray-600 hover:bg-gray-100 transition-colors duration-150 cursor-pointer",title:"Slack",children:(0,r.jsx)(d.mU,{className:"".concat(o?"w-4 h-4":"w-5 h-5")})})}),(0,r.jsx)(f.WH,{content:"Leave Feedback",className:"text-sm text-muted-foreground",children:(0,r.jsx)("a",{href:"https://github.com/skypilot-org/skypilot/issues/new",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center justify-center p-2 rounded-full text-gray-600 hover:bg-gray-100 transition-colors duration-150 cursor-pointer",title:"Leave Feedback",children:(0,r.jsx)(d.aD,{className:"".concat(o?"w-4 h-4":"w-5 h-5")})})}),(0,r.jsx)("div",{className:"border-l border-gray-200 h-6"}),(0,r.jsx)(f.WH,{content:"Configuration",className:"text-sm text-muted-foreground",children:(0,r.jsx)(c(),{href:"/config",className:"inline-flex items-center justify-center p-2 rounded-full transition-colors duration-150 cursor-pointer ".concat(v("/config")?"text-blue-600 hover:bg-gray-100":"text-gray-600 hover:bg-gray-100"),title:"Configuration",prefetch:!1,children:(0,r.jsx)(u.Z,{className:"".concat(o?"w-4 h-4":"w-5 h-5")})})}),l&&(0,r.jsxs)("div",{className:"relative",ref:y,children:[(0,r.jsx)("button",{onClick:()=>j(!w),className:"inline-flex items-center justify-center rounded-full transition-colors duration-150 cursor-pointer hover:ring-2 hover:ring-blue-200",title:"User Profile",children:(0,r.jsx)("div",{className:"".concat(o?"w-6 h-6":"w-7 h-7"," bg-blue-600 text-white rounded-full flex items-center justify-center font-medium ").concat(o?"text-xs":"text-sm"," hover:bg-blue-700 transition-colors"),children:l?l.includes("@")?l.split("@")[0].charAt(0).toUpperCase():l.charAt(0).toUpperCase():"?"})}),w&&(0,r.jsxs)("div",{className:"absolute right-0 mt-2 w-48 bg-white rounded-md shadow-lg z-50 border border-gray-200",children:[(e=l,t=null,l&&l.includes("@")&&(e=l.split("@")[0],t=l),(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("div",{className:"px-4 pt-2 pb-1 text-sm font-medium text-gray-900",children:e}),t&&(0,r.jsx)("div",{className:"px-4 pt-0 pb-1 text-xs text-gray-500",children:t}),g&&(0,r.jsx)("div",{className:"px-4 pt-0 pb-2 text-xs",children:"admin"===g?(0,r.jsxs)("span",{className:"inline-flex items-center text-blue-600",children:[(0,r.jsx)(d.r7,{className:"w-3 h-3 mr-1"}),"Admin"]}):(0,r.jsxs)("span",{className:"inline-flex items-center text-gray-600",children:[(0,r.jsx)(h.Z,{className:"w-3 h-3 mr-1"}),"User"]})})]})),(0,r.jsx)("div",{className:"border-t border-gray-200 mx-1 my-1"}),(0,r.jsx)(c(),{href:"/users",className:"block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 hover:text-blue-600",onClick:()=>j(!1),prefetch:!1,children:"See all users"})]})]})]})]})})}function j(e){let{children:t,highlighted:n}=e;return(0,m.X)(),(0,r.jsxs)("div",{className:"min-h-screen bg-gray-50",children:[(0,r.jsx)("div",{className:"fixed top-0 left-0 right-0 z-50 shadow-sm",children:(0,r.jsx)(w,{})}),(0,r.jsx)("div",{className:"transition-all duration-200 ease-in-out min-h-screen",style:{paddingTop:"56px"},children:(0,r.jsx)("main",{className:"p-6",children:t})})]})}function y(e){return(0,r.jsx)(g,{children:(0,r.jsx)(j,{...e})})}},8950:function(e,t,n){n.d(t,{Bw:function(){return m},Ph:function(){return d},Ql:function(){return p},i4:function(){return h},ki:function(){return u}});var r=n(5893),s=n(7294),o=n(2067),i=n(5895),a=n(7242),l=n(282),c=n(2350);let d=o.fC;o.ZA;let u=o.B4,h=s.forwardRef((e,t)=>{let{className:n,children:s,...a}=e;return(0,r.jsxs)(o.xz,{ref:t,className:(0,c.cn)("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",n),...a,children:[s,(0,r.jsx)(o.JO,{asChild:!0,children:(0,r.jsx)(i.Z,{className:"h-4 w-4 opacity-50"})})]})});h.displayName=o.xz.displayName;let x=s.forwardRef((e,t)=>{let{className:n,...s}=e;return(0,r.jsx)(o.u_,{ref:t,className:(0,c.cn)("flex cursor-default items-center justify-center py-1",n),...s,children:(0,r.jsx)(a.Z,{className:"h-4 w-4"})})});x.displayName=o.u_.displayName;let f=s.forwardRef((e,t)=>{let{className:n,...s}=e;return(0,r.jsx)(o.$G,{ref:t,className:(0,c.cn)("flex cursor-default items-center justify-center py-1",n),...s,children:(0,r.jsx)(i.Z,{className:"h-4 w-4"})})});f.displayName=o.$G.displayName;let m=s.forwardRef((e,t)=>{let{className:n,children:s,position:i="popper",...a}=e;return(0,r.jsx)(o.h_,{children:(0,r.jsxs)(o.VY,{ref:t,className:(0,c.cn)("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2","popper"===i&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",n),position:i,...a,children:[(0,r.jsx)(x,{}),(0,r.jsx)(o.l_,{className:(0,c.cn)("p-1","popper"===i&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:s}),(0,r.jsx)(f,{})]})})});m.displayName=o.VY.displayName,s.forwardRef((e,t)=>{let{className:n,...s}=e;return(0,r.jsx)(o.__,{ref:t,className:(0,c.cn)("py-1.5 pl-8 pr-2 text-sm font-semibold",n),...s})}).displayName=o.__.displayName;let p=s.forwardRef((e,t)=>{let{className:n,children:s,...i}=e;return(0,r.jsxs)(o.ck,{ref:t,className:(0,c.cn)("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",n),...i,children:[(0,r.jsx)("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:(0,r.jsx)(o.wU,{children:(0,r.jsx)(l.Z,{className:"h-4 w-4"})})}),(0,r.jsx)(o.eT,{children:s})]})});p.displayName=o.ck.displayName,s.forwardRef((e,t)=>{let{className:n,...s}=e;return(0,r.jsx)(o.Z0,{ref:t,className:(0,c.cn)("-mx-1 my-1 h-px bg-muted",n),...s})}).displayName=o.Z0.displayName},6989:function(e,t,n){n.d(t,{$B:function(){return g},GV:function(){return d},LU:function(){return m},Md:function(){return f},WH:function(){return x},o0:function(){return u},q8:function(){return p},yc:function(){return l}});var r=n(5893),s=n(7294),o=n(3302),i=n(1886),a=n(8950);let l=n(1214).nb.REFRESH_INTERVAL;function c(e){return e.charAt(0).toUpperCase()+e.slice(1)}function d(e){if(!e)return"N/A";let t=new Date;if(!(7>Math.abs((t-e)/864e5)))return(0,r.jsx)(x,{content:c(u(e)),className:"text-sm text-muted-foreground",children:c(e.toLocaleString("en-CA",{year:"numeric",month:"2-digit",day:"2-digit"}).replace(",",""))});{let n=function(e){if(!e||"string"!=typeof e)return e;if("just now"===e)return"now";let t=e.match(/^about\s+(\d+)\s+(\w+)\s+ago$/i);if(t){let e=t[1],n=t[2],r={second:"s",seconds:"s",minute:"m",minutes:"m",hour:"h",hours:"h",day:"d",days:"d",month:"mo",months:"mo",year:"yr",years:"yr"};if(r[n])return"".concat(e).concat(r[n]," ago")}let n=e.match(/^a[n]?\s+(\w+)\s+ago$/i);if(n){let e=n[1],t={second:"s",minute:"m",hour:"h",day:"d",month:"mo",year:"yr"};if(t[e])return"1".concat(t[e]," ago")}let r=e.match(/^(\d+)\s+(\w+)\s+ago$/i);if(r){let e=r[1],t=r[2],n={second:"s",seconds:"s",minute:"m",minutes:"m",hour:"h",hours:"h",day:"d",days:"d",month:"mo",months:"mo",year:"yr",years:"yr"};if(n[t])return"".concat(e).concat(n[t]," ago")}return e}((0,i.B)(e,t,{addSuffix:!0}));return(0,r.jsx)(x,{content:u(e),className:"capitalize text-sm text-muted-foreground",children:n})}}function u(e){return e.toLocaleString("en-CA",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1,timeZoneName:"short"}).replace(",","")}let h={placement:"bottom",color:"default"},x=e=>{let{children:t,...n}=e,s=n.content;return n.content=void 0,(0,r.jsx)(o.e,{...h,...n,content:(0,r.jsx)("span",{className:"left-full w-max px-2 py-1 text-sm text-gray-100 bg-gray-500 text-sm capitalize rounded",children:s}),children:t})},f=e=>{let{children:t,...n}=e,s=n.content;return n.content=void 0,(0,r.jsx)(o.e,{...h,...n,content:(0,r.jsx)("span",{className:"left-full w-max px-2 py-1 text-sm text-gray-100 bg-gray-500 text-sm rounded",children:s}),children:t})};function m(e){if(!e&&0!==e)return"-";let t=e=Math.floor(e),n="",r=0;for(let e of[{value:86400,label:"d"},{value:3600,label:"h"},{value:60,label:"m"},{value:1,label:"s"}])if(t>=e.value&&r<2){let s=Math.floor(t/e.value);n+="".concat(s).concat(e.label," "),t%=e.value,r++}return n.trim()||"0s"}function p(e){return e?(e=e.split("\n").filter(e=>!e.match(/<rich_.*?\[bold cyan\]/)&&!e.match(/<rich_.*>.*<\/rich_.*>/)&&!e.match(/├──/)&&!e.match(/└──/)).join("\n").replace(/\x1b\[([0-9]{1,2}(;[0-9]{1,2})?)?[mGKH]/g,"")).split("\n").map(e=>{let t=e.match(/^([IWED])\s+(\d{2}-\d{2}\s+\d{2}:\d{2}:\d{2})\s+([^:]+:\d+\])(.*)/);if(t){let[e,n,r,s,o]=t,i={I:"INFO",W:"WARNING",E:"ERROR",D:"DEBUG"}[n]||"";return'<span class="log-line '.concat(i,'"><span class="level">').concat(n,'</span><span class="timestamp">').concat(r,'</span><span class="location">').concat(s,'</span><span class="message">').concat(o,"</span></span>")}let n=e.match(/^(\([^)]+\))(.*)$/);if(n){let[e,t,r]=n;return'<span class="log-line"><span class="log-prefix">'.concat(t,'</span><span class="log-rest">').concat(r,"</span></span>")}return'<span class="log-line"><span class="message">'.concat(e,"</span></span>")}).join("\n"):""}function g(e){let{logs:t,controller:n=!1}=e,[o,i]=(0,s.useState)("all"),[l,c]=(0,s.useState)(t),[d,u]=(0,s.useState)([]);return(0,s.useEffect)(()=>{u(function(e){let t;let n=/\((head|worker\d+),/g,r=new Set;for(;null!==(t=n.exec(e));)r.add(t[1]);return Array.from(r).sort((e,t)=>"head"===e?-1:"head"===t?1:e.localeCompare(t,void 0,{numeric:!0,sensitivity:"base"}))}(t))},[t]),(0,s.useEffect)(()=>{"all"===o?c(t):c(t.split("\n").filter(e=>e.includes("(".concat(o,","))).join("\n"))},[o,t]),(0,r.jsxs)("div",{children:[(0,r.jsx)("style",{children:'\n .logs-container {\n background-color: #f7f7f7;\n padding: 16px;\n max-height: calc(100vh - 300px);\n overflow-y: auto;\n overflow-x: hidden;\n font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;\n line-height: 1.5;\n border-radius: 6px;\n min-height: fit-content;\n }\n\n .log-line {\n display: block;\n white-space: pre-wrap;\n margin: 2px 0;\n }\n\n .log-line .level {\n display: inline;\n width: 1ch;\n margin-right: 1ch;\n font-weight: bold;\n }\n\n .log-line.INFO .level {\n color: #2563eb;\n }\n\n .log-line.WARNING .level {\n color: #d97706;\n }\n\n .log-line.ERROR .level {\n color: #dc2626;\n }\n\n .log-line.DEBUG .level {\n color: #6b7280;\n }\n\n .log-line .timestamp {\n color: #059669;\n margin-right: 1ch;\n white-space: nowrap;\n }\n\n .log-line .location {\n color: #6366f1;\n margin-right: 1ch;\n white-space: nowrap;\n }\n\n .log-line .message {\n color: #111827;\n word-break: break-word;\n white-space: pre-wrap;\n }\n\n .log-line .log-prefix {\n color: #6366f1;\n font-weight: 500;\n }\n\n .log-line .log-rest {\n color: #111827;\n word-break: break-word;\n white-space: pre-wrap;\n }\n'}),!n&&(0,r.jsx)("div",{style:{marginBottom:"1rem"},children:(0,r.jsxs)(a.Ph,{onValueChange:e=>i(e),value:o,children:[(0,r.jsx)(a.i4,{"aria-label":"Node",className:"focus:ring-0 focus:ring-offset-0",children:(0,r.jsx)(a.ki,{placeholder:"Select Node"})}),(0,r.jsxs)(a.Bw,{children:[(0,r.jsx)(a.Ql,{value:"all",children:"All Nodes"}),d.map(e=>(0,r.jsx)(a.Ql,{value:e,children:e},e))]})]})}),(0,r.jsx)("div",{className:"logs-container",dangerouslySetInnerHTML:{__html:l}})]})}},3001:function(e,t,n){n.d(t,{X:function(){return s}});var r=n(7294);function s(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:768,[t,n]=(0,r.useState)(!1);return(0,r.useEffect)(()=>{let t=()=>{n(window.innerWidth<e)};return t(),window.addEventListener("resize",t),()=>{window.removeEventListener("resize",t)}},[e]),t}},1214:function(e,t,n){n.d(t,{MO:function(){return o},ej:function(){return r},nb:function(){return s}});let r={DEFAULT_TTL:12e4},s={REFRESH_INTERVAL:3e4,GPU_REFRESH_INTERVAL:3e4},o={NAME_TRUNCATE_LENGTH:20}},2350:function(e,t,n){n.d(t,{cn:function(){return o}});var r=n(512),s=n(8388);function o(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,s.m6)((0,r.W)(t))}}}]);
|