@ref0/git 0.8.0 → 0.10.0

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 (102) hide show
  1. package/dist/contracts/calls-spent.d.mts +2 -12
  2. package/dist/contracts/calls-spent.mjs +4 -5
  3. package/dist/contracts/commits.d.mts +14 -2
  4. package/dist/contracts/commits.mjs +22 -3
  5. package/dist/contracts/events.d.mts +70 -4
  6. package/dist/contracts/events.mjs +27 -3
  7. package/dist/contracts/git.d.mts +13 -3
  8. package/dist/contracts/objects.d.mts +18 -0
  9. package/dist/contracts/queue.d.mts +3 -2
  10. package/dist/contracts/queue.mjs +4 -2
  11. package/dist/contracts/refs.mjs +3 -1
  12. package/dist/core/ancestry.mjs +5 -4
  13. package/dist/core/events/seen.mjs +5 -4
  14. package/dist/core/index-job.mjs +23 -1
  15. package/dist/core/index-lost.d.mts +11 -0
  16. package/dist/core/index-lost.mjs +55 -0
  17. package/dist/core/job-view.mjs +20 -0
  18. package/dist/core/objects/commit-writes.mjs +1 -1
  19. package/dist/core/objects/commits.mjs +10 -9
  20. package/dist/core/objects/merges.mjs +1 -1
  21. package/dist/core/objects/reading.mjs +28 -13
  22. package/dist/core/objects/trees.mjs +1 -1
  23. package/dist/core/parts.d.mts +7 -0
  24. package/dist/core/publish.mjs +9 -5
  25. package/dist/core/purge.mjs +16 -3
  26. package/dist/core/push.mjs +27 -11
  27. package/dist/core/ref-view.mjs +1 -25
  28. package/dist/core/repack.mjs +36 -14
  29. package/dist/core/view.d.mts +10 -1
  30. package/dist/core/view.mjs +15 -6
  31. package/dist/core/work.mjs +47 -4
  32. package/dist/effect.d.mts +2 -3
  33. package/dist/effect.mjs +2 -3
  34. package/dist/engine/commits.mjs +4 -3
  35. package/dist/engine/merge-bases.mjs +5 -3
  36. package/dist/engine/merge.mjs +4 -3
  37. package/dist/engine/parts.d.mts +1 -0
  38. package/dist/engine/parts.mjs +1 -1
  39. package/dist/engine/walk.mjs +62 -20
  40. package/dist/http/core-parts.mjs +17 -8
  41. package/dist/index.d.mts +4 -4
  42. package/dist/index.mjs +3 -3
  43. package/dist/lfs/objects.mjs +7 -4
  44. package/dist/lfs/upkeep.mjs +6 -5
  45. package/dist/lfs/upload-most.mjs +8 -2
  46. package/dist/protocol/bytes/streams.mjs +84 -2
  47. package/dist/protocol/diff/read.d.mts +1 -0
  48. package/dist/protocol/diff/read.mjs +5 -2
  49. package/dist/protocol/objects/commit.d.mts +7 -0
  50. package/dist/protocol/objects/commit.mjs +5 -1
  51. package/dist/queue/advance.mjs +39 -10
  52. package/dist/queue/host.d.mts +4 -0
  53. package/dist/queue/layer.mjs +4 -2
  54. package/dist/queue/limits.mjs +18 -2
  55. package/dist/queue/rows.mjs +2 -1
  56. package/dist/queue/trim.mjs +2 -2
  57. package/dist/rest/commits.d.mts +202 -198
  58. package/dist/rest/forks.d.mts +99 -99
  59. package/dist/rest/refs.d.mts +144 -144
  60. package/dist/rest/repos.d.mts +48 -48
  61. package/dist/rest/topics.d.mts +112 -112
  62. package/dist/rest/trees.d.mts +58 -58
  63. package/dist/rest/wire.d.mts +19 -1
  64. package/dist/rest/work.d.mts +39 -39
  65. package/dist/server/joined.d.mts +11 -5
  66. package/dist/server/joined.mjs +3 -2
  67. package/dist/server/registry.mjs +11 -5
  68. package/dist/server/server.mjs +16 -4
  69. package/dist/storage/index-bitmaps.mjs +16 -10
  70. package/dist/storage/index-build.mjs +61 -13
  71. package/dist/storage/index-graph.d.mts +1 -0
  72. package/dist/storage/index-graph.mjs +29 -5
  73. package/dist/storage/index-layers.d.mts +1 -0
  74. package/dist/storage/index-layers.mjs +5 -2
  75. package/dist/storage/index-reach.mjs +7 -5
  76. package/dist/storage/index-remap.mjs +5 -5
  77. package/dist/storage/index-visible.mjs +16 -5
  78. package/dist/storage/links.mjs +3 -3
  79. package/dist/storage/pack-order.d.mts +1 -0
  80. package/dist/storage/pack-order.mjs +18 -1
  81. package/dist/storage/prune-walk.mjs +5 -2
  82. package/dist/storage/prune.mjs +107 -37
  83. package/dist/storage/receive-bounds.mjs +3 -2
  84. package/dist/storage/visible.mjs +3 -2
  85. package/dist/storage/walk.d.mts +1 -0
  86. package/dist/storage/walk.mjs +9 -5
  87. package/dist/storage/wants.mjs +17 -11
  88. package/dist/store/call-count.d.mts +8 -0
  89. package/dist/store/call-count.mjs +15 -7
  90. package/dist/store/errors.d.mts +7 -1
  91. package/dist/store/errors.mjs +7 -1
  92. package/dist/store/job-try.mjs +3 -1
  93. package/dist/store/records.mjs +17 -2
  94. package/dist/store/repo-record.mjs +9 -2
  95. package/dist/store/scopes.mjs +10 -2
  96. package/dist/sync/bound.d.mts +1 -1
  97. package/dist/sync/import.mjs +1 -1
  98. package/dist/sync/layer.mjs +4 -7
  99. package/dist/sync/mirror.mjs +1 -1
  100. package/dist/topics/advance.mjs +4 -4
  101. package/dist/topics/layer.mjs +1 -1
  102. package/package.json +3 -3
@@ -4,6 +4,8 @@ import { upstreamOf } from "../store/catalogue.mjs";
4
4
  import { collections } from "../store/scopes.mjs";
5
5
  import { answeredBy, effectWithin, objectsFace, scopedReader } from "../storage/calls.mjs";
6
6
  import { callScope, inCallScope } from "../store/call-count.mjs";
7
+ import { askingOnLost } from "../storage/index-visible.mjs";
8
+ import { indexRowKey } from "../storage/layout.mjs";
7
9
  import { withPushed } from "../storage/visible.mjs";
8
10
  import { WholeRepo, storedPeel, storesPeel, wholeRefs } from "../store/ref-rows.mjs";
9
11
  import { openRepo, repoAccess } from "./access.mjs";
@@ -213,10 +215,16 @@ const viewOf = /* @__PURE__ */ Effect.fnUntraced(function* (caller, resolved, ow
213
215
  const peeled = row === void 0 ? void 0 : yield* storedPeel(row);
214
216
  if (peeled !== void 0) ordered.push(peeled);
215
217
  }
216
- const tips = {
218
+ const lost = core.indexLost === void 0 || at.index === void 0 ? void 0 : core.indexLost(resolved.internalId, {
219
+ ...indexRowKey,
220
+ value: at.index
221
+ }, at.listed);
222
+ const asking = (input) => lost === void 0 ? input : askingOnLost(input, lost);
223
+ const tips = asking({
217
224
  tips: [...new Set(ordered)],
218
- row: at.index
219
- };
225
+ row: at.index,
226
+ roots: at.roots
227
+ });
220
228
  const read = at.pushed === void 0 ? `${at.listed.version}` : `${at.listed.version}+${at.pushed.id}`;
221
229
  const reach = options.ownWrites === false ? `${read}:refs` : read;
222
230
  const key = owner === void 0 ? reach : `${reach}:${owner.prefix}`;
@@ -240,10 +248,11 @@ const viewOf = /* @__PURE__ */ Effect.fnUntraced(function* (caller, resolved, ow
240
248
  const above = yield* parentTips(caller, resolved);
241
249
  const both = [.../* @__PURE__ */ new Set([...tips.tips, ...above])];
242
250
  if (both.length === tips.tips.length) return void 0;
243
- const asked = {
251
+ const asked = asking({
244
252
  tips: both,
245
- row: at.index
246
- };
253
+ row: at.index,
254
+ roots: at.roots
255
+ });
247
256
  let parted;
248
257
  const part = (pick) => () => {
249
258
  parted ??= SealedObjects.parted(sealed, viewWhole, at.listed, asked, at.pushed);
@@ -1,17 +1,47 @@
1
1
  import { keepsEvents } from "../contracts/events.mjs";
2
+ import { badCursor } from "../engine/reads.mjs";
3
+ import { utf8 } from "../protocol/bytes/text.mjs";
2
4
  import { afterCommit } from "../store/call-count.mjs";
5
+ import { listBound } from "../store/cursor-seal.mjs";
3
6
  import { storeCall } from "../store/errors.mjs";
4
7
  import { keptKey } from "../store/records.mjs";
5
8
  import { newChangeId, repoScope } from "../store/scopes.mjs";
6
9
  import { callerFor, contended, openRepo, repoAccess } from "./access.mjs";
7
10
  import { isDeliverJob, skipFailed } from "./events/deliver.mjs";
8
- import { refViewIn, seesJob } from "./ref-view.mjs";
11
+ import { seesJob } from "./job-view.mjs";
12
+ import { refViewIn } from "./ref-view.mjs";
9
13
  import { heldReceipt, receiptAnswered, receiptReads, receiptWrites } from "./receipts.mjs";
10
14
  import { fail } from "../contracts/result.mjs";
11
15
  import { CoreParts, QueueParts } from "./parts.mjs";
12
16
  import * as Clock$1 from "effect/Clock";
13
17
  import * as Effect from "effect/Effect";
18
+ import { limits } from "@ref0/infra";
14
19
  // src/core/work.ts
20
+ /**
21
+ * The UTF-8 bytes a `work.list` cursor's text is padded to before it's sealed, the seal's own
22
+ * measure, so a sealed cursor's length tells nothing of the job it ends on, such as a hidden one.
23
+ * A store's cursor is a job's name and key as JSON: at most 256 and 1,024 bytes of them, each byte
24
+ * at most 6 once escaped, as `\u001f` is, and 7 of brackets, quotes and a comma. Then the length
25
+ * prefix, at most 5.
26
+ */
27
+ const workCursorBytes = 6 * (limits.nameBytes + limits.keyBytes) + 7 + 5;
28
+ /**
29
+ * A store's `cursor` as a `work.list` cursor's text: its length in UTF-16 units, then it, padded
30
+ * with spaces to `workCursorBytes`. `INTERNAL` for a store's cursor past them, which no store here
31
+ * writes.
32
+ */
33
+ const workCursorText = (cursor) => {
34
+ const text = `${cursor.length}:${cursor}`;
35
+ const bytes = utf8(text).byteLength;
36
+ return bytes > workCursorBytes ? fail("INTERNAL", `The store's cursor holds ${bytes} bytes, past the ${workCursorBytes} a work.list cursor holds`) : Effect.succeed(text + " ".repeat(workCursorBytes - bytes));
37
+ };
38
+ /** The store's cursor an opened `work.list` cursor's text holds, or none when it isn't one. */
39
+ const storeCursor = (text) => {
40
+ const length = /^(\d+):/.exec(text);
41
+ if (length === null) return void 0;
42
+ const start = length[0].length;
43
+ return text.slice(start, start + Number(length[1]));
44
+ };
15
45
  /** Commits a work write's receipt, and `git.repack` due to sweep it, at the scope's `expect`. */
16
46
  const commitReceipt = (internalId, write) => Effect.flatMap(Effect.service(CoreParts), (core) => storeCall(() => {
17
47
  const receipt = receiptWrites(write.kept, write.answer, core.repackJobRow);
@@ -102,14 +132,27 @@ const workCalls = (bound) => {
102
132
  const { internalId } = opened;
103
133
  const repoOf = repoAccess(opened);
104
134
  const refView = yield* refViewIn(caller, repoOf);
135
+ const core = yield* CoreParts;
136
+ const sealed = core.access !== void 0;
137
+ const bound = listBound("work.list", internalId, input.state ?? "");
138
+ const sent = input.page?.after;
139
+ const opens = sent === void 0 || !sealed ? sent : yield* core.cursors.open(bound, sent);
140
+ const after = sealed && opens !== void 0 ? storeCursor(opens) : opens;
141
+ if (sent !== void 0 && after === void 0) return yield* badCursor();
105
142
  const request = {};
106
143
  if (input.state !== void 0) request.state = input.state;
107
- if (input.page !== void 0) request.page = input.page;
144
+ if (input.page !== void 0) {
145
+ const page = { ...input.page };
146
+ if (after !== void 0) page.after = after;
147
+ request.page = page;
148
+ }
108
149
  const { jobs } = yield* QueueParts;
109
150
  const listed = yield* storeCall(() => jobs.list(repoScope(internalId), request));
151
+ const items = listed.items.filter((item) => seesJob(refView, item));
152
+ if (listed.next === void 0) return { items };
110
153
  return {
111
- ...listed,
112
- items: listed.items.filter((item) => seesJob(refView, item))
154
+ items,
155
+ next: sealed ? yield* core.cursors.seal(bound, yield* workCursorText(listed.next)) : listed.next
113
156
  };
114
157
  }),
115
158
  retry: write("work.retry"),
package/dist/effect.d.mts CHANGED
@@ -1,8 +1,7 @@
1
1
  import { EffectCalls, GitCaller, GitStore } from "./contracts/services.mjs";
2
2
  import { IndexCalls, IndexReachInput, IndexReached, IndexStatus, IndexTip, IndexTry, IndexTryInput } from "./contracts/objects.mjs";
3
3
  import { CallAllowance, CallBudget, CallBudgetOptions } from "./store/call-count.mjs";
4
- import { spentRefusalOf } from "./contracts/calls-spent.mjs";
5
- import { storeCall } from "./store/errors.mjs";
4
+ import { commitCallsMost, storeCall } from "./store/errors.mjs";
6
5
  import { bucketCall } from "./storage/calls.mjs";
7
6
  import { GitRestApi } from "./rest/api.mjs";
8
7
  import { GitCallerMiddleware, GitRestServices, RestServerSeam } from "./rest/caller.mjs";
@@ -14,4 +13,4 @@ import { ReposApiGroup } from "./rest/repos.mjs";
14
13
  import { TokensApiGroup } from "./rest/tokens.mjs";
15
14
  import { WorkApiGroup } from "./rest/work.mjs";
16
15
  import { SeamAuthorizeInput, TokenRevokeCheck } from "./core/seam.mjs";
17
- export { type CallAllowance, CallBudget, type CallBudgetOptions, type EffectCalls, GitCaller, GitCallerMiddleware, GitErrors, GitRestApi, GitRestHandlers, GitRestServices, GitStore, type IndexCalls, type IndexReachInput, type IndexReached, type IndexStatus, type IndexTip, type IndexTry, type IndexTryInput, MeApiGroup, RefsApiGroup, ReposApiGroup, type RestServerSeam, type SeamAuthorizeInput, type TokenRevokeCheck, TokensApiGroup, WorkApiGroup, bucketCall, spentRefusalOf, storeCall };
16
+ export { type CallAllowance, CallBudget, type CallBudgetOptions, type EffectCalls, GitCaller, GitCallerMiddleware, GitErrors, GitRestApi, GitRestHandlers, GitRestServices, GitStore, type IndexCalls, type IndexReachInput, type IndexReached, type IndexStatus, type IndexTip, type IndexTry, type IndexTryInput, MeApiGroup, RefsApiGroup, ReposApiGroup, type RestServerSeam, type SeamAuthorizeInput, type TokenRevokeCheck, TokensApiGroup, WorkApiGroup, bucketCall, commitCallsMost, storeCall };
package/dist/effect.mjs CHANGED
@@ -1,7 +1,6 @@
1
1
  import { GitCaller, GitStore } from "./contracts/services.mjs";
2
2
  import { CallBudget } from "./store/call-count.mjs";
3
- import { spentRefusalOf } from "./contracts/calls-spent.mjs";
4
- import { storeCall } from "./store/errors.mjs";
3
+ import { commitCallsMost, storeCall } from "./store/errors.mjs";
5
4
  import { bucketCall } from "./storage/calls.mjs";
6
5
  import { GitRestApi } from "./rest/api.mjs";
7
6
  import { GitCallerMiddleware, GitRestServices } from "./rest/caller.mjs";
@@ -12,4 +11,4 @@ import { RefsApiGroup } from "./rest/refs.mjs";
12
11
  import { ReposApiGroup } from "./rest/repos.mjs";
13
12
  import { TokensApiGroup } from "./rest/tokens.mjs";
14
13
  import { WorkApiGroup } from "./rest/work.mjs";
15
- export { CallBudget, GitCaller, GitCallerMiddleware, GitErrors, GitRestApi, GitRestHandlers, GitRestServices, GitStore, MeApiGroup, RefsApiGroup, ReposApiGroup, TokensApiGroup, WorkApiGroup, bucketCall, spentRefusalOf, storeCall };
14
+ export { CallBudget, GitCaller, GitCallerMiddleware, GitErrors, GitRestApi, GitRestHandlers, GitRestServices, GitStore, MeApiGroup, RefsApiGroup, ReposApiGroup, TokensApiGroup, WorkApiGroup, bucketCall, commitCallsMost, storeCall };
@@ -1,6 +1,6 @@
1
1
  import { fail } from "../contracts/result.mjs";
2
2
  import { drained } from "../protocol/diff/read.mjs";
3
- import { decodeCommit } from "../protocol/objects/commit.mjs";
3
+ import { decodeCommit, parentsWithin } from "../protocol/objects/commit.mjs";
4
4
  import { decodeTag } from "../protocol/objects/tag.mjs";
5
5
  import { fromDiff } from "./failures.mjs";
6
6
  import * as Effect from "effect/Effect";
@@ -11,14 +11,15 @@ const unreadable = (oid, decoded) => Effect.catch(decoded, (error) => fail("DATA
11
11
  /**
12
12
  * A commit decoded from `bytes`, which the reader charged already, its subject charged too: a
13
13
  * string beside the message, two bytes a character at most, which a walk holds as long as the
14
- * commit.
14
+ * commit. One of the reader's roots has no parents, so no walk reads past it.
15
15
  */
16
16
  const decodedAt = /* @__PURE__ */ Effect.fnUntraced(function* (reader, oid, bytes) {
17
17
  const commit = yield* unreadable(oid, decodeCommit(bytes));
18
18
  yield* Effect.mapError(reader.charge(commit.subject.length * 2), asWalk);
19
19
  return {
20
20
  oid,
21
- ...commit
21
+ ...commit,
22
+ parents: parentsWithin(reader.roots, oid, commit.parents)
22
23
  };
23
24
  });
24
25
  /** A parent, or a commit a walk reaches: a commit, or `DATA_LOSS`. */
@@ -1,5 +1,6 @@
1
1
  import { fail } from "../contracts/result.mjs";
2
2
  import { DiffReader } from "../protocol/diff/read.mjs";
3
+ import { noRepoRoots } from "../protocol/objects/commit.mjs";
3
4
  import { namedCommit, walkedThrough } from "./commits.mjs";
4
5
  import { mergeBasesOf } from "./merge-base-walk.mjs";
5
6
  import { limitsOf, readThrough, stepDeadline, timed } from "./reads.mjs";
@@ -9,15 +10,16 @@ import * as Effect from "effect/Effect";
9
10
  * `merge-base --all <first> <rest>...`: the best common ancestors of the first commit and any of
10
11
  * the rest, newest first, or none for unrelated histories. Each commit named is peeled through
11
12
  * its tags. The walk reads each commit as it reaches it, within the call's limits, and stops at
12
- * the bases, so a deep history below them is never read.
13
+ * the bases, so a deep history below them is never read, and at each of `roots`, which reads with
14
+ * no parents.
13
15
  */
14
- const mergeBases = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, call) {
16
+ const mergeBases = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, call, roots = noRepoRoots) {
15
17
  const limits = yield* limitsOf(input.limits);
16
18
  const [first, ...rest] = input.commits;
17
19
  if (first === void 0 || rest.length === 0) return yield* fail("INVALID_ARGUMENT", "A merge base needs two commits or more");
18
20
  const deadline = yield* stepDeadline(limits.milliseconds, "walk-limit", call);
19
21
  const run = Effect.gen(function* () {
20
- const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally);
22
+ const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally, void 0, roots);
21
23
  const one = yield* namedCommit(reader, first);
22
24
  const twos = yield* Effect.forEach(rest, (oid) => namedCommit(reader, oid));
23
25
  const commits = walkedThrough(reader, [one, ...twos]);
@@ -3,6 +3,7 @@ import { joinedBytes } from "../protocol/bytes/joined.mjs";
3
3
  import { streamOf } from "../protocol/bytes/streams.mjs";
4
4
  import { bytesOf, keyOf } from "../protocol/diff/paths.mjs";
5
5
  import { DiffReader } from "../protocol/diff/read.mjs";
6
+ import { noRepoRoots } from "../protocol/objects/commit.mjs";
6
7
  import { isTreeMode, objectId } from "../protocol/objects/object.mjs";
7
8
  import { compareEntries, treeBytes } from "../protocol/objects/tree.mjs";
8
9
  import { attributesFor, parseAttributes, parsedBytes, pathAttributesOf, refusedAttribute } from "./attributes.mjs";
@@ -1069,9 +1070,9 @@ const basesRoot = /* @__PURE__ */ Effect.fnUntraced(function* (call, input, attr
1069
1070
  * `base`, `ours` and `theirs`, each a tree or what peels to one, merged: a tree, or a conflict.
1070
1071
  * Without `base`, two commits merge over their merge bases. `load` gives xdiff for the merge's
1071
1072
  * scope, loaded once the first file's content merges. A `step` of a longer call reads within that
1072
- * call's tally and deadline.
1073
+ * call's tally and deadline. The merge bases' walk sees each of `repoRoots` as having no parents.
1073
1074
  */
1074
- const mergeTrees = (read, input, load, step) => Effect.scoped(Effect.gen(function* () {
1075
+ const mergeTrees = (read, input, load, step, repoRoots = noRepoRoots) => Effect.scoped(Effect.gen(function* () {
1075
1076
  const limits = yield* limitsOf(input.limits);
1076
1077
  const scope = yield* Effect.scope;
1077
1078
  const xdiff = yield* Effect.cached(Effect.provideService(load, Scope.Scope, scope));
@@ -1079,7 +1080,7 @@ const mergeTrees = (read, input, load, step) => Effect.scoped(Effect.gen(functio
1079
1080
  const run = Effect.gen(function* () {
1080
1081
  const known = /* @__PURE__ */ new Map();
1081
1082
  const call = {
1082
- reader: new DiffReader(knownFirst(known, readThrough(read, deadline)), limits.reads, step?.tally),
1083
+ reader: new DiffReader(knownFirst(known, readThrough(read, deadline)), limits.reads, step?.tally, void 0, repoRoots),
1083
1084
  xdiff,
1084
1085
  deadline,
1085
1086
  known,
@@ -3,6 +3,7 @@ import "../contracts/objects.mjs";
3
3
  import "../contracts/result.mjs";
4
4
  import "../protocol/diff/patch.mjs";
5
5
  import "../protocol/diff/tree-diff.mjs";
6
+ import "../protocol/objects/commit.mjs";
6
7
  import "./reads.mjs";
7
8
  import "./xdiff.mjs";
8
9
  import "effect/Effect";
@@ -32,7 +32,7 @@ const refusedAs = (run) => (one, two) => Effect.catch(run(one, two), (error) =>
32
32
  const mergeParts = (load) => {
33
33
  const allotted = (allot) => Effect.flatMap(allot, (allotment) => loadAllotted(load, allotment, xdiffTooLarge));
34
34
  return {
35
- mergeTrees: (read, input, allot, call) => mergeTrees(read, input, allotted(allot), call),
35
+ mergeTrees: (read, input, allot, call, roots) => mergeTrees(read, input, allotted(allot), call, roots),
36
36
  lineDiff: (allot) => Effect.map(allotted(allot), (xdiff) => ({
37
37
  lines: refusedAs(xdiffLines(xdiff, "myers")),
38
38
  patcher: refusedAs(xdiffPatcher(xdiff, "myers"))
@@ -1,6 +1,7 @@
1
1
  import { fail } from "../contracts/result.mjs";
2
2
  import { entryAt, pathParts } from "../protocol/diff/paths.mjs";
3
3
  import { DiffReader } from "../protocol/diff/read.mjs";
4
+ import { noRepoRoots } from "../protocol/objects/commit.mjs";
4
5
  import { commitAt, namedCommit, timeOf } from "./commits.mjs";
5
6
  import { fromDiff } from "./failures.mjs";
6
7
  import { badCursor, inputDigest, limitOf, limitsOf, readThrough, stepDeadline, timed } from "./reads.mjs";
@@ -132,12 +133,37 @@ var RevWalk = class {
132
133
  return left - 1;
133
134
  }
134
135
  };
136
+ /** The filter's part of a cursor's digest, so a cursor of one filter can't page another. */
137
+ const filterKey = (filter) => [
138
+ filter.authors?.join("\n"),
139
+ filter.committers?.join("\n"),
140
+ filter.since,
141
+ filter.until
142
+ ].map((part) => String(part ?? "")).join("\0");
143
+ const addressesOf = (named) => named === void 0 ? void 0 : new Set(named.map((email) => email.toLowerCase()));
144
+ /** Whether `filter` keeps a commit the walk lists. */
145
+ const keeperOf = (filter) => {
146
+ const authors = addressesOf(filter.authors);
147
+ const committers = addressesOf(filter.committers);
148
+ const { since, until } = filter;
149
+ return (commit) => (authors === void 0 || authors.has(commit.author.email.toLowerCase())) && (committers === void 0 || committers.has(commit.committer.email.toLowerCase())) && (since === void 0 || commit.committer.at >= since) && (until === void 0 || commit.committer.at <= until);
150
+ };
151
+ /**
152
+ * Git's `max_age` stop: a commit committed before `since`, which a walk without `haves` neither
153
+ * lists nor follows to its parents, and `limit_list` marks uninteresting.
154
+ */
155
+ const staleOf = ({ since }) => (commit) => since !== void 0 && commit.committer.at < since;
156
+ /** `limit_list`'s `min_age` skip: a commit committed after `until`, which leaves its date unset. */
157
+ const youngOf = ({ until }) => (commit) => until !== void 0 && commit.committer.at > until;
135
158
  /** `limit_list`, then the commits it kept that are still interesting. */
136
- const limited = /* @__PURE__ */ Effect.fnUntraced(function* (walk, take) {
159
+ const limited = /* @__PURE__ */ Effect.fnUntraced(function* (walk, take, filter = {}) {
160
+ const stale = staleOf(filter);
161
+ const young = youngOf(filter);
137
162
  const kept = [];
138
163
  let date = Number.POSITIVE_INFINITY;
139
164
  let left = slop;
140
165
  for (let commit = walk.list.pop(); commit !== void 0; commit = walk.list.pop()) {
166
+ if (stale(commit)) walk.mark(commit.oid, uninteresting);
141
167
  yield* walk.parents(commit);
142
168
  if (walk.has(commit.oid, uninteresting)) {
143
169
  walk.markParents(commit);
@@ -145,6 +171,7 @@ const limited = /* @__PURE__ */ Effect.fnUntraced(function* (walk, take) {
145
171
  if (left > 0) continue;
146
172
  break;
147
173
  }
174
+ if (young(commit)) continue;
148
175
  date = timeOf(commit);
149
176
  kept.push(commit);
150
177
  }
@@ -153,9 +180,13 @@ const limited = /* @__PURE__ */ Effect.fnUntraced(function* (walk, take) {
153
180
  if (!take(commit)) return;
154
181
  }
155
182
  });
156
- /** The walk without `haves`: each commit listed as it's taken, reading only as far as `take`. */
157
- const unlimited = /* @__PURE__ */ Effect.fnUntraced(function* (walk, take) {
183
+ /**
184
+ * The walk without `haves`: each commit listed as it's taken, reading only as far as `take`, and
185
+ * none past a `stale` one on its line.
186
+ */
187
+ const unlimited = /* @__PURE__ */ Effect.fnUntraced(function* (walk, take, stale = () => false) {
158
188
  for (let commit = walk.list.pop(); commit !== void 0; commit = walk.list.pop()) {
189
+ if (stale(commit)) continue;
159
190
  yield* walk.parents(commit);
160
191
  if (!take(commit)) return;
161
192
  }
@@ -182,26 +213,32 @@ const started = /* @__PURE__ */ Effect.fnUntraced(function* (reader, wants, have
182
213
  }
183
214
  return walk;
184
215
  });
185
- /** `rev-list <wants> ^<haves>`, a page at a time. */
186
- const walkHistory = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, call) {
216
+ /**
217
+ * `rev-list <wants> ^<haves>`, a page at a time, keeping what its `LogFilter` keeps, as Git's
218
+ * `--author`, `--committer`, `--max-age` and `--min-age` do. Each walk here sees each of `roots`
219
+ * as having no parents, as Git's shallow grafts make a repo's roots.
220
+ */
221
+ const walkHistory = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, call, roots = noRepoRoots) {
187
222
  const haves = input.haves ?? [];
188
223
  if (input.wants.length === 0) return yield* fail("INVALID_ARGUMENT", "A walk needs a want");
189
224
  const digest = yield* inputDigest([
190
225
  "walk",
191
226
  ...input.wants,
192
227
  "^",
193
- ...haves
228
+ ...haves,
229
+ filterKey(input)
194
230
  ]);
195
- return yield* paged(read, input, digest, (walk, take) => (haves.length > 0 ? limited : unlimited)(walk, take), call);
231
+ const stale = staleOf(input);
232
+ return yield* paged(read, input, digest, (walk, take) => haves.length > 0 ? limited(walk, take, input) : unlimited(walk, take, stale), call, roots);
196
233
  });
197
234
  /** `rev-list --count <wants> ^<haves>`: how many commits the walk lists, within its limits. */
198
- const countHistory = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, call) {
235
+ const countHistory = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, call, roots = noRepoRoots) {
199
236
  const limits = yield* limitsOf(input.limits);
200
237
  const haves = input.haves ?? [];
201
238
  const deadline = yield* stepDeadline(limits.milliseconds, "walk-limit", call);
202
239
  let count = 0;
203
240
  const run = Effect.gen(function* () {
204
- const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally);
241
+ const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally, void 0, roots);
205
242
  const walk = yield* started(reader, input.wants, haves);
206
243
  yield* (haves.length > 0 ? limited : unlimited)(walk, () => {
207
244
  count += 1;
@@ -215,13 +252,13 @@ const countHistory = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, c
215
252
  * `rev-list --max-count=<most> <wants> ^<haves>`: the first `most` commits the walk lists, in one
216
253
  * walk within its limits, for a caller that reads them all, where each page would walk again.
217
254
  */
218
- const historyUpTo = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, most, call) {
255
+ const historyUpTo = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, most, call, roots = noRepoRoots) {
219
256
  const limits = yield* limitsOf(input.limits);
220
257
  const haves = input.haves ?? [];
221
258
  const deadline = yield* stepDeadline(limits.milliseconds, "walk-limit", call);
222
259
  const commits = [];
223
260
  const run = Effect.gen(function* () {
224
- const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally);
261
+ const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally, void 0, roots);
225
262
  const walk = yield* started(reader, input.wants, haves);
226
263
  yield* (haves.length > 0 ? limited : unlimited)(walk, (commit) => {
227
264
  if (commits.length === most) return false;
@@ -238,21 +275,23 @@ const historyUpTo = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, mo
238
275
  * `path`, a root when `path` is absent from it; a merge TREESAME to a parent is followed only
239
276
  * through the first such parent, and one TREESAME to none through every parent.
240
277
  */
241
- const walkPath = /* @__PURE__ */ Effect.fnUntraced(function* (read, input) {
278
+ const walkPath = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, roots = noRepoRoots) {
242
279
  const parts = pathParts(input.path);
243
280
  if (parts === void 0) return yield* fail("INVALID_ARGUMENT", `'${input.path}' isn't a path`);
244
281
  const digest = yield* inputDigest([
245
282
  "walk-path",
246
283
  input.want,
247
- input.path
284
+ input.path,
285
+ filterKey(input)
248
286
  ]);
287
+ const stale = staleOf(input);
249
288
  return yield* paged(read, {
250
289
  ...input,
251
290
  wants: [input.want]
252
- }, digest, (walk, take) => simplified(walk, parts, take));
291
+ }, digest, (walk, take) => simplified(walk, parts, take, stale), void 0, roots);
253
292
  });
254
293
  /** The walk without `haves`, each commit's parents simplified at `parts` as `walkPath` says. */
255
- const simplified = /* @__PURE__ */ Effect.fnUntraced(function* (walk, parts, take) {
294
+ const simplified = /* @__PURE__ */ Effect.fnUntraced(function* (walk, parts, take, stale) {
256
295
  const atPath = /* @__PURE__ */ new Map();
257
296
  const entryOf = Effect.fnUntraced(function* (commit) {
258
297
  const held = atPath.get(commit.oid);
@@ -263,6 +302,7 @@ const simplified = /* @__PURE__ */ Effect.fnUntraced(function* (walk, parts, tak
263
302
  return key;
264
303
  });
265
304
  for (let commit = walk.list.pop(); commit !== void 0; commit = walk.list.pop()) {
305
+ if (stale(commit)) continue;
266
306
  const own = yield* entryOf(commit);
267
307
  let follow = commit.parents;
268
308
  let shown = commit.parents.length > 0 || own !== "";
@@ -281,18 +321,20 @@ const simplified = /* @__PURE__ */ Effect.fnUntraced(function* (walk, parts, tak
281
321
  }
282
322
  });
283
323
  /**
284
- * One page of a walk, `run` taking each commit it lists: the walk runs again from the start each
285
- * page, within the call's limits, and lists after its cursor's commit, so a cursor holds the
286
- * input's digest and that commit.
324
+ * One page of a walk, `run` taking each commit it lists that the input's `LogFilter` keeps: the
325
+ * walk runs again from the start each page, within the call's limits, and lists after its
326
+ * cursor's commit, so a cursor holds the input's digest and that commit.
287
327
  */
288
- const paged = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, digest, run, call) {
328
+ const paged = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, digest, run, call, roots) {
289
329
  const limits = yield* limitsOf(input.limits);
290
330
  const limit = yield* limitOf(input.page);
291
331
  const after = yield* afterOf(input.page?.after, digest);
292
332
  const items = [];
333
+ const keeps = keeperOf(input);
293
334
  let found = after === void 0;
294
335
  let more = false;
295
336
  const take = (commit) => {
337
+ if (!keeps(commit)) return true;
296
338
  if (!found) {
297
339
  found = commit.oid === after;
298
340
  return true;
@@ -306,7 +348,7 @@ const paged = /* @__PURE__ */ Effect.fnUntraced(function* (read, input, digest,
306
348
  };
307
349
  const deadline = yield* stepDeadline(limits.milliseconds, "walk-limit", call);
308
350
  const walked = Effect.gen(function* () {
309
- const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally);
351
+ const reader = new DiffReader(readThrough(read, deadline), limits.reads, call?.tally, void 0, roots);
310
352
  yield* run(yield* started(reader, input.wants, input.haves ?? []), take);
311
353
  });
312
354
  yield* timed(walked, deadline);
@@ -15,8 +15,8 @@ import { answerSpent, decodeRow } from "../store/errors.mjs";
15
15
  import { refPageRows, storedPeel } from "../store/ref-rows.mjs";
16
16
  import { decodePacks } from "../store/git-store.mjs";
17
17
  import { ReachedMark, markHolds } from "../store/records.mjs";
18
- import { readRecord } from "../store/repo-record.mjs";
19
- import { collections, reachedKey } from "../store/scopes.mjs";
18
+ import { readRecord, rootsOf } from "../store/repo-record.mjs";
19
+ import { collections, reachedKey, repoRootsKey } from "../store/scopes.mjs";
20
20
  import { fetchReaches, hiddenUnder } from "../protocol/wire/lines.mjs";
21
21
  import { read } from "../core/objects/objects.mjs";
22
22
  import * as Effect from "effect/Effect";
@@ -114,12 +114,14 @@ const coreHttpParts = (parts, options = {}) => {
114
114
  refsRead,
115
115
  packsRead,
116
116
  indexRowKey,
117
- reachedKey
117
+ reachedKey,
118
+ repoRootsKey
118
119
  ]);
119
120
  const { record, snapshot } = read$1;
120
121
  if (record === void 0 || record.deleted === true) return yield* fail("NOT_FOUND", `No repo '${operation.repo}'`);
121
- const [, refRows = [], packRows = [], indexRows = [], markRows = []] = snapshot.results;
122
+ const [, refRows = [], packRows = [], indexRows = [], markRows = [], rootRows] = snapshot.results;
122
123
  const packs = yield* decodePacks(packRows);
124
+ const roots = yield* rootsOf(rootRows);
123
125
  const listed = {
124
126
  repo: resolved.internalId,
125
127
  version: snapshot.version,
@@ -134,13 +136,17 @@ const coreHttpParts = (parts, options = {}) => {
134
136
  listed,
135
137
  refs: seen,
136
138
  refRows,
137
- index: row
139
+ index: row,
140
+ roots
138
141
  }
139
142
  });
140
143
  const objects = objectsFace(viewed);
144
+ const [stored] = indexRows;
145
+ const lost = stored === void 0 ? void 0 : core.indexLost?.(resolved.internalId, stored, listed);
141
146
  const index = viewed.index === void 0 ? void 0 : {
142
147
  calls: viewed.index,
143
- row
148
+ row,
149
+ ...lost !== void 0 && { lost }
144
150
  };
145
151
  const refs = peel ? yield* advertised(refRows, seen) : [...seen].map(([name, oid]) => ({
146
152
  name,
@@ -163,13 +169,15 @@ const coreHttpParts = (parts, options = {}) => {
163
169
  refs: served,
164
170
  objects,
165
171
  whole,
166
- seesAll
172
+ seesAll,
173
+ roots
167
174
  } : {
168
175
  listed,
169
176
  refs: served,
170
177
  objects,
171
178
  whole,
172
179
  seesAll,
180
+ roots,
173
181
  index
174
182
  };
175
183
  });
@@ -277,7 +285,8 @@ const coreHttpParts = (parts, options = {}) => {
277
285
  listed: at.listed,
278
286
  tips,
279
287
  wants: request.wants,
280
- signal
288
+ signal,
289
+ roots: at.roots
281
290
  };
282
291
  if (at.index !== void 0) input.index = at.index;
283
292
  const missing = yield* unreachableWant(input);
package/dist/index.d.mts CHANGED
@@ -20,9 +20,9 @@ import { authorize_d_exports } from "./contracts/authorize.mjs";
20
20
  import "./queue/namespace.mjs";
21
21
  import "./lfs/namespace.mjs";
22
22
  import { QueueInternals, mergeQueue } from "./queue/host.mjs";
23
- import { CommitCalls, CommitCreateInput, CommitDiffInput, Compare, CompareInput, ComparisonFile, LineCounts, LogInput, RefPublication, Revision, commits_d_exports } from "./contracts/commits.mjs";
23
+ import { CommitCalls, CommitCreateInput, CommitDiffInput, Compare, CompareInput, ComparisonFile, LineCounts, LogInput, RefPublication, Revision, commits_d_exports, logEmailsMost } from "./contracts/commits.mjs";
24
24
  import { Commit, DiffListing, MergeBaseInput, MergeBases, MergeLabels, MergeTree, ObjectWrite, ObjectWrites, PathObject, ReadOptions, ReadPage, RenamesSkipped, Signature, Tag, TagFields, TreeChange, TreeChanges, TreeDiffInput, TreeMergeInput, WalkInput } from "./contracts/engine.mjs";
25
- import { BeforeAfter, CandidateClosed, CandidateClosedFields, CandidateOpened, CandidateReported, EntryAdded, EntryFailed, EntryMerged, EntryRemoved, EntryRetried, EventEnvelope, EventFeature, FeedItem, FenceReason, FencedPack, GitEvent, HoldEvent, HoldEventFields, IndexRefusal, QueueEvent, QueueRestarted, RefPush, RefUpdated, RepoCreated, RepoDeletedEvent, RepoEnvelope, RepoEvent, RepoIndexRefused, RepoJobFailed, RepoMaintained, RepoRenamed, RepoVisibilityChanged, RepoWorkFailed, TokenEvent, TokenEventFields, TopicAdded, TopicEnvelope, TopicEvent, TopicFailed, TopicMerged, TopicOpened, TopicRemoved, TopicReported, TopicWorkFailed, events_d_exports } from "./contracts/events.mjs";
25
+ import { BeforeAfter, CandidateClosed, CandidateClosedFields, CandidateOpened, CandidateReported, EntryAdded, EntryFailed, EntryMerged, EntryRemoved, EntryRetried, EventEnvelope, EventFeature, FeedItem, FenceReason, FencedPack, GitEvent, HoldEvent, HoldEventFields, IndexRefusal, QueueEvent, QueueRestarted, RefPush, RefUpdated, RepoCreated, RepoDeletedEvent, RepoEnvelope, RepoEvent, RepoIndexRefused, RepoJobFailed, RepoMaintained, RepoPruneRefused, RepoRenamed, RepoVisibilityChanged, RepoWorkFailed, TokenEvent, TokenEventFields, TopicAdded, TopicEnvelope, TopicEvent, TopicFailed, TopicMerged, TopicOpened, TopicRemoved, TopicReported, TopicWorkFailed, events_d_exports } from "./contracts/events.mjs";
26
26
  import { File, FileCalls, FileDiff, FileReadInput, FilesDiffInput, FilesListInput, FilesRead, files_d_exports } from "./contracts/files.mjs";
27
27
  import { ForkCalls, ForkCreateInput, ForkFetched, ForkGetInput, ForkHolder, ForkListInput, forks_d_exports } from "./contracts/forks.mjs";
28
28
  import { LfsCalls, LfsFeature, LfsGetInput, LfsObject, LfsOptions } from "./contracts/lfs.mjs";
@@ -36,7 +36,7 @@ import { BypassOperation, FilesAllowOperation, ForkOperation, MeOperation, Opera
36
36
  import { client_d_exports } from "./client/client.mjs";
37
37
  import { AddResult, Added, BatchOptions, Bisect, Candidate, CandidateCloseReason, CandidateId, CandidateReportInput, CandidateResult, CandidateState, CandidatesResult, Entry, EntryFailureReason, EntryFields, EntryGroups, EntryHoldInput, EntryHoldsInput, EntryId, EntryResult, EntryState, Held, Hold, HoldFields, HoldId, HoldResult, HoldsResult, JoinInput, Judged, LanesInput, MergeInput, MergeMethod, MergePlan, MergeQueueCalls, MergeQueueLayerOptions, MergeQueueOptions, MetaValue, PreviousQueueSchedule, QueueAddInput, QueueFailureCounts, QueueKeys, QueueListInput, QueueListResult, QueueMeta, QueueOf, QueueRecent, QueueTargetInput, QueueView, ReleaseResult, Released, RemoveResult, Removed, Report, ReportDetails, ReportOptions, ReportResult, Reported, RestartResult, Restarted, Retried, RetryResult, ScheduleOption, TargetHoldInput } from "./contracts/queue.mjs";
38
38
  import { RepoStreamEvent } from "./rest/wire.mjs";
39
- import { Ref, RefCalls, RefCount, RefCountInput, RefEdit, RefInput, RefListInput, RefProtection, RefSource, RefUpdate, RefUpdateKind, RefsUpdateInput, RefsUpdated, refs_d_exports } from "./contracts/refs.mjs";
39
+ import { Ref, RefCalls, RefCount, RefCountInput, RefEdit, RefInput, RefListInput, RefProtection, RefSource, RefUpdate, RefUpdateKind, RefsUpdateInput, RefsUpdated, maxSeenRefs, refs_d_exports } from "./contracts/refs.mjs";
40
40
  import { BasicCredential, BearerCredential, ClientCredential, ClientCredentials, CredentialInput, RemoteCalls, RemoteOptions, TransportFailure, TransportRetry, WithoutActor, WithoutSignal } from "./contracts/remote.mjs";
41
41
  import { PinnedRepo, RepoCalls, RepoCatalogueEntry, RepoCreateInput, RepoDeleted, RepoGetInput, RepoIndexHold, RepoInfo, RepoInfoStats, RepoInput, RepoListInput, RepoListOrder, RepoRecord, RepoRenameInput, RepoStats, RepoUpdateInput, RepoWork, repos_d_exports } from "./contracts/repos.mjs";
42
42
  import { PeelInput, Peeled, TagCalls, TagCreateInput, peelMost, peelTagsMost, tags_d_exports } from "./contracts/tags.mjs";
@@ -87,4 +87,4 @@ import { PushHookInput } from "./contracts/git-hooks.mjs";
87
87
  import { public_d_exports as public_d_exports$5 } from "./signin/public.mjs";
88
88
  import "./signin/namespace.mjs";
89
89
  import { jobStates } from "@ref0/infra";
90
- export { type Accepted, type AccessOption, type Acting, type Actor, type ActorId, type ActorInput, type AddResult, type Added, type Allotment, type AnonymousActor, type ApprovalBase, type ApprovalDecision, type ApprovalPageContext, type ApprovalPageInput, type ApprovalPrompt, type ApprovedGrant, auth_namespace_d_exports as Auth, type AuthInput, authorize_d_exports as Authorize, type AuthorizeAnswer, type AuthorizeInput, type Awaitable, type BasicCredential, type BatchOptions, type BearerCredential, type BeforeAfter, BeginPushUpload, type Bisect, type Blob, type BlobCalls, type BlobCreateInput, BlobLimit, BlobNone, blobs_d_exports as Blobs, type BypassOperation, type Bytes, type CallInput, type Caller, type CallerGrant, type Candidate, type CandidateCloseReason, type CandidateClosed, type CandidateClosedFields, type CandidateId, type CandidateOpened, type CandidateReportInput, type CandidateReported, type CandidateResult, type CandidateState, type CandidatesResult, type ClientAdapter, type ClientCredential, type ClientCredentials, type ClientFetchInput, type ClientFetchResult, type ClientPushInput, type Commit, type CommitCalls, type CommitCreateInput, type CommitDiffInput, commits_d_exports as Commits, type Compare, type CompareInput, type ComparisonFile, type ConfirmApprovalPage, ContextValue, type CopyRow, type CopyRowsInput, type CopyRowsPage, type CreatedObject, type CreatedToken, type CredentialInput, type Credentials, type CredentialsBasic, type CredentialsBearer, DataLossContext, DataLossReason, type DecisionAnswer, type DeniedGrant, type DeviceApproval, type DeviceCodePage, type DeviceCodeRequest, type DeviceCodeResponse, type DeviceExchange, type DiffListing, type EffectiveLimits, type Entry, type EntryAdded, type EntryFailed, type EntryFailureReason, type EntryFields, type EntryGroups, type EntryHoldInput, type EntryHoldsInput, type EntryId, type EntryMerged, type EntryRemoved, type EntryResult, type EntryRetried, type EntryState, ErrorContext, type EventEnvelope, type EventFeature, event_streams_d_exports as EventStreams, events_d_exports as Events, ExistingContext, ExistingReason, type FailureResult, type FeedItem, type FenceReason, type FencedPack, type FetchAdjustment, type FetchAnswer, type FetchReadInput, type FetchReadTarget, FetchRequest, type FetchRule, type FetchRuleInput, type File, type FileCalls, type FileDiff, type FileReadInput, type FileRuleOptions, files_d_exports as Files, type FilesAllowOperation, type FilesDiffInput, type FilesListInput, type FilesRead, Filter, FinishPushUpload, type ForkCalls, type ForkCreateInput, type ForkFetched, type ForkGetInput, type ForkHolder, type ForkListInput, type ForkOperation, forks_d_exports as Forks, git_namespace_d_exports as Git, type GitAdapter, type GitAuth, type GitAuthorize, client_d_exports as GitClient, type GitClientCalls, type GitClientOptions, type GitError, GitErrorBody, type GitErrorCode, type GitErrorContexts, type GitErrorFields, type GitErrorInput, type GitErrorTagged, type GitEvent, git_events_d_exports as GitEvents, public_d_exports as GitHooks, type GitNeeds, type GitObject, type GitObjects, type GitScope, type GitServer, type GitServerOptions, type GitStore, type GitStoreAddInput, type GitStoreCommitInput, type GitStoreReadInput, type Grant, type GrantAgainInput, type GrantAgainRequest, type GrantInput, type GrantReachInput, type GrantResolver, type GrantScope, type HandlerOptions, type Held, type HeldPack, type HiddenSpan, type Hold, type HoldEvent, type HoldEventFields, type HoldFields, type HoldId, type HoldResult, type Holding, type HoldingsInput, type HoldingsWalked, type HoldsResult, HostErrorContext, type HostFunctionName, type ImportState, type IndexCalls, type IndexReachInput, type IndexReached, type IndexRefusal, type IndexStatus, type IndexTip, type IndexTry, type IndexTryInput, InternalRepoId, InvalidInputContext, InvalidInputReason, type JoinInput, type Judged, type LanesInput, public_d_exports$1 as Lfs, type LfsCalls, type LfsFeature, type LfsGetInput, type LfsObject, type LfsOptions, type LfsPointers, type LfsPointersBuilder, type LineCounts, type LinkedObjects, type Listed, type ListedInput, type ListenInput, type Localize, type LogInput, type MaintainInput, type Me, type MeOperation, type MergeAnswer, type MergeBaseInput, type MergeBases, type MergeCalls, type MergeCreateInput, type MergeInput, type MergeLabels, type MergeMethod, type MergePlan, public_d_exports$2 as MergeQueue, type MergeQueueCalls, type MergeQueueLayerOptions, type MergeQueueOptions, type MergeTree, public_d_exports$3 as Merges, type MetaValue, MissingContext, MissingReason, type NamedActor, NotAllowedContext, NotAllowedReason, type OAuthClient, type OAuthError, type OAuthTokenResponse, type ObjectHeader, type ObjectHeadersInput, type ObjectInput, type ObjectReadInput, type ObjectReadResult, type ObjectReader, type ObjectReaderInput, type ObjectSizesInput, type ObjectType, type ObjectWrite, type ObjectWrites, objects_namespace_d_exports as Objects, type ObjectsChange, type ObjectsFactory, type ObjectsFetchInput, type ObjectsOpenInput, type ObjectsRead, type ObjectsReadInput, type ObjectsStarting, type ObjectsStartingInput, type ObjectsStep, type Oid, type Operation, type OperationKind, type Option, type Pack, type PacksMemory, type PacksOptions, type PagedInput, type PathObject, type PeelInput, type Peeled, type PinnedRepo, policy_d_exports as Policy, PreconditionContext, PreconditionReason, type PrefixTarget, type Prepare, type PrepareInput, type PreviousQueueSchedule, public_d_exports$4 as PrivateRefs, type ProtectOptions, type ProvidedBy, type PushContext, type PushFacts, type PushHookInput, type PushOperation, type PushOptions, type PushRule, type PushRuleInput, type PushUploadOptions, PushUploadPart, PushUploadStarted, type PushedCommit, type PushedCommitsInput, type Quarantine, type QueueAddInput, type QueueAddOperation, type QueueCandidateOperation, type QueueEntryOperation, type QueueEvent, type QueueFailureCounts, type QueueInternals, type QueueKeys, type QueueListInput, type QueueListResult, type QueueMeta, type QueueOf, type QueueRecent, type QueueReleaseOperation, type QueueRestarted, type QueueTargetInput, type QueueTargetOperation, type QueueView, type ReadLimits, type ReadObject, type ReadObjects, type ReadOptions, type ReadPage, type ReceiveInput, type Ref, type RefAudience, type RefCalls, type RefCount, type RefCountInput, type RefEdit, type RefForced, type RefInput, type RefListInput, type RefName, type RefPatterns, type RefProtection, type RefPublication, type RefPush, type RefSource, type RefUpdate, type RefUpdateKind, type RefUpdated, type RefView, refs_d_exports as Refs, type RefsPrivateOperation, type RefsUpdateInput, type RefsUpdated, type RefusalReason, type RejectInput, type Rejected, type ReleaseResult, type Released, type RemoteCalls, type RemoteOptions, type RemoteRefsInput, type RemoveResult, type Removed, type RenamesSkipped, type RepackOptions, type RepoAccess, type RepoCalls, type RepoCatalogueEntry, type RepoCreateInput, type RepoCreated, type RepoDeleted, type RepoDeletedEvent, type RepoEnvelope, type RepoEvent, type RepoGetInput, type RepoIndexHold, type RepoIndexRefused, type RepoInfo, type RepoInfoStats, type RepoInput, type RepoJobFailed, type RepoListInput, type RepoListOperation, type RepoListOrder, type RepoMaintained, type RepoName, type RepoOperation, type RepoRecord, repo_records_d_exports as RepoRecords, type RepoRenameInput, type RepoRenamed, type RepoStats, type RepoStreamEvent, type RepoUpdateInput, type RepoVisibilityChanged, type RepoWork, type RepoWorkFailed, type Report, type ReportDetails, type ReportOptions, type ReportResult, type Reported, repos_d_exports as Repos, ResourceContext, ResourceReason, layer_d_exports as Rest, client_d_exports$1 as RestClient, type RestClientCalls, type RestEvents, type RestTokenCalls, type RestartResult, type Restarted, type Result, type Retried, type RetryResult, type Revision, type RowsMoved, type RuleOperation, rules_d_exports as Rules, saved_callers_public_d_exports as SavedCallers, type SavedHandlerOptions, type ScheduleOption, type ServerCalls, type ServerSetup, type ShareInput, public_d_exports$5 as SignIn, type Signature, type SliceRefusal, type StageInput, type Staged, type StepAnswer, type StepInput, type Success, type Tag, type TagCalls, type TagCreateInput, type TagFields, tags_d_exports as Tags, type TargetHoldInput, type TokenCalls, type TokenCoverage, type TokenCreateInput, type TokenCreateOperation, type TokenEvent, type TokenEventFields, type TokenFields, type TokenId, type TokenInfo, type TokenListInput, type TokenOperation, type TokenParties, type TokenRecord, type TokenScope, type TokenState, type TokenTarget, tokens_public_d_exports as Tokens, type TokensFeature, type Topic, type TopicAddInput, type TopicAdded, type TopicCalls, type TopicCandidate, type TopicEntry, type TopicEntryInput, type TopicEnvelope, type TopicEvent, type TopicFailed, type TopicFailure, type TopicFailureReason, type TopicId, type TopicListInput, type TopicMerged, type TopicMergedEntry, type TopicOpened, type TopicOperation, type TopicRemoved, type TopicReportInput, type TopicReportOptions, type TopicReportQuestion, type TopicReported, type TopicState, type TopicTarget, type TopicWait, type TopicWorkFailed, public_d_exports$6 as Topics, type TopicsFactory, type TransportFailure, type TransportRetry, type TreeCalls, type TreeChange, type TreeChanges, type TreeCreateInput, type TreeDiffInput, type TreeEdit, type TreeEntry, TreeFilter, type TreeInput, type TreeMergeInput, trees_d_exports as Trees, type TrustedWriteInput, UnavailableContext, UnavailableReason, type UnpackOptions, Verdict, type VerifiedToken, type WalkInput, type WebApproval, type WebAuthorize, type WebExchange, type WholeObject, type WithoutActor, type WithoutSignal, work_d_exports as Work, type WorkCalls, type WorkItem, type WorkListInput, type WorkOperation, type WorkWriteInput, type WriteInput, accept, allotmentWithin, branchRef, createGitServer, gitError, gitPathOf, grantScopes, httpStatus, isGitError, isInternalId, isRefusalReason, jobStates, lfs, lfsPointerOid, lfsPointers, loose, looseLimits, maxActorIdLength, maxLfsPointerBytes, maxRefNameLength, mergeQueue, objectsReadMost, packs, packsMemory, peelMost, peelTagsMost, reject, shortTarget, tokenScopes, tokenStates, topics };
90
+ export { type Accepted, type AccessOption, type Acting, type Actor, type ActorId, type ActorInput, type AddResult, type Added, type Allotment, type AnonymousActor, type ApprovalBase, type ApprovalDecision, type ApprovalPageContext, type ApprovalPageInput, type ApprovalPrompt, type ApprovedGrant, auth_namespace_d_exports as Auth, type AuthInput, authorize_d_exports as Authorize, type AuthorizeAnswer, type AuthorizeInput, type Awaitable, type BasicCredential, type BatchOptions, type BearerCredential, type BeforeAfter, BeginPushUpload, type Bisect, type Blob, type BlobCalls, type BlobCreateInput, BlobLimit, BlobNone, blobs_d_exports as Blobs, type BypassOperation, type Bytes, type CallInput, type Caller, type CallerGrant, type Candidate, type CandidateCloseReason, type CandidateClosed, type CandidateClosedFields, type CandidateId, type CandidateOpened, type CandidateReportInput, type CandidateReported, type CandidateResult, type CandidateState, type CandidatesResult, type ClientAdapter, type ClientCredential, type ClientCredentials, type ClientFetchInput, type ClientFetchResult, type ClientPushInput, type Commit, type CommitCalls, type CommitCreateInput, type CommitDiffInput, commits_d_exports as Commits, type Compare, type CompareInput, type ComparisonFile, type ConfirmApprovalPage, ContextValue, type CopyRow, type CopyRowsInput, type CopyRowsPage, type CreatedObject, type CreatedToken, type CredentialInput, type Credentials, type CredentialsBasic, type CredentialsBearer, DataLossContext, DataLossReason, type DecisionAnswer, type DeniedGrant, type DeviceApproval, type DeviceCodePage, type DeviceCodeRequest, type DeviceCodeResponse, type DeviceExchange, type DiffListing, type EffectiveLimits, type Entry, type EntryAdded, type EntryFailed, type EntryFailureReason, type EntryFields, type EntryGroups, type EntryHoldInput, type EntryHoldsInput, type EntryId, type EntryMerged, type EntryRemoved, type EntryResult, type EntryRetried, type EntryState, ErrorContext, type EventEnvelope, type EventFeature, event_streams_d_exports as EventStreams, events_d_exports as Events, ExistingContext, ExistingReason, type FailureResult, type FeedItem, type FenceReason, type FencedPack, type FetchAdjustment, type FetchAnswer, type FetchReadInput, type FetchReadTarget, FetchRequest, type FetchRule, type FetchRuleInput, type File, type FileCalls, type FileDiff, type FileReadInput, type FileRuleOptions, files_d_exports as Files, type FilesAllowOperation, type FilesDiffInput, type FilesListInput, type FilesRead, Filter, FinishPushUpload, type ForkCalls, type ForkCreateInput, type ForkFetched, type ForkGetInput, type ForkHolder, type ForkListInput, type ForkOperation, forks_d_exports as Forks, git_namespace_d_exports as Git, type GitAdapter, type GitAuth, type GitAuthorize, client_d_exports as GitClient, type GitClientCalls, type GitClientOptions, type GitError, GitErrorBody, type GitErrorCode, type GitErrorContexts, type GitErrorFields, type GitErrorInput, type GitErrorTagged, type GitEvent, git_events_d_exports as GitEvents, public_d_exports as GitHooks, type GitNeeds, type GitObject, type GitObjects, type GitScope, type GitServer, type GitServerOptions, type GitStore, type GitStoreAddInput, type GitStoreCommitInput, type GitStoreReadInput, type Grant, type GrantAgainInput, type GrantAgainRequest, type GrantInput, type GrantReachInput, type GrantResolver, type GrantScope, type HandlerOptions, type Held, type HeldPack, type HiddenSpan, type Hold, type HoldEvent, type HoldEventFields, type HoldFields, type HoldId, type HoldResult, type Holding, type HoldingsInput, type HoldingsWalked, type HoldsResult, HostErrorContext, type HostFunctionName, type ImportState, type IndexCalls, type IndexReachInput, type IndexReached, type IndexRefusal, type IndexStatus, type IndexTip, type IndexTry, type IndexTryInput, InternalRepoId, InvalidInputContext, InvalidInputReason, type JoinInput, type Judged, type LanesInput, public_d_exports$1 as Lfs, type LfsCalls, type LfsFeature, type LfsGetInput, type LfsObject, type LfsOptions, type LfsPointers, type LfsPointersBuilder, type LineCounts, type LinkedObjects, type Listed, type ListedInput, type ListenInput, type Localize, type LogInput, type MaintainInput, type Me, type MeOperation, type MergeAnswer, type MergeBaseInput, type MergeBases, type MergeCalls, type MergeCreateInput, type MergeInput, type MergeLabels, type MergeMethod, type MergePlan, public_d_exports$2 as MergeQueue, type MergeQueueCalls, type MergeQueueLayerOptions, type MergeQueueOptions, type MergeTree, public_d_exports$3 as Merges, type MetaValue, MissingContext, MissingReason, type NamedActor, NotAllowedContext, NotAllowedReason, type OAuthClient, type OAuthError, type OAuthTokenResponse, type ObjectHeader, type ObjectHeadersInput, type ObjectInput, type ObjectReadInput, type ObjectReadResult, type ObjectReader, type ObjectReaderInput, type ObjectSizesInput, type ObjectType, type ObjectWrite, type ObjectWrites, objects_namespace_d_exports as Objects, type ObjectsChange, type ObjectsFactory, type ObjectsFetchInput, type ObjectsOpenInput, type ObjectsRead, type ObjectsReadInput, type ObjectsStarting, type ObjectsStartingInput, type ObjectsStep, type Oid, type Operation, type OperationKind, type Option, type Pack, type PacksMemory, type PacksOptions, type PagedInput, type PathObject, type PeelInput, type Peeled, type PinnedRepo, policy_d_exports as Policy, PreconditionContext, PreconditionReason, type PrefixTarget, type Prepare, type PrepareInput, type PreviousQueueSchedule, public_d_exports$4 as PrivateRefs, type ProtectOptions, type ProvidedBy, type PushContext, type PushFacts, type PushHookInput, type PushOperation, type PushOptions, type PushRule, type PushRuleInput, type PushUploadOptions, PushUploadPart, PushUploadStarted, type PushedCommit, type PushedCommitsInput, type Quarantine, type QueueAddInput, type QueueAddOperation, type QueueCandidateOperation, type QueueEntryOperation, type QueueEvent, type QueueFailureCounts, type QueueInternals, type QueueKeys, type QueueListInput, type QueueListResult, type QueueMeta, type QueueOf, type QueueRecent, type QueueReleaseOperation, type QueueRestarted, type QueueTargetInput, type QueueTargetOperation, type QueueView, type ReadLimits, type ReadObject, type ReadObjects, type ReadOptions, type ReadPage, type ReceiveInput, type Ref, type RefAudience, type RefCalls, type RefCount, type RefCountInput, type RefEdit, type RefForced, type RefInput, type RefListInput, type RefName, type RefPatterns, type RefProtection, type RefPublication, type RefPush, type RefSource, type RefUpdate, type RefUpdateKind, type RefUpdated, type RefView, refs_d_exports as Refs, type RefsPrivateOperation, type RefsUpdateInput, type RefsUpdated, type RefusalReason, type RejectInput, type Rejected, type ReleaseResult, type Released, type RemoteCalls, type RemoteOptions, type RemoteRefsInput, type RemoveResult, type Removed, type RenamesSkipped, type RepackOptions, type RepoAccess, type RepoCalls, type RepoCatalogueEntry, type RepoCreateInput, type RepoCreated, type RepoDeleted, type RepoDeletedEvent, type RepoEnvelope, type RepoEvent, type RepoGetInput, type RepoIndexHold, type RepoIndexRefused, type RepoInfo, type RepoInfoStats, type RepoInput, type RepoJobFailed, type RepoListInput, type RepoListOperation, type RepoListOrder, type RepoMaintained, type RepoName, type RepoOperation, type RepoPruneRefused, type RepoRecord, repo_records_d_exports as RepoRecords, type RepoRenameInput, type RepoRenamed, type RepoStats, type RepoStreamEvent, type RepoUpdateInput, type RepoVisibilityChanged, type RepoWork, type RepoWorkFailed, type Report, type ReportDetails, type ReportOptions, type ReportResult, type Reported, repos_d_exports as Repos, ResourceContext, ResourceReason, layer_d_exports as Rest, client_d_exports$1 as RestClient, type RestClientCalls, type RestEvents, type RestTokenCalls, type RestartResult, type Restarted, type Result, type Retried, type RetryResult, type Revision, type RowsMoved, type RuleOperation, rules_d_exports as Rules, saved_callers_public_d_exports as SavedCallers, type SavedHandlerOptions, type ScheduleOption, type ServerCalls, type ServerSetup, type ShareInput, public_d_exports$5 as SignIn, type Signature, type SliceRefusal, type StageInput, type Staged, type StepAnswer, type StepInput, type Success, type Tag, type TagCalls, type TagCreateInput, type TagFields, tags_d_exports as Tags, type TargetHoldInput, type TokenCalls, type TokenCoverage, type TokenCreateInput, type TokenCreateOperation, type TokenEvent, type TokenEventFields, type TokenFields, type TokenId, type TokenInfo, type TokenListInput, type TokenOperation, type TokenParties, type TokenRecord, type TokenScope, type TokenState, type TokenTarget, tokens_public_d_exports as Tokens, type TokensFeature, type Topic, type TopicAddInput, type TopicAdded, type TopicCalls, type TopicCandidate, type TopicEntry, type TopicEntryInput, type TopicEnvelope, type TopicEvent, type TopicFailed, type TopicFailure, type TopicFailureReason, type TopicId, type TopicListInput, type TopicMerged, type TopicMergedEntry, type TopicOpened, type TopicOperation, type TopicRemoved, type TopicReportInput, type TopicReportOptions, type TopicReportQuestion, type TopicReported, type TopicState, type TopicTarget, type TopicWait, type TopicWorkFailed, public_d_exports$6 as Topics, type TopicsFactory, type TransportFailure, type TransportRetry, type TreeCalls, type TreeChange, type TreeChanges, type TreeCreateInput, type TreeDiffInput, type TreeEdit, type TreeEntry, TreeFilter, type TreeInput, type TreeMergeInput, trees_d_exports as Trees, type TrustedWriteInput, UnavailableContext, UnavailableReason, type UnpackOptions, Verdict, type VerifiedToken, type WalkInput, type WebApproval, type WebAuthorize, type WebExchange, type WholeObject, type WithoutActor, type WithoutSignal, work_d_exports as Work, type WorkCalls, type WorkItem, type WorkListInput, type WorkOperation, type WorkWriteInput, type WriteInput, accept, allotmentWithin, branchRef, createGitServer, gitError, gitPathOf, grantScopes, httpStatus, isGitError, isInternalId, isRefusalReason, jobStates, lfs, lfsPointerOid, lfsPointers, logEmailsMost, loose, looseLimits, maxActorIdLength, maxLfsPointerBytes, maxRefNameLength, maxSeenRefs, mergeQueue, objectsReadMost, packs, packsMemory, peelMost, peelTagsMost, reject, shortTarget, tokenScopes, tokenStates, topics };