@fern-api/fern-api-dev 5.27.6 → 5.27.7

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/cli.cjs +10 -72
  2. package/package.json +1 -1
package/cli.cjs CHANGED
@@ -360342,9 +360342,9 @@ var require_diff3 = __commonJS({
360342
360342
  }
360343
360343
  });
360344
360344
 
360345
- // ../../../node_modules/.pnpm/@fern-api+replay@0.15.1/node_modules/@fern-api/replay/dist/index.cjs
360345
+ // ../../../node_modules/.pnpm/@fern-api+replay@0.15.2/node_modules/@fern-api/replay/dist/index.cjs
360346
360346
  var require_dist14 = __commonJS({
360347
- "../../../node_modules/.pnpm/@fern-api+replay@0.15.1/node_modules/@fern-api/replay/dist/index.cjs"(exports2, module4) {
360347
+ "../../../node_modules/.pnpm/@fern-api+replay@0.15.2/node_modules/@fern-api/replay/dist/index.cjs"(exports2, module4) {
360348
360348
  "use strict";
360349
360349
  var __defProp4 = Object.defineProperty;
360350
360350
  var __getOwnPropDesc4 = Object.getOwnPropertyDescriptor;
@@ -361269,7 +361269,7 @@ var require_dist14 = __commonJS({
361269
361269
  async detectPatchesInRange(rangeStart, lastGen, lock) {
361270
361270
  const log4 = await this.git.exec([
361271
361271
  "log",
361272
- "--first-parent",
361272
+ "--no-merges",
361273
361273
  "--format=%H%x00%an%x00%ae%x00%s",
361274
361274
  `${rangeStart}..HEAD`,
361275
361275
  "--",
@@ -361289,18 +361289,6 @@ var require_dist14 = __commonJS({
361289
361289
  continue;
361290
361290
  }
361291
361291
  const parents = await this.git.getCommitParents(commit.sha);
361292
- if (parents.length > 1) {
361293
- const compositePatch = await this.createMergeCompositePatch({
361294
- mergeCommit: commit,
361295
- firstParent: parents[0],
361296
- lastGen,
361297
- lock
361298
- });
361299
- if (compositePatch) {
361300
- newPatches.push(compositePatch);
361301
- }
361302
- continue;
361303
- }
361304
361292
  let patchContent;
361305
361293
  try {
361306
361294
  patchContent = await this.git.formatPatch(commit.sha);
@@ -361438,9 +361426,7 @@ var require_dist14 = __commonJS({
361438
361426
  * within the current linear detection window, and are absent from
361439
361427
  * HEAD at the end of the window.
361440
361428
  *
361441
- * Rationale: on a merge commit, createMergeCompositePatch already diffs
361442
- * firstParent..mergeCommit so net-zero files never enter the composite. On
361443
- * linear history each commit becomes its own patch, so a file that was
361429
+ * Rationale: each commit becomes its own patch, so a file that was
361444
361430
  * briefly added and later removed survives as a create+delete pair whose
361445
361431
  * cumulative diff is empty. We drop such patches before they reach the
361446
361432
  * lockfile.
@@ -361507,54 +361493,6 @@ var require_dist14 = __commonJS({
361507
361493
  return /* @__PURE__ */ new Set();
361508
361494
  }
361509
361495
  }
361510
- /**
361511
- * Create a single composite patch for a merge commit by diffing the merge
361512
- * commit against its first parent. This captures the net change of the
361513
- * entire merged branch as one patch, eliminating accumulator chaining and
361514
- * zero-net-change ghost conflicts.
361515
- */
361516
- async createMergeCompositePatch(input3) {
361517
- const { mergeCommit, firstParent, lastGen, lock } = input3;
361518
- const forgottenHashes = new Set(lock.forgotten_hashes ?? []);
361519
- const filesOutput = await this.git.exec([
361520
- "diff",
361521
- "--name-only",
361522
- firstParent,
361523
- mergeCommit.sha
361524
- ]);
361525
- const { files, sensitiveFiles } = filterInfrastructureAndSensitiveFiles(filesOutput);
361526
- if (sensitiveFiles.length > 0) {
361527
- this.warnings.push(
361528
- `Sensitive file(s) excluded from merge patch for commit ${mergeCommit.sha.slice(0, 7)}: ${sensitiveFiles.join(", ")}. These files will not be tracked by replay.`
361529
- );
361530
- }
361531
- if (files.length === 0) return null;
361532
- const diff2 = await this.git.exec([
361533
- "diff",
361534
- firstParent,
361535
- mergeCommit.sha,
361536
- "--",
361537
- ...files
361538
- ]);
361539
- if (!diff2.trim()) return null;
361540
- const contentHash = this.computeContentHash(diff2);
361541
- if (lock.patches.some((p14) => p14.content_hash === contentHash) || forgottenHashes.has(contentHash)) {
361542
- return null;
361543
- }
361544
- const theirsSnapshot = await capturePatchSnapshot(this.git, files, mergeCommit.sha);
361545
- return {
361546
- id: `patch-merge-${mergeCommit.sha.slice(0, 8)}`,
361547
- content_hash: contentHash,
361548
- original_commit: mergeCommit.sha,
361549
- original_message: mergeCommit.message,
361550
- original_author: `${mergeCommit.authorName} <${mergeCommit.authorEmail}>`,
361551
- base_generation: lastGen.commit_sha,
361552
- files,
361553
- patch_content: diff2,
361554
- ...Object.keys(theirsSnapshot).length > 0 ? { theirs_snapshot: theirsSnapshot } : {},
361555
- ...this.isCreationOnlyPatch(diff2) ? { user_owned: true } : {}
361556
- };
361557
- }
361558
361496
  /**
361559
361497
  * Detect patches via tree diff for non-linear history. Returns a composite patch.
361560
361498
  * Revert reconciliation is skipped here because tree-diff produces a single composite
@@ -668132,7 +668070,7 @@ var AccessTokenPosthogManager = class {
668132
668070
  properties: {
668133
668071
  ...event,
668134
668072
  ...event.properties,
668135
- version: "5.27.6",
668073
+ version: "5.27.7",
668136
668074
  usingAccessToken: true,
668137
668075
  ...getRunIdProperties()
668138
668076
  }
@@ -668196,7 +668134,7 @@ var UserPosthogManager = class {
668196
668134
  distinctId: this.userId ?? await this.getPersistedDistinctId(),
668197
668135
  event: "CLI",
668198
668136
  properties: {
668199
- version: "5.27.6",
668137
+ version: "5.27.7",
668200
668138
  ...event,
668201
668139
  ...event.properties,
668202
668140
  usingAccessToken: false,
@@ -859775,7 +859713,7 @@ var LOCAL_STORAGE_FOLDER4 = ".fern-dev";
859775
859713
  var LOGS_FOLDER_NAME = "logs";
859776
859714
  var MAX_LOGS_DIR_SIZE_BYTES = 100 * 1024 * 1024;
859777
859715
  function getCliSource() {
859778
- const version7 = "5.27.6";
859716
+ const version7 = "5.27.7";
859779
859717
  return `cli@${version7}`;
859780
859718
  }
859781
859719
  var DebugLogger = class {
@@ -873775,7 +873713,7 @@ var LegacyDocsPublisher = class {
873775
873713
  previewId,
873776
873714
  disableTemplates: void 0,
873777
873715
  skipUpload,
873778
- cliVersion: "5.27.6",
873716
+ cliVersion: "5.27.7",
873779
873717
  loginCommand: "fern auth login"
873780
873718
  });
873781
873719
  if (taskContext.getResult() === TaskResult.Failure) {
@@ -948180,7 +948118,7 @@ function getAutomationContextFromEnv() {
948180
948118
  config_branch: process.env.FERN_CONFIG_BRANCH,
948181
948119
  config_pr_number: process.env.FERN_CONFIG_PR_NUMBER,
948182
948120
  trigger: process.env.GITHUB_EVENT_NAME,
948183
- cli_version: "5.27.6"
948121
+ cli_version: "5.27.7"
948184
948122
  };
948185
948123
  }
948186
948124
  function isAutomationMode() {
@@ -949006,7 +948944,7 @@ var CliContext = class _CliContext {
949006
948944
  if (false) {
949007
948945
  this.logger.error("CLI_VERSION is not defined");
949008
948946
  }
949009
- return "5.27.6";
948947
+ return "5.27.7";
949010
948948
  }
949011
948949
  getCliName() {
949012
948950
  if (false) {
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "5.27.6",
2
+ "version": "5.27.7",
3
3
  "repository": {
4
4
  "type": "git",
5
5
  "url": "git+https://github.com/fern-api/fern.git",