@promptbook/cli 0.82.0-2 → 0.82.0-3

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.
@@ -11,6 +11,7 @@ import { CLAIM } from '../config';
11
11
  import { LOGO_LIGHT_SRC } from '../config';
12
12
  import { LOGO_DARK_SRC } from '../config';
13
13
  import { DEFAULT_BOOK_TITLE } from '../config';
14
+ import { DEFAULT_TASK_TITLE } from '../config';
14
15
  import { MAX_FILENAME_LENGTH } from '../config';
15
16
  import { DEFAULT_INTERMEDIATE_FILES_STRATEGY } from '../config';
16
17
  import { DEFAULT_MAX_PARALLEL_COUNT } from '../config';
@@ -134,6 +135,7 @@ export { CLAIM };
134
135
  export { LOGO_LIGHT_SRC };
135
136
  export { LOGO_DARK_SRC };
136
137
  export { DEFAULT_BOOK_TITLE };
138
+ export { DEFAULT_TASK_TITLE };
137
139
  export { MAX_FILENAME_LENGTH };
138
140
  export { DEFAULT_INTERMEDIATE_FILES_STRATEGY };
139
141
  export { DEFAULT_MAX_PARALLEL_COUNT };
@@ -59,6 +59,12 @@ export declare const LOGO_DARK_SRC: string_url_image;
59
59
  * @public exported from `@promptbook/core`
60
60
  */
61
61
  export declare const DEFAULT_BOOK_TITLE = "\u2728 Untitled Book";
62
+ /**
63
+ * When the title of task is not provided, the default title is used
64
+ *
65
+ * @public exported from `@promptbook/core`
66
+ */
67
+ export declare const DEFAULT_TASK_TITLE = "Task";
62
68
  /**
63
69
  * Warning message for the generated sections and files files
64
70
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/cli",
3
- "version": "0.82.0-2",
3
+ "version": "0.82.0-3",
4
4
  "description": "It's time for a paradigm shift. The future of software in plain English, French or Latin",
5
5
  "--note-0": " <- [🐊]",
6
6
  "private": false,
package/umd/index.umd.js CHANGED
@@ -51,7 +51,7 @@
51
51
  * @generated
52
52
  * @see https://github.com/webgptorg/promptbook
53
53
  */
54
- var PROMPTBOOK_ENGINE_VERSION = '0.82.0-1';
54
+ var PROMPTBOOK_ENGINE_VERSION = '0.82.0-2';
55
55
  /**
56
56
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
57
57
  * Note: [💞] Ignore a discrepancy between file name and entity name
@@ -236,6 +236,12 @@
236
236
  * @public exported from `@promptbook/core`
237
237
  */
238
238
  var DEFAULT_BOOK_TITLE = "\u2728 Untitled Book";
239
+ /**
240
+ * When the title of task is not provided, the default title is used
241
+ *
242
+ * @public exported from `@promptbook/core`
243
+ */
244
+ var DEFAULT_TASK_TITLE = "Task";
239
245
  /**
240
246
  * Warning message for the generated sections and files files
241
247
  *
@@ -3905,11 +3911,17 @@
3905
3911
  * @public exported from `@promptbook/utils`
3906
3912
  */
3907
3913
  function deserializeError(error) {
3914
+ var name = error.name, stack = error.stack;
3915
+ var message = error.message;
3908
3916
  var ErrorClass = ALL_ERRORS[error.name];
3909
3917
  if (ErrorClass === undefined) {
3910
- return new Error("".concat(error.name, ": ").concat(error.message));
3918
+ ErrorClass = Error;
3919
+ message = "".concat(name, ": ").concat(message);
3920
+ }
3921
+ if (stack !== undefined && stack !== '') {
3922
+ message = spaceTrim__default["default"](function (block) { return "\n ".concat(block(message), "\n\n Original stack trace:\n ").concat(block(stack || ''), "\n "); });
3911
3923
  }
3912
- return new ErrorClass(error.message);
3924
+ return new ErrorClass(message);
3913
3925
  }
3914
3926
 
3915
3927
  /**
@@ -10067,8 +10079,8 @@
10067
10079
  isSectionTypeSet: false,
10068
10080
  isTask: true,
10069
10081
  taskType: undefined /* <- Note: [🍙] Putting here placeholder to keep `taskType` on top at final JSON */,
10070
- name: getUniqueSectionName(section.title),
10071
- title: section.title,
10082
+ name: getUniqueSectionName(section.title || DEFAULT_TASK_TITLE),
10083
+ title: section.title || DEFAULT_TASK_TITLE,
10072
10084
  description: description_1,
10073
10085
  content: content,
10074
10086
  // <- TODO: [🍙] Some standard order of properties