MCPcopy Create free account

hub / github.com/PerpetualSoftware/pad / functions

Functions31,685 in github.com/PerpetualSoftware/pad

↓ 3 callersMethoddrop
(reason string)
internal/watchevents/observer.go:179
↓ 3 callersFunctiondropFileIntoEditor
( page: Page, filename: string, base64: string, mimeType = 'image/png', editorSelector = '.editor-content
web/e2e/lib/attachment-viewer.ts:662
↓ 3 callersFunctiondropPostgresDB
(tb testing.TB, baseURL, dbName string)
internal/store/storetest/postgres.go:224
↓ 3 callersFunctiondropPostgresTemplateDB
(tb testing.TB, baseURL, name string)
internal/store/store_test.go:330
↓ 3 callersFunctiondueOf
dueOf is the instant the fire pass fires the outstanding occurrence: the override if set, else the occurrence, less the lead.
internal/store/schedule_carry_matrix_test.go:45
↓ 3 callersFunctiondurationsByCollection
durationsByCollection turns per-collection samples into median+count entries, ordered by count desc then slug.
internal/store/reports.go:992
↓ 3 callersFunctioneditor
()
web/src/lib/components/editor/frontmatterRoundtrip.svelte.test.ts:74
↓ 3 callersFunctioneditor
()
web/src/lib/components/editor/canonicalMarkdown.svelte.test.ts:116
↓ 3 callersFunctioneditorMounts
()
web/src/lib/components/items/itemDetailTouchEdit.svelte.test.ts:238
↓ 3 callersMethodeffectivePurgeRetention
effectivePurgeRetention returns the retention window the purge sweeper actually enforces: the SetWorkspacePurgeConfig override when set (PAD_WORKSPACE
internal/server/workspace_purge.go:89
↓ 3 callersMethodemailConfigured
emailConfigured reports whether this instance can actually SEND an emailed link — a sender is wired AND the public base URL is usable. This is the DR-
internal/server/server.go:1281
↓ 3 callersFunctionemailNotVerifiedPayload
(message string)
internal/mcp/errors.go:1655
↓ 3 callersMethodemit
emit prints one chat line to the agent and, once that write succeeded, appends the same line to the chat-seen log. Every chat line goes through here a
cmd/pad/cmd_watch_chat.go:162
↓ 3 callersMethodemitCommentEventAsInstallTx
emitCommentEventAsInstallTx is emitCommentEventTx for an installed app's write; see emitItemEventAsInstallTx.
internal/store/event_outbox.go:1121
↓ 3 callersMethodemitItemEventAsInstallTx
emitItemEventAsInstallTx is emitItemEventTx for a write an installed app made: actorInstall is frozen into the app-projection block as actor_via_app (
internal/store/event_outbox.go:1082
↓ 3 callersFunctionemitRealPadJSON
emitRealPadJSON builds the real pad cobra tree and emits its JSON representation with a static (no-resolver, no live-workspace) configuration. Tests t
cmd/pad/cmdhelp_real_test.go:23
↓ 3 callersMethodemitRefOnlyDeletionWithProjectionTx
emitRefOnlyDeletionWithProjectionTx is emitRefOnlyDeletionTx carrying a comment's app-projection block, which the caller computed before the delete ch
internal/store/event_outbox.go:1481
↓ 3 callersFunctionencode
(t *testing.T, m map[string]any)
internal/appmanifest/manifest_test.go:37
↓ 3 callersFunctionendDrag
()
web/src/lib/components/editor/block-drag-handle.ts:757
↓ 3 callersMethodendGuardCounts
TASK-4537: a done or skip that would end the schedule of an open item is refused unless the caller consents. Runs on SQLite in make test and on Postgr
internal/store/schedule_end_guard_test.go:20
↓ 3 callersMethodenforceUserPlanLimit
enforceUserPlanLimit checks a user-scoped plan limit and writes a 403 error if the limit is exceeded. Returns true if the operation is allowed. In non
internal/server/handlers_cloud.go:1675
↓ 3 callersFunctionensureSkills
ensureSkills detects AI tools, installs missing skill files, and updates outdated ones. Returns a summary of what it did.
cmd/pad/init.go:542
↓ 3 callersFunctionentryAtWall
(t *testing.T, es []AgendaEntry, wall string)
internal/store/occurrence_role_history_test.go:60
↓ 3 callersFunctionentryKey
(entry: AgendaEntry)
web/src/lib/calendar/presentation.ts:116
↓ 3 callersFunctionentryOf
(t *testing.T, d *upgradeDiff, kind, key string)
internal/server/app_upgrade_diff_test.go:48
↓ 3 callersFunctionentryStates
(m map[string]any, title string)
internal/server/handlers_calendar_test.go:622
↓ 3 callersFunctionenvDataDir
envDataDir is the ONE reader of PAD_DATA_DIR and PAD_DB_PATH (Load and userConfigPath both call it): PAD_DATA_DIR sets the data dir and its pad.db; PA
internal/config/config.go:365
↓ 3 callersFunctionenvTokenNotice
envTokenNotice returns a one-line warning when PAD_TOKEN is set, or "" when it isn't. login/logout print it to stderr (gh-style) so users aren't surpr
cmd/pad/cmd_auth.go:883
↓ 3 callersMethoderaseUserTxCtx
eraseUserTx removes one account and every reference to it, in the caller's transaction: the de-identify, outbox scrub, delete and final delete steps o
internal/store/users.go:1889
↓ 3 callersFunctionerrorCodeOf
(t *testing.T, res *CallToolResult)
internal/mcp/agenda_audience_test.go:10
↓ 3 callersFunctionerrorResult
errorResult is an error result carrying plain text. Prefer NewErrorResult (errors.go), which carries a structured envelope, wherever a code applies.
internal/mcp/result.go:29
↓ 3 callersFunctionescapeHTML
escapeHTML exists to keep byte parity with escapeHtml in web/src/lib/markdown/attachments.ts (TASK-4195). html.EscapeString emits `"` for a double
internal/server/render/attachments.go:177
↓ 3 callersFunctionescapeTable
escapeTable replaces newlines and pipes so a value can sit in a markdown table cell without breaking the table grid.
internal/cmdhelp/md.go:298
↓ 3 callersMethodestablishSubscription
establishSubscription opens a workspace's Redis subscription and does not return until Redis has acknowledged it, the bound expires, or the CALLER's c
internal/events/redis_bus.go:1703
↓ 3 callersMethodetagKeyUsable
()
internal/appstore/appstore.go:85
↓ 3 callersFunctionev
(extra: Partial<ItemCommitmentView> = {}, o: Parameters<typeof offsets>[0] = {})
web/src/lib/commitment.test.ts:159
↓ 3 callersMethodevalComments
(t *testing.T, item *models.Item)
internal/decision/per_comment_test.go:34
↓ 3 callersMethodevaluateAndOpenGates
evaluateAndOpenGates records successful gates and their notices atomically.
internal/store/commitment_gates.go:789
↓ 3 callersFunctioneventIDs
(es []Event)
internal/events/redis_discarded_peak_test.go:88
↓ 3 callersFunctionexecMulti
execMulti executes multiple SQL statements by iteratively using database/sql's Exec which processes one statement at a time, then advancing past it us
internal/store/store.go:1064
↓ 3 callersFunctionexistenceClaimsIn
(root: Element)
web/src/test/existenceClaim.ts:22
↓ 3 callersMethodexitString
exitString describes how the child ended, once it has been reaped.
internal/materialize/supervisor.go:497
↓ 3 callersFunctionexpandAgendaSchedules
expandAgendaSchedules expands schedules over [from, to) in loc, stopping once clock() passes deadline, and maps each occurrence to an agendaEntry. The
internal/server/handlers_agenda.go:527
↓ 3 callersFunctionexpectNoDependents
(t *testing.T, what string, views map[string]map[string]any, ids ...string)
internal/server/handlers_commitment_gate_dependents_test.go:50
↓ 3 callersFunctionexpireDecisionBackoff
expireDecisionBackoff makes a held-for-backoff job claimable now, through the same release a superseding write would cause.
internal/decision/runner_test.go:690
↓ 3 callersFunctionexplainPlan
(t *testing.T, s *Store, query string, args ...any)
internal/store/bug3668_credential_lookup_index_test.go:58
↓ 3 callersFunctionextensionOf
(filename: string | null | undefined)
web/src/lib/attachments/display.ts:196
↓ 3 callersFunctionextractFieldFromJSON
(fieldsJSON, key string)
cmd/pad/cmd_workspace.go:1454
↓ 3 callersFunctionextractFieldString
extractFieldString reads a top-level scalar string from a JSON-encoded fields map. Returns "" when the JSON is empty, malformed, the key is missing, o
internal/server/handlers_items_open_children_guard.go:687
↓ 3 callersFunctionextractHash
extractHash pulls the hash component out of an "fs:<hash>" key and validates it. We require the canonical 64-char lowercase-hex sha256 form on every p
internal/attachments/fs_store.go:71
↓ 3 callersFunctionextractUnknownWorkspaceSlug
extractUnknownWorkspaceSlug pulls the slug from a CLI stderr like "workspace 'foo' does not exist" so the envelope can name it. Returns empty string i
internal/mcp/errors.go:906
↓ 3 callersFunctionfail
(rule: string)
web/src/lib/stores/chatThread.property.svelte.test.ts:222
↓ 3 callersFunctionfailingImportBundle
BUG-2892. ImportWorkspace minted the workspace through CreateWorkspace — its own committed write — BEFORE opening the transaction that carries every o
internal/store/import_workspace_husk_test.go:29
↓ 3 callersFunctionfamilyCollection
(t *testing.T, tmpl *WorkspaceTemplate, slug string)
internal/collections/templates_family_test.go:21
↓ 3 callersMethodfeed
feed walks the workspace feed for the seeded action by keyset pages of pageSize, as the web client does, until a page comes back short.
internal/server/bug3687_activity_visible_page_test.go:111
↓ 3 callersFunctionfeedStdin
feedStdin points os.Stdin at a pipe carrying s, and returns a restore func. The update command reads os.Stdin directly (io.ReadAll), not cmd.InOrStdin
cmd/pad/item_show_markdown_roundtrip_test.go:141
↓ 3 callersFunctionfenceDir
()
web/src/test/identityFenceSource.test.ts:21
↓ 3 callersFunctionfetchItem
($, ref)
plugin/hooks/register.js:402
↓ 3 callersMethodfetchItem
fetchItem retrieves a full models.Item via the api/v1/workspaces/{ws}/items/{ref} surface. Used by the related / implemented-by dispatchers which need
internal/mcp/dispatch_http_links.go:524
↓ 3 callersFunctionfetchWrite
* `fetch` for a direct WRITE that bypasses request() (TASK-2202): * attachment upload and transform, artifact import, checkout. Same rule as * reque
web/src/lib/api/client.ts:721
↓ 3 callersFunctionfieldDefFor
( collections: Collection[], collectionSlug: string | undefined, key: string, notStale = true, )
web/src/lib/collections/categoricalFieldValue.ts:54
↓ 3 callersFunctionfieldString
fieldString parses an item's fields JSON and returns the string value at key (or "" if absent).
internal/server/handlers_artifact_test.go:579
↓ 3 callersFunctionfieldValue
fieldValue decodes a fields blob: Postgres JSONB and SQLite TEXT render the same object differently.
internal/appstore/items_test.go:408
↓ 3 callersFunctionfilenameFromContentDisposition
filenameFromContentDisposition extracts the filename token from a Content-Disposition header value (e.g. `attachment; filename="foo.pad.md"`). Returns
internal/cli/client.go:2134
↓ 3 callersFunctionfilterAgentAttention
(attention []server.DashboardAttention)
cmd/pad/query.go:365
↓ 3 callersFunctionfindItemByRef
(items: Item[], ref: string)
web/src/lib/utils/markdown.ts:766
↓ 3 callersFunctionfindMatchingLinkID
(links []models.ItemLink, linkType, sourceID, targetID string)
cmd/pad/lineage.go:191
↓ 3 callersFunctionfinishAgendaWork
(resp *agendaResponse)
internal/server/agenda_work.go:189
↓ 3 callersMethodfire
(type: string, data?: unknown)
web/src/lib/services/sseLiveness.svelte.test.ts:55
↓ 3 callersMethodfirstActiveBlockers
firstActiveBlockers resolves, for every blocked target in the workspace, the FIRST blocker (newest link first) that the caller can see AND that is sti
internal/server/handlers_dashboard.go:260
↓ 3 callersMethodfirstAtLeast
firstAtLeast returns the first message logged at or above level, or "".
internal/watchevents/redis_bus_resume_test.go:643
↓ 3 callersFunctionfirstLine
firstLine returns the first line of s with surrounding whitespace trimmed. Useful for collapsing a multi-line Long string into a Summary.
internal/cmdhelp/json.go:513
↓ 3 callersFunctionfkCheckRuns
(t *testing.T, s *Store)
internal/store/bug3663_migration_025_test.go:243
↓ 3 callersFunctionflush
()
web/src/routes/[username]/[workspace]/dashboardPollGate.svelte.test.ts:112
↓ 3 callersFunctionflush
()
web/src/lib/stores/chatSurface.svelte.test.ts:677
↓ 3 callersMethodflushNow
Cancel the debounce, read the live editor markdown, and flush it now. * Returns false (no-op) when the editor is unavailable. Used by editor * t
web/src/lib/collab/collabFlush.svelte.ts:144
↓ 3 callersFunctionfmtWall
fmtWall renders a wall as "2026-11-09 09:00" (or the bare date when all-day).
cmd/pad/cmd_schedule.go:78
↓ 3 callersFunctionforEachTitleLink
forEachTitleLink calls fn(start, end) for every whole-body link to title, by the rule ReplaceTitle documents, in order and never overlapping. It is w
internal/links/links.go:77
↓ 3 callersMethodforWorkspace
(workspaceID string)
internal/server/handlers_watch_events.go:675
↓ 3 callersFunctionforecastCLI4359
Exercise the real write/read doors as well as the CLI wire formatting above. The CLI is built first because tzCLI writes time.Local, and the real ser
cmd/pad/task4359_forecast_test.go:114
↓ 3 callersMethodforgetPrefix
forgetPrefix drops every entry whose id starts with prefix.
cmd/pad/cmd_watch.go:103
↓ 3 callersFunctionformatFieldLabel
(value: unknown)
web/src/lib/utils/fieldColors.ts:143
↓ 3 callersFunctionformatMonitorLine
formatMonitorLine renders one notification as a single stdout line (the harness ingests each line as a session notification). A push carries the D5 au
cmd/pad/cmd_watch.go:200
↓ 3 callersFunctionframe
()
web/src/lib/scroll/restore.svelte.test.ts:26
↓ 3 callersMethodframe
()
web/e2e/lib/attachment-viewer.ts:378
↓ 3 callersFunctionfreeUser
TASK-3551 at the boot: a cloud boot marks the database, and a later non-cloud boot of the same database leaves its free users free instead of converti
cmd/pad/task3551_boot_plan_backfill_test.go:18
↓ 3 callersFunctionfreezeBucket
freezeBucket stops rl's bucket for the test client from refilling, so "spend the burst, then the next call is refused" holds however slowly the calls
internal/server/handlers_collab_bug1308_test.go:44
↓ 3 callersFunctionfullExportFixture
()
internal/models/export_stream_test.go:59
↓ 3 callersFunctionfullyUnescape
fullyUnescape decodes s until no escape remains. It reports false when the input is malformed, or is still encoded after maxUnescapePasses: text that
internal/logging/redaction.go:103
↓ 3 callersFunctiong4Cloud
(token string)
cmd/pad/task3321_g4_apps_challenge_test.go:16
↓ 3 callersMethodgapCooldown
gapCooldown is the interval a handler should use — midStreamGapCooldown unless a test has narrowed it. A field rather than the bare constant because
internal/server/stream_gap_announcer.go:36
↓ 3 callersFunctiongateFixture
BUG-3032: `pad db migrate-to-pg` is the only door that abandons its source database, so it is the only door that refuses rather than warns. These test
cmd/pad/cmd_db_unflushed_test.go:18
↓ 3 callersFunctiongateOnTombstone
A soft-deleted blocker travels only so that its gate can still be judged. The row must not take anything from the live items beside it, and must not p
internal/store/schedule_gate_tombstone_test.go:15
↓ 3 callersMethodgatedSource
Gates stay within one workspace (TASK-4353). A cross-workspace copy or move of a GATED item cannot carry them: the copy starts with none (the source k
internal/store/schedule_carry_gates_test.go:19
↓ 3 callersMethodgatesDropped
---- carrying the gated item to another workspace ---- gatesDropped counts the gates that hold itemID whose blocker canRead accepts (nil accepts every
internal/store/commitment_gates.go:938
↓ 3 callersFunctiongenerateCSPNonce
generateCSPNonce generates a cryptographically random nonce for Content-Security-Policy headers. Returns a 16-byte base64-encoded string.
internal/server/middleware_security.go:56
↓ 3 callersFunctiongenerateCSRFToken
generateCSRFToken returns a cryptographically random hex string.
internal/server/middleware_csrf.go:343
↓ 3 callersFunctiongenerateRecoveryCodes
generateRecoveryCodes produces n random recovery codes. Each code is 10 bytes (80 bits) of cryptographic randomness encoded as unpadded base32 — 16 vi
internal/server/handlers_2fa.go:555
↓ 3 callersFunctiongetCodeContext
(t *testing.T, srv *Server, path string)
internal/server/handlers_items_github_pr_test.go:23
↓ 3 callersMethodgetCollectionAnyStateQ
getCollectionAnyStateQ is GetCollectionAnyState against a caller-supplied executor.
internal/store/collections.go:330
← previousnext →5,601–5,700 of 31,685, ranked by callers