@xuda.io/drive_module 1.1.1492 → 1.1.1493

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.
Files changed (2) hide show
  1. package/index.mjs +7 -0
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -2669,6 +2669,9 @@ export default {
2669
2669
 
2670
2670
  doc.vite_build_res = vite_build_res;
2671
2671
  doc.scriptData.dependencies = devDependencies;
2672
+ // build_error parity with the (former) blocking client flow: a clean build
2673
+ // clears any stale error so the editor stops flagging the doc.
2674
+ delete doc.build_error;
2672
2675
 
2673
2676
  db_module.save_app_couch_doc(app_id, doc);
2674
2677
  } catch (err) {
@@ -2680,6 +2683,10 @@ export default {
2680
2683
  src_hash: js_src_hash(doc.scriptData?.value || ''),
2681
2684
  data: err.message,
2682
2685
  };
2686
+ // Stamp build_error on the doc itself (same contract as save_prog): the
2687
+ // studio save flow no longer blocks on the build, so editors learn of
2688
+ // failures from this self-saved rev replicating back.
2689
+ doc.build_error = { message: err?.message || 'Compilation error', ts: Date.now() };
2683
2690
  console.error(doc._id, 'js compile failed:', String(err.message).slice(0, 300));
2684
2691
  if (job_id || req.return_result) {
2685
2692
  return doc.vite_build_res;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/drive_module",
3
- "version": "1.1.1492",
3
+ "version": "1.1.1493",
4
4
  "description": "Xuda Drive Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {