The command exited with code 0. Output: 1726: async def _poll_invite_approval(self, ws: Workspace, ref: str, invite_hash: str) -> None: 1727- user_id = ws.user_id 1728- max_attempts = 18 # 18 * 10s = 3 minutes 1729- for attempt in range(max_attempts): 1730- await asyncio.sleep(10) 1731- try: 1732- invite = await self.main_client.invoke(CheckChatInvite(hash=invite_hash)) 1733- if isinstance(invite, ChatInviteAlready): 1734- chat = invite.chat 1735- chat_id = self._canonical_chat_id(chat.id, getattr(chat, "type", None)) 1736- group_name = self._group_key_from_chat(chat) 1737- 1738- ws = self.load_workspace(user_id) 1739- group_name = self._unique_group_name(ws, group_name, chat_id) 1740- 1741- ws.saved_groups[group_name] = chat_id 1742- ws.group_id = chat_id 1743- self.save_workspace(ws) 1744- 1745- await self.send( 1746- user_id, 1747- fmt_msg("Group Approved & Added", f"āœ… **Request Approved!**\n\nšŸ“” **Name:** `{group_name}`\nšŸ†” **ID:** `{chat_id}`", success=True), 1748- keyboard=self._workspace_menu(ws), 1749- ) 1750- return 1751- except Exception as exc: 1752- log(f"[poll invite] Error checking invite {invite_hash} for {user_id}: {exc}") 1753- 1754- ws = self.load_workspace(user_id) 1755- await self.send( 1756- user_id, 1757- fmt_msg( 1758- "Approval Timeout", 1759- "ā± **Join Request Timeout**\n\nAdmin didn't approve the request within 3 minutes.\nOnce they approve it, simply add the group again using the same link.", 1760- error=True 1761- ), 1762- keyboard=self._workspace_menu(ws), 1763- ) 1764- 1765- async def _resolve_and_save_group(self, ws: Workspace, raw_ref: str, must_be_link: bool = False) -> bool: 1766- user_id = ws.user_id 1767- ref = raw_ref.strip() 1768- 1769- if not ref: 1770- await self.send(user_id, fmt_msg("Invalid Input", "Send an invite link, @username, or group/channel ID.", error=True), keyboard=reply_kb(BACK_KB)) 1771- return False 1772- 1773- if not self.main_client_ready: 1774- await self.send(user_id, fmt_msg("Session Not Ready", "Main Telegram session is not ready yet. Please wait.", error=True), keyboard=reply_kb(BACK_KB)) 1775- return False 1776-