MCPcopy Create free account
hub / github.com/Loping151/RoverSign / select_cookie

Method select_cookie

RoverSign/utils/database/models.py:79–93  ·  view source on GitHub ↗
(
        cls: Type[T_WavesUser],
        session: AsyncSession,
        uid: str,
        user_id: str,
        bot_id: str,
    )

Source from the content-addressed store, hash-verified

77 @classmethod
78 @with_session
79 async def select_cookie(
80 cls: Type[T_WavesUser],
81 session: AsyncSession,
82 uid: str,
83 user_id: str,
84 bot_id: str,
85 ) -> Optional[str]:
86 sql = select(cls).where(
87 cls.user_id == user_id,
88 cls.uid == uid,
89 cls.bot_id == bot_id,
90 )
91 result = await session.execute(sql)
92 data = result.scalars().all()
93 return data[0].cookie if data else None
94
95 @classmethod
96 @with_session

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected