Compare commits

..

3 Commits

Author SHA1 Message Date
e21c6a0aac bugfix 2025-08-06 14:39:35 +08:00
bbe8ac33fb Merge branch 'main' of git.opencomputing.cn:yumoqing/uapi 2025-08-06 14:36:46 +08:00
977a3b9b29 bugfix 2025-08-06 14:36:21 +08:00

View File

@ -67,7 +67,10 @@ class UAPI:
raise e
return None, None
apiset = apisets[0]
r recs = await sor.R('uapi', {'name':apiname, 'apisetid': upapp.apisetid})
recs = await sor.R('uapi', {
'name':apiname,
'apisetid': upapp.apisetid
})
if len(recs)==0:
return None, None
uapi = recs[0]
@ -97,8 +100,8 @@ r recs = await sor.R('uapi', {'name':apiname, 'apisetid': upapp.apisetid})
await self.do_auth(auth_uapi)
async for chunk in self.stream_resp(uapi):
yield chunk
t
async stream_linify(self, upappid, apiname, callerid, params={}):
async def stream_linify(self, upappid, apiname, callerid, params={}):
gen = liner(self.__call__(upappid, apiname, callerid, params=params))
async for line in gen:
yield line
@ -172,3 +175,5 @@ where a.id = b.upappid
'myappid': r.myappid
})
if __name__ == '__main__':
print('test')