Repository navigation
Conversation
The declare body now carries `workflows`: each `base44/workflows/**/*.jsonc`
file, parsed as JSONC and sent raw, keyed by its path under the directory
with `.jsonc` stripped (`daily-digest`, `sub/x`), the key the platform's
`workflow_files_key` derives. Only `.jsonc`: to the platform a `.json` file
there is an ordinary file, not a workflow. Always sent, `{}` for an app with
none, since an absent field means a producer that cannot describe workflows.
The directory is `workflowsDir` in config.jsonc, default `workflows`, beside
`entitiesDir` and `agentsDir`.
Requires an apper that accepts `workflows` on DeclareVersionRequest; an
older one refuses the unknown field with a 422.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
🚀 Package Preview Available!Install this PR's preview build with npm: npm i @base44-preview/cli@0.3.1-pr.691.71865f0Prefer not to change any import paths? Install using npm alias so your code still imports npm i "base44@npm:@base44-preview/cli@0.3.1-pr.691.71865f0"Or add it to your {
"dependencies": {
"base44": "npm:@base44-preview/cli@0.3.1-pr.691.71865f0"
}
}
Preview published to npm registry — try new features instantly! |
The platform counts any `.jsonc` under base44/workflows/ as a workflow, dot-files included, so `.draft.jsonc` is the workflow `.draft`. Skipping it here would record a version without a workflow the app has. Workflows only; entities and agents keep globby's default. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yurynix
marked this pull request as draft
November 3, 2026 12:44
Contributor
Author
|
Do not merge or release yet. apper's |
apper #37480 makes both fields required on POST versions: a declare without either is a 422 invalid_request for any app, and the conditional 409s (actors_undeclared, workflows_undeclared) are gone. The CLI already always sends both, so only the wording changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note
Description
base44 publishnow declares the app's workflow files alongside its entities and agents, so a recorded version captures the workflows the build produced. The payloads go up raw — keyed the way the platform names the same file — andworkflowsis always sent,{}for an app with none, because the platform requires the field and refuses a declare without it. Workflows follow the platform's own reading of that directory, which differs from entities and agents in two rules: only.jsonccounts (a.jsonfile there is an ordinary file), and dot-files count (.draft.jsoncis the workflow.draft).Related Issue
None
Type of Change
Changes Made
core/version/artifacts.ts:collectResourcesnow also reads the workflows directory and returns aworkflowsmap;readRawResourcestakes options for the extension glob and for including dot-files, so workflows are restricted toCONFIG_FILE_EXTENSION(.jsonc) and read withdot: true, while entities and agents keep{json,jsonc}and skip dot-files. Keys are the file path with the extension stripped, soworkflows/daily-digest.jsonc→daily-digest, a hidden.draft.jsonc→.draft, and a nested file keeps its relative path (sub/x).core/version/schema.ts: addedworkflows: Record<string, unknown>toArtifactSet, documented as always-sent ({}when empty); theactorscomment now states the same contract.core/version/api.ts:createVersionsendsworkflowsin the declare body.core/project/schema.ts: newworkflowsDirproject-config setting, defaulting toworkflows.core/project/target.ts:BuildTargetcarriesworkflowsDir(same default), resolved fromconfigDirlike the other resource directories.docs/versions.md: documented the workflows payload, the.jsonc-only and dot-files rules, the always-sent{}contract, and added theworkflowskeyword. Corrected theactorsnote: the platform requires the field on every declare and refuses a declare without it with 422invalid_request, not only for an app that has actors (409actors_undeclared).Testing
npm test)New/updated coverage:
tests/core/version-artifacts.spec.ts: keying by path (including nested), JSONC parsed and sent raw,.jsonc-only selection, a hidden.draft.jsoncbeing taken as a workflow, a parse failure naming the file (ConfigInvalidError), and reading from a configuredworkflowsDir.tests/cli/publish.spec.ts: the declare body carries the fixture's workflow and ignores the.jsonfile beside it; an app with no workflows declaresworkflows: {}.tests/core/project-target.spec.ts:workflowsDirin the resolved build target.tests/fixtures/publishable/base44/workflows/:daily-digest.jsoncand anotes.jsonthat must be ignored.Checklist
docs/(AGENTS.md) if I made architectural changesAdditional Notes
Behind the existing
BASE44_VERSIONS_APIgate, like the rest of the versions lane. Workflow payloads are deliberately not read through a validated resource reader — the platform's own extractor and validation are authoritative, matching how entities and agents are already handled. The dot-file rule is scoped to workflows:readRawResourcesdefaults todot: false, so entity and agent collection is unchanged.🤖 Generated by Claude | 2026-11-04 12:54 UTC | 48ac1e4