Skip to content

Commit 0b1a29b

Browse files
authored
Remove references to local app admin view (#14306)
The local app '/admin' route is being removed because it does not provide any value, so we need to remove references from it in the CLI.
1 parent 8662ab2 commit 0b1a29b

File tree

3 files changed

+2
-4
lines changed

3 files changed

+2
-4
lines changed

src/lightning_app/cli/lightning_cli.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
from lightning_app.cli.lightning_cli_create import create
1717
from lightning_app.cli.lightning_cli_delete import delete
1818
from lightning_app.cli.lightning_cli_list import get_list
19-
from lightning_app.core.constants import get_lightning_cloud_url, LOCAL_LAUNCH_ADMIN_VIEW
19+
from lightning_app.core.constants import get_lightning_cloud_url
2020
from lightning_app.runners.runtime import dispatch
2121
from lightning_app.runners.runtime_type import RuntimeType
2222
from lightning_app.utilities.app_logs import _app_logs_reader
@@ -38,7 +38,7 @@ def get_app_url(runtime_type: RuntimeType, *args) -> str:
3838
lightning_app = args[0]
3939
return f"{get_lightning_cloud_url()}/me/apps/{lightning_app.id}"
4040
else:
41-
return "http://127.0.0.1:7501/admin" if LOCAL_LAUNCH_ADMIN_VIEW else "http://127.0.0.1:7501/view"
41+
return "http://127.0.0.1:7501/view"
4242

4343

4444
def main():

src/lightning_app/core/constants.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
USER_ID = os.getenv("USER_ID", "1234")
2424
FRONTEND_DIR = os.path.join(os.path.dirname(lightning_app.__file__), "ui")
2525
PACKAGE_LIGHTNING = os.getenv("PACKAGE_LIGHTNING", None)
26-
LOCAL_LAUNCH_ADMIN_VIEW = bool(int(os.getenv("LOCAL_LAUNCH_ADMIN_VIEW", "0")))
2726
CLOUD_UPLOAD_WARNING = int(os.getenv("CLOUD_UPLOAD_WARNING", "2"))
2827
DISABLE_DEPENDENCY_CACHE = bool(int(os.getenv("DISABLE_DEPENDENCY_CACHE", "0")))
2928
# Project under which the resources need to run in cloud. If this env is not set,

tests/tests_app/core/test_lightning_api.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,6 @@ async def test_health_endpoint_failure():
337337
("/", 200),
338338
("/asdf", 200),
339339
("/view/component_a", 200),
340-
("/admin", 200),
341340
),
342341
)
343342
@pytest.mark.anyio

0 commit comments

Comments
 (0)