rentabots-sdk 1.7.31 → 1.7.32

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/dist/index.js CHANGED
@@ -71,7 +71,7 @@ exports.MessageSchema = zod_1.z.object({
71
71
  })
72
72
  });
73
73
  // --- CORE SDK ENGINE ---
74
- let SDK_VERSION = '1.7.31'; // fallback when package.json is unavailable
74
+ let SDK_VERSION = '1.7.32'; // fallback when package.json is unavailable
75
75
  try {
76
76
  const pkg = JSON.parse(fs.readFileSync(path.join(__dirname, '..', 'package.json'), 'utf8'));
77
77
  SDK_VERSION = pkg.version;
package/init.js CHANGED
@@ -209,9 +209,13 @@ async function main() {
209
209
  queen.on('message', async (msg) => {
210
210
  if (msg.sender.type === 'agent') return;
211
211
 
212
- const job = queen.activeMissions.get(msg.jobId);
212
+ let job = queen.activeMissions.get(msg.jobId);
213
213
  if (!job) {
214
- await queen.sendMessage(msg.jobId, "🤖 Supervisor online. Mission sync in progress.");
214
+ try { if (typeof queen.syncFromCloud === 'function') await queen.syncFromCloud(); } catch (_) {}
215
+ job = queen.activeMissions.get(msg.jobId);
216
+ }
217
+ if (!job) {
218
+ await queen.sendMessage(msg.jobId, "🤖 Got your message. I am re-syncing mission state now and will resume as soon as assignment is visible.");
215
219
  await pushLog('WARN', 'Message received for unknown mission ' + msg.jobId);
216
220
  return;
217
221
  }
@@ -513,7 +517,8 @@ async function main() {
513
517
 
514
518
  if (issues.length > 0) {
515
519
  await agent.setProgress(job.id, 70);
516
- if (RELAXED_MODE) {
520
+ const blockingIssues = issues.filter(i => i.includes('expected at least one .py') || i.includes('missing contract deliverable'));
521
+ if (RELAXED_MODE && blockingIssues.length === 0) {
517
522
  await agent.sendMessage(job.id, '⚠️ Soft QA warnings: ' + issues.slice(0, 3).join('; ') + '. Continuing with OpenClaw output in relaxed mode.');
518
523
  } else {
519
524
  await agent.sendMessage(job.id, '⚠️ Contract QA failed: ' + issues.slice(0, 4).join('; ') + '. Running targeted OpenClaw repair pass now.');
package/init_templates.js CHANGED
@@ -178,9 +178,13 @@ async function main() {
178
178
  queen.on('message', async (msg) => {
179
179
  if (msg.sender.type === 'agent') return;
180
180
 
181
- const job = queen.activeMissions.get(msg.jobId);
181
+ let job = queen.activeMissions.get(msg.jobId);
182
182
  if (!job) {
183
- await queen.sendMessage(msg.jobId, "🤖 Supervisor online. Mission sync in progress.");
183
+ try { if (typeof queen.syncFromCloud === 'function') await queen.syncFromCloud(); } catch (_) {}
184
+ job = queen.activeMissions.get(msg.jobId);
185
+ }
186
+ if (!job) {
187
+ await queen.sendMessage(msg.jobId, "🤖 Got your message. I am re-syncing mission state now and will resume as soon as assignment is visible.");
184
188
  await pushLog('WARN', 'Message received for unknown mission ' + msg.jobId);
185
189
  return;
186
190
  }
@@ -498,7 +502,8 @@ async function main() {
498
502
 
499
503
  if (issues.length > 0) {
500
504
  await agent.setProgress(job.id, 70);
501
- if (RELAXED_MODE) {
505
+ const blockingIssues = issues.filter(i => i.includes('expected at least one .py') || i.includes('missing contract deliverable'));
506
+ if (RELAXED_MODE && blockingIssues.length === 0) {
502
507
  await agent.sendMessage(job.id, '⚠️ Soft QA warnings: ' + issues.slice(0, 3).join('; ') + '. Continuing with OpenClaw output in relaxed mode.');
503
508
  } else {
504
509
  await agent.sendMessage(job.id, '⚠️ Contract QA failed: ' + issues.slice(0, 4).join('; ') + '. Running targeted OpenClaw repair pass now.');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rentabots-sdk",
3
- "version": "1.7.31",
3
+ "version": "1.7.32",
4
4
  "description": "Official SDK for RentaBots AI Agent Marketplace",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",