@xuda.io/ai_module 1.1.4921 → 1.1.4922
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.mjs +5 -13
- package/index_ms.mjs +2 -2
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -5970,19 +5970,11 @@ export const pin_ai_agent = async function (req, job_id, headers) {
|
|
|
5970
5970
|
|
|
5971
5971
|
const save_ret = await db_module.save_app_couch_doc(app_id, ai_agent_doc);
|
|
5972
5972
|
|
|
5973
|
-
|
|
5974
|
-
'
|
|
5975
|
-
|
|
5976
|
-
|
|
5977
|
-
|
|
5978
|
-
data: {
|
|
5979
|
-
service: 'ai_agent_pinned',
|
|
5980
|
-
to: [uid],
|
|
5981
|
-
data: await get_ai_agent_info(uid, job_id, headers, ai_agent_doc),
|
|
5982
|
-
},
|
|
5983
|
-
}),
|
|
5984
|
-
),
|
|
5985
|
-
);
|
|
5973
|
+
ws_dashboard_ms.emit_message_to_dashboard({
|
|
5974
|
+
service: 'ai_agent_pinned',
|
|
5975
|
+
to: [uid],
|
|
5976
|
+
data: await get_ai_agent_info(uid, job_id, headers, ai_agent_doc),
|
|
5977
|
+
});
|
|
5986
5978
|
return save_ret;
|
|
5987
5979
|
} catch (err) {
|
|
5988
5980
|
return {
|
package/index_ms.mjs
CHANGED
|
@@ -46,7 +46,7 @@ const send_to_queue =async function(ms_method, ...args) {
|
|
|
46
46
|
const timeout = setTimeout(() => {
|
|
47
47
|
delete queue[queue_id];
|
|
48
48
|
reject(new Error(`Queue timeout for ${ms_method}`));
|
|
49
|
-
},
|
|
49
|
+
}, 300000); // 300 second timeout
|
|
50
50
|
|
|
51
51
|
// Wrap resolve to clean up
|
|
52
52
|
queue[queue_id].resolve = (value) => {
|
|
@@ -74,7 +74,7 @@ const send_to_queue =async function(ms_method, ...args) {
|
|
|
74
74
|
})
|
|
75
75
|
)
|
|
76
76
|
);
|
|
77
|
-
|
|
77
|
+
|
|
78
78
|
}catch(err){
|
|
79
79
|
debugger
|
|
80
80
|
}
|