Skip to content

Commit

Permalink
fix: only install AlbyHub when running a LND node
Browse files Browse the repository at this point in the history
  • Loading branch information
fusion44 committed Dec 18, 2024
1 parent 81608cd commit 1127b60
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions app/apps/impl/raspiblitz.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,9 +161,13 @@ async def get_app_status(self):
continue
if appID == "thunderhub":
continue
if appID == "albyhub":
continue
elif node_type == "cln_grpc":
if appID == "thunderhub":
continue
if appID == "albyhub":
continue
# elif node_type="lnd_grpc":

# get status (installed, etc) and append
Expand Down Expand Up @@ -194,7 +198,13 @@ async def install_app_sub(self, app_id: str):
if app_id not in available_app_ids:
raise HTTPException(
status.HTTP_400_BAD_REQUEST,
detail=app_id + "install script does not exist / is not supported",
detail=app_id + " install script does not exist / is not supported",
)

if node_type == "cln_grpc" and (app_id == "thunderhub" or app_id == "albyhub"):
raise HTTPException(
status.HTTP_400_BAD_REQUEST,
detail=app_id + " not available for Core Lightning nodes",
)

await broadcast_sse_msg(
Expand Down Expand Up @@ -308,7 +318,7 @@ async def run_bonus_script(self, app_id: str, params: str):
updatedAppData = await self.get_app_status_single(app_id)

# in case of script error
if updatedAppData["error"] != "":
if "error" in updatedAppData and updatedAppData["error"] != "":
logging.warning("Error Detected ...")
logging.warning(f"updatedAppData: {updatedAppData}")
await broadcast_sse_msg(
Expand Down

0 comments on commit 1127b60

Please sign in to comment.