@tostudy-ai/cli 0.17.2 → 0.17.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.
package/dist/cli.js CHANGED
@@ -41,7 +41,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
41
41
  mod
42
42
  ));
43
43
 
44
- // ../../node_modules/@parisgroup-ai/logger/dist/sanitize-DSkXy3jL.mjs
44
+ // ../../node_modules/@parisgroup-ai/logger/dist/sanitize-Cu_Xsxno.mjs
45
45
  function isSensitiveKey(key) {
46
46
  if (matchesSensitiveField(key)) return true;
47
47
  return matchesPluralOfSensitiveField(key);
@@ -149,8 +149,8 @@ function sanitizeEntryData(obj, additionalSensitiveKeys, includeStack, redactMas
149
149
  });
150
150
  }
151
151
  var SENSITIVE_FIELDS;
152
- var init_sanitize_DSkXy3jL = __esm({
153
- "../../node_modules/@parisgroup-ai/logger/dist/sanitize-DSkXy3jL.mjs"() {
152
+ var init_sanitize_Cu_Xsxno = __esm({
153
+ "../../node_modules/@parisgroup-ai/logger/dist/sanitize-Cu_Xsxno.mjs"() {
154
154
  SENSITIVE_FIELDS = [
155
155
  "password",
156
156
  "senha",
@@ -281,7 +281,7 @@ var require_picocolors = __commonJS({
281
281
  }
282
282
  });
283
283
 
284
- // ../../node_modules/@parisgroup-ai/logger/dist/logger.base-Bznav79x.mjs
284
+ // ../../node_modules/@parisgroup-ai/logger/dist/logger.base-DkCKo9Cu.mjs
285
285
  function formatJson(entry) {
286
286
  const { timestamp, level, message, service, environment, context, data, error: error49 } = entry;
287
287
  const output3 = {
@@ -385,9 +385,9 @@ function extractErrorInfo(error49, includeStack, visited = /* @__PURE__ */ new W
385
385
  return info;
386
386
  }
387
387
  var import_picocolors, LOG_LEVELS, LEVEL_COLORS, LEVEL_WIDTH, BaseLogger;
388
- var init_logger_base_Bznav79x = __esm({
389
- "../../node_modules/@parisgroup-ai/logger/dist/logger.base-Bznav79x.mjs"() {
390
- init_sanitize_DSkXy3jL();
388
+ var init_logger_base_DkCKo9Cu = __esm({
389
+ "../../node_modules/@parisgroup-ai/logger/dist/logger.base-DkCKo9Cu.mjs"() {
390
+ init_sanitize_Cu_Xsxno();
391
391
  import_picocolors = __toESM(require_picocolors(), 1);
392
392
  LOG_LEVELS = {
393
393
  trace: 0,
@@ -708,8 +708,8 @@ function createLogger(module, options) {
708
708
  var asyncLocalStorage, ConsoleTransport, FileTransport, HttpTransport, SINGLETON_KEY$1, SEVERITY, OtlpLogsTransport, SINGLETON_KEY, Logger, logger;
709
709
  var init_dist = __esm({
710
710
  "../../node_modules/@parisgroup-ai/logger/dist/index.mjs"() {
711
- init_logger_base_Bznav79x();
712
- init_sanitize_DSkXy3jL();
711
+ init_logger_base_DkCKo9Cu();
712
+ init_sanitize_Cu_Xsxno();
713
713
  asyncLocalStorage = new AsyncLocalStorage();
714
714
  ConsoleTransport = class {
715
715
  log(entry, formatted) {
@@ -770,6 +770,7 @@ var init_dist = __esm({
770
770
  this.flush().catch(() => {
771
771
  });
772
772
  }, this.flushInterval);
773
+ this.timer.unref();
773
774
  process.once("beforeExit", () => this.dispose());
774
775
  process.once("SIGTERM", () => this.dispose());
775
776
  }
@@ -864,6 +865,7 @@ var init_dist = __esm({
864
865
  this.flush().catch(() => {
865
866
  });
866
867
  }, this.flushInterval);
868
+ this.timer.unref();
867
869
  process.once("beforeExit", () => this.dispose());
868
870
  process.once("SIGTERM", () => this.dispose());
869
871
  }
@@ -2991,19 +2993,17 @@ async function writeWorkspaceMarker(workspacePath, input2, options = {}) {
2991
2993
  const existing = await readWorkspaceMarker(workspacePath);
2992
2994
  const now = (/* @__PURE__ */ new Date()).toISOString();
2993
2995
  let carried = {};
2994
- if (existing && existing.courseId === input2.courseId) {
2996
+ if (existing) {
2995
2997
  try {
2996
2998
  const raw = JSON.parse(readFileSync2(filePath, "utf-8"));
2997
- for (const key of [
2998
- "currentLessonId",
2999
- "currentModuleId",
3000
- "courseTags",
3001
- "courseLevel",
3002
- "lastInitCourseId",
3003
- "templateVersion"
3004
- ]) {
2999
+ for (const key of ["lastInitCourseId", "templateVersion"]) {
3005
3000
  if (raw[key] !== void 0) carried[key] = raw[key];
3006
3001
  }
3002
+ if (existing.courseId === input2.courseId) {
3003
+ for (const key of ["currentLessonId", "currentModuleId", "courseTags", "courseLevel"]) {
3004
+ if (raw[key] !== void 0) carried[key] = raw[key];
3005
+ }
3006
+ }
3007
3007
  } catch {
3008
3008
  carried = {};
3009
3009
  }
@@ -3531,7 +3531,7 @@ var CLI_VERSION;
3531
3531
  var init_version = __esm({
3532
3532
  "src/version.ts"() {
3533
3533
  "use strict";
3534
- CLI_VERSION = true ? "0.17.2" : "0.7.1";
3534
+ CLI_VERSION = true ? "0.17.3" : "0.7.1";
3535
3535
  }
3536
3536
  });
3537
3537