MCPcopy Create free account

hub / github.com/PerpetualSoftware/pad / functions

Functions28,840 in github.com/PerpetualSoftware/pad

↓ 8 callersFunctionrecordingServer
(t *testing.T)
cmd/pad/item_stdin_blank_test.go:51
↓ 8 callersMethodrecurring
recurring makes item i's schedule daily at 09:00 UTC from its first day.
internal/store/commitment_gates_outcome_test.go:21
↓ 8 callersFunctionredactAttr
redactAttr is a backstop for structured application logs, including With attributes and groups. Call sites handling external input should still use th
internal/logging/redaction.go:264
↓ 8 callersFunctionredactLinkError
redactLinkError replaces a pure-layer error by one that cannot name a node or show a count (LinkError.Path carries node ids; LimitError.Got is Limit+1
internal/store/commitment_links.go:91
↓ 8 callersMethodredeem
redeem is §6's POST /api/app/v1/context/redeem: no workspace in the path, the token's own.
internal/server/task3414_item_actions_test.go:78
↓ 8 callersFunctionregisterGuardedDrivers
registerGuardedDrivers registers the wrapping driver names once per process. The base driver is taken from a throwaway sql.DB rather than from a driv
internal/store/nulguard.go:508
↓ 8 callersMethodrelationVisibility
relationVisibility binds the request-scoped half of the visibility rule into a callback the store can run on ITS executor. This is what lets the copy
internal/server/relation_referents.go:430
↓ 8 callersFunctionrender
(body: string, refs: ChatRef[] = [], ws?: string)
web/src/lib/chat/markdown.svelte.test.ts:19
↓ 8 callersFunctionrenderMarkedWithAttachments
( content: string, ctx: { resolver: AttachmentResolver; workspaceSlug: string; imageVariant?: 'thumb-s
web/src/lib/utils/markdown.ts:598
↓ 8 callersFunctionrenegotiateCall
(f *schedHTTP, u *models.User, body any)
internal/server/handlers_commitments_test.go:343
↓ 8 callersFunctionreopenState
(t *testing.T, s *Store)
internal/store/schedule_reopen_test.go:16
↓ 8 callersMethodreplaceRelationLinks
The materialised reverse index for `relation` field values (PLAN-2857 U5 / TASK-2997). See migration 088 for why it is materialised and why it is its
internal/store/relation_links.go:46
↓ 8 callersMethodrequestSessionInfo
requestSessionInfo is the session the request was authenticated with, or nil. It follows the credential the middleware recorded (ctxAuthKind) rather t
internal/server/handlers_account.go:66
↓ 8 callersFunctionrequestUserAgent
requestUserAgent returns the User-Agent header as text the database can store, replacing any invalid UTF-8 and dropping any NUL. A header is not a pa
internal/server/middleware_request_text.go:905
↓ 8 callersMethodrequireActiveUserTx
requireActiveUserTx is the one gate every credential-minting insert passes (BUG-3349): it reads the user's row inside the insert's own transaction, FO
internal/store/users.go:1159
↓ 8 callersFunctionrequirePostgresForConcurrency
requirePostgresForConcurrency skips a test unless a real PostgreSQL backend is configured. The parent-link TOCTOU races (BUG-2073) are Postgres-only:
internal/store/parent_link_concurrency_test.go:19
↓ 8 callersMethodresolve
(t *testing.T, i int, state string)
internal/store/commitment_gates_outcome_test.go:37
↓ 8 callersMethodresolveAssignName
resolveAssignName rewrites a `--assign <name|email>` input into `assigned_user_id <uuid>` by hitting the workspace-members endpoint and finding a matc
internal/mcp/dispatch_http_advanced.go:31
↓ 8 callersMethodresolveDone
(t *testing.T)
internal/store/milestone_test.go:72
↓ 8 callersMethodresolveItemCollectionSlug
resolveItemCollectionSlug resolves a user-supplied collection slug against the workspace's ACTUAL collections, so a regular singular/plural pair works
internal/server/collection_resolve.go:48
↓ 8 callersFunctionresult
(c *models.Commitment)
internal/store/milestone_test.go:77
↓ 8 callersFunctionroomFor
(t *testing.T, mgr *RoomManager, itemID string)
internal/collab/restore_coord_test.go:31
↓ 8 callersFunctionrunEdit
runEdit runs `pad item edit TASK-5 [extra...]` against the stub with a fake editor that announces itself on stderr and appends a line. It returns stdo
cmd/pad/bug3035_edit_guard_test.go:87
↓ 8 callersMethodrunRowlessBlobSweep
runRowlessBlobSweep reclaims blobs that NO attachments row references — the leak class the row-driven sweep above cannot see (BUG-2406). Every write p
internal/server/orphan_gc.go:375
↓ 8 callersFunctionrunTwoFactorDisable
runTwoFactorDisable asks for whichever proof the account takes: its password, or, for an account with none (#1879), a current code or a recovery code.
cmd/pad/cmd_auth_2fa.go:226
↓ 8 callersFunctionrunTwoFactorSetup
(client *cli.Client, in *bufio.Reader, out io.Writer)
cmd/pad/cmd_auth_2fa.go:86
↓ 8 callersFunctionrunUpdate
(t *testing.T, args ...string)
cmd/pad/item_update_outcome_test.go:63
↓ 8 callersFunctionsafeText
(raw: unknown)
web/src/lib/fields/fieldShape.ts:69
↓ 8 callersFunctionschedErrDetails
(t *testing.T, rr *httptest.ResponseRecorder)
internal/server/handlers_commitments_http_test.go:104
↓ 8 callersFunctionscopeClause
scopeClause is the visibility predicate on the item alias, as " AND ..." (empty when scope is unrestricted). The same three-way shape as models.ItemLi
internal/store/reminders.go:254
↓ 8 callersMethodseedAnswers
seedAnswers stores a Noul-shaped row per key for the item in the attention set, evaluated at `at`, as the runner would have left them.
internal/decision/effort_backfill_test.go:24
↓ 8 callersFunctionseedBackfillAccess
(t *testing.T, s *Store, requestID, clientID, subject string, ts time.Time, sessionData string)
internal/store/oauth_connections_backfill_test.go:81
↓ 8 callersFunctionseedClient
seedClient creates an oauth_clients row so chains have something to FK against. Returns the client ID.
internal/store/connected_apps_test.go:42
↓ 8 callersFunctionseedDormantLog
seedDormantLog appends n frames to a fresh item, ages them past an hour ago, flushes the watermark to the last, and returns the item and its max id.
internal/store/task3531_compaction_test.go:20
↓ 8 callersFunctionseedPermissionWalk
()
web/e2e/lib/permission-walk.ts:173
↓ 8 callersFunctionseedStoredRow
seedStoredRow writes body to the registry and creates a live attachment row with an arbitrary stored MIME + filename attached to itemID. The row shape
internal/server/handlers_attachments_download_mime_test.go:58
↓ 8 callersFunctionseedUser
seedUser creates a user that subsequent oauth tokens can use as their `subject`.
internal/store/connected_apps_test.go:61
↓ 8 callersMethodsend
(data: Uint8Array)
web/src/lib/collab/wsProvider.svelte.ts:1599
↓ 8 callersFunctionserveAttachment
serve issues a GET (method="GET") or HEAD against a seeded row and returns the recorder. variant, when non-empty, is appended as ?variant=.
internal/server/handlers_attachments_download_mime_test.go:99
↓ 8 callersMethodsetBlockerStatus
(t *testing.T, it *models.Item, status string)
internal/store/commitment_gates_outcome_test.go:292
↓ 8 callersMethodsetLimits
setLimits updates the bounds in place. In place rather than by replacing the gate, because a replacement silently OVER-GRANTS capacity: the new gate
internal/server/stream_admission.go:68
↓ 8 callersFunctionsetSortOrder
(t *testing.T, s *Store, id string, v int)
internal/store/items_new_item_top_test.go:44
↓ 8 callersMethodskipAs
(t *testing.T, i int, actor string)
internal/store/commitment_cancel_test.go:28
↓ 8 callersFunctionsniffISOBMFF
sniffISOBMFF returns the allowlisted MIME for an ISO-BMFF file this package recognises — a still image by any of its brands, or an audio/video contain
internal/attachments/mime_isobmff.go:124
↓ 8 callersMethodsoftDelete
A link whose parent or child item is soft-deleted (TASK-4418). Deleting the link must work; changing it, and any cascade through it, must not reach th
internal/store/commitment_links_deleted_end_test.go:15
↓ 8 callersFunctionsoftDeleteWorkspaceAt
softDeleteWorkspaceAt stamps a workspace's deleted_at to a specific time so the sweep's age cutoff can be exercised deterministically — there's no API
internal/server/workspace_purge_test.go:36
↓ 8 callersMethodspecialRoutes
specialRoutes maps cmdKeys to the dispatcher methods that handle them in place of a routeTable mapper — commands whose HTTP path needs read-modify-wri
internal/mcp/dispatch_http.go:460
↓ 8 callersFunctionsplitAfterManifest
BUG-3184, both halves. (1) ONE DOOR. `read tar entry` was the one importBundle error return that dropped the workspace it had already minted, so the
internal/server/handlers_import_bundle_bug3184_test.go:40
↓ 8 callersMethodsseSubscriberStillHasAccess
sseSubscriberStillHasAccess re-runs the workspace access check for an already-subscribed SSE client. Returns false when the caller can no longer see t
internal/server/handlers_events.go:1060
↓ 8 callersFunctionstageOldSeed
stageOldSeed makes the item hold oldContent with oldFields merged in, and records that as the text it was seeded with.
internal/server/task3462_builtin_update_test.go:36
↓ 8 callersFunctionstamped
(content, tab string, n int64)
internal/server/bug3080_client_write_test.go:25
↓ 8 callersFunctionstatBlob
(t *testing.T, srv *Server, key string)
internal/server/orphan_gc_test.go:761
↓ 8 callersMethodstillPending
(t *testing.T, inv *models.WorkspaceInvitation)
internal/server/handlers_invitation_accept_limit_test.go:51
↓ 8 callersMethodstoredRelationKey
storedRelationKey is storedRelation for a key other than owner_ref. Same reason it reads the database rather than the response: a handler that echoed
internal/server/relation_referents_doors_test.go:160
↓ 8 callersFunctionstreamClosedWithin
BUG-3007 — a stream must stop delivering when the CREDENTIAL that opened it is no longer valid. Both SSE endpoints revalidate something on a 60s jitt
internal/server/handlers_stream_session_liveness_test.go:46
↓ 8 callersMethodsweep
sweep walks the map, evicts entries older than ttl, and returns the eviction count. onChange fires once at the end with the new total — single observa
internal/server/middleware_mcp_session.go:146
↓ 8 callersFunctiontestServerPostgres
testServerPostgres returns a *Server backed by an ISOLATED PostgreSQL database (t.Skip unless PAD_TEST_POSTGRES_URL is set) with collab + an event bus
internal/server/handlers_item_versions_test.go:332
↓ 8 callersFunctiontokenAllowedWorkspaceMatches
tokenAllowedWorkspaceMatches reports whether the OAuth token's workspace allow-list (set at consent time, TASK-952) permits the given workspace slug.
internal/server/middleware_auth.go:1330
↓ 8 callersMethodtotpEnabled
(t *testing.T, id string)
cmd/pad/cmd_auth_2fa_test.go:86
↓ 8 callersMethodtouch
touch inserts or refreshes an entry. No-op on empty id (defensive: callers pre-filter, but a missing header should never bump anything). Fires onChang
internal/server/middleware_mcp_session.go:112
↓ 8 callersFunctiontransformAs
transformAs POSTs a rotate as a specific user + workspace role, bypassing the auth middleware the same way downloadAs does.
internal/server/handlers_attachments_transform_authz_test.go:95
↓ 8 callersFunctiontriStateEnv
triStateEnv sets up a live socket-keyed session in an auto_arm=true repo: HOME + PAD_DATA_DIR point at temp dirs, CLAUDE_CODE_MESSAGING_SOCKET is a re
internal/cli/session_arm_tristate_test.go:14
↓ 8 callersFunctiontwoMsgs
()
internal/notify/gateway_test.go:21
↓ 8 callersMethodunusable
unusable reports whether f cannot run work: finished, or not made by BeginFenced.
internal/store/fenced_tx.go:91
↓ 8 callersFunctionupdateFrame
updateFrame is a well-framed sync update carrying payload. The relay never decodes the payload, so its bytes need only be distinct per call site.
internal/store/bug3124_content_bearing_test.go:33
↓ 8 callersFunctionuploadItemFixture
uploadItemFixture creates a workspace + collection + item for the item_id-invariant tests, returning the workspace slug and the item.
internal/server/handlers_attachments_test.go:369
↓ 8 callersFunctionviewerDialog
(page: Page, name: string)
web/e2e/lib/attachment-viewer.ts:209
↓ 8 callersFunctionwantStatus
(t *testing.T, leg string, rr *httptest.ResponseRecorder, code int)
internal/server/bug3028_relation_blank_test.go:62
↓ 8 callersFunctionwebFS
(files map[string]string)
internal/server/web_build_identity_test.go:9
↓ 8 callersFunctionwithOwnerVerdict
BUG-2771: an arm-state file whose owner cannot be probed (the unknown verdict) used to be treated as dead: reaped on the next read, which handed the d
internal/cli/session_arm_unverifiable_bug2771_test.go:21
↓ 8 callersFunctionwithStdin
BUG-3100 (public mirror: GitHub #1391). `--stdin` with a blank body used to succeed: `item create` minted a content-less item and `item update` REPLAC
cmd/pad/item_stdin_blank_test.go:25
↓ 8 callersMethodwriteInstallLifecycleError
(w http.ResponseWriter, err error)
internal/server/handlers_apps_lifecycle.go:49
↓ 8 callersFunctionwriteScheduleNotFound
writeScheduleNotFound is the 404 for an item with no schedule.
internal/server/handlers_schedules.go:136
↓ 7 callersMethod#guard
A guard for one async step: false once the thread was reopened, disposed or re-fenced.
web/src/lib/stores/chatThread.svelte.ts:203
↓ 7 callersMethod#publishAfterWrite
Publish after a pending change; the window beyond stays beyond.
web/src/lib/stores/chatThread.svelte.ts:403
↓ 7 callersMethodAddCreatedWorkspaceIfPermitted
AddCreatedWorkspaceIfPermitted inserts a (request_id, workspace_id) row with added_by='agent-create', but ONLY while the connection still carries may_
internal/store/oauth_connections.go:566
↓ 7 callersFunctionAppItemETag
AppItemETag is the opaque concurrency token an app sees: HMAC-SHA256 over (install, item, seq) under a SERVER-ONLY key, truncated to 128 bits. The app
internal/store/fenced_items.go:105
↓ 7 callersMethodApply
Apply repairs a JSON body's NUL-carrying values when the flag is set, and returns the bytes the gate should judge. A nil tally, or one with the flag
internal/server/import_nul_repair.go:75
↓ 7 callersMethodBrowserURL
BrowserURL returns a URL suitable for displaying to humans in CLI prompts (e.g. "Or open the web UI at X"). It behaves like BaseURL except that when t
internal/config/config.go:863
↓ 7 callersFunctionBuildMetaPayload
(padVersion string)
internal/mcp/meta.go:89
↓ 7 callersFunctionBuiltinStateOf
BuiltinStateOf compares an item with the built-in it was made from. It returns the state, the item's hash over the LIBRARY's update fields, and the en
internal/collections/builtin.go:294
↓ 7 callersMethodBusyWorkers
BusyWorkers reads this user's activity in one batch, ignoring empty and duplicate workers and expired records. On error, known states may still be ret
internal/server/session_presence.go:314
↓ 7 callersMethodCheckSession
CheckSession returns the current auth status.
internal/cli/client.go:2333
↓ 7 callersMethodCheckUserLimit
CheckUserLimit checks a user-level limit (not workspace-scoped), such as total workspace count or total API tokens. This is an ADVISORY read on the p
internal/store/limits.go:188
↓ 7 callersMethodClaimIdempotencyKey
ClaimIdempotencyKey claims (workspace, user, key) for a request whose canonical hash is requestHash, or reports why it cannot.
internal/store/idempotency.go:54
↓ 7 callersMethodCompactedResumeCovers
CompactedResumeCovers reports whether a resume cursor is inside the item's compaction snapshot, which still exists (TASK-3531): such a tab is admitted
internal/collab/room.go:344
↓ 7 callersFunctionCompressResponses
CompressResponses gzips (or deflates) what the client accepts, except what compressSkips names.
internal/server/middleware_compress.go:91
↓ 7 callersFunctionConvertOpenAPI
ConvertOpenAPI converts an OpenAPI 3.x specification into a human-readable markdown document. The output is organized as: - H1 with the API title - I
internal/urlimport/openapi.go:30
↓ 7 callersMethodCopyItemPreflight
CopyItemPreflight runs the DRY RUN. It mutates nothing in the copy's own domain, so it is safe to call repeatedly and safe to retry. Returns the deco
internal/cli/client_items_copy.go:314
↓ 7 callersMethodCountLocked
CountLocked is the number of uploads holding hash. The caller holds Lock.
internal/attachments/inflight.go:61
↓ 7 callersMethodCreateView
CreateView adds a new saved view.
internal/store/views.go:11
↓ 7 callersMethodCreateWorkspaceGroup
(ctx context.Context, userID, name string, ids []string)
internal/store/workspace_groups.go:200
↓ 7 callersMethodDeleteItemGrant
DeleteItemGrant revokes an item grant by ID, scoped to a workspace. When it was the grantee's last access to the workspace, their workspace tab goes
internal/store/grants.go:208
↓ 7 callersMethodDeleteUserAPIToken
DeleteUserAPIToken removes an API token by ID, verifying it belongs to the user.
internal/store/api_tokens.go:280
↓ 7 callersFunctionDerivePrefix
DerivePrefix generates a short uppercase prefix from a collection name. Single word: first 3-5 letters, removing trailing "s" for plurals Multi-word:
internal/collections/prefix.go:63
↓ 7 callersFunctionDropBlankRelations
DropBlankRelations deletes the blank scalar relation keys for which keep is false (every one when keep is nil) and returns the keys it deleted.
internal/items/relation_blanks.go:47
↓ 7 callersMethodEnableUser
EnableUser re-enables a disabled user account by clearing disabled_at.
internal/store/users.go:1278
↓ 7 callersFunctionEnsureBootstrapToken
EnsureBootstrapToken generates a fresh first-run bootstrap token (or loads the existing one if a valid file is already present). Returns the token str
internal/server/bootstrap.go:66
↓ 7 callersFunctionEnsureStructuredEntryIDs
EnsureStructuredEntryIDs gives every implementation note and decision-log entry a PERSISTED id that nothing else in the blob claims (BUG-2788). An en
internal/models/structured_entry_ids.go:105
↓ 7 callersMethodGet
Get returns the current session workspace, or empty string when none has been set.
internal/mcp/workspace.go:72
← previousnext →2,001–2,100 of 28,840, ranked by callers