Conversation
|
|
||
| Upload changelog entries or bundle artifacts to S3 or Elasticsearch. The command discovers `.yaml` and `.yml` files in a local directory and uploads only files whose content hash changed since the last run. Changelog entries are uploaded once under `changelog/{org}/{repo}/{branch}/{file}`, keyed by the authoring owner, repository, and branch; bundles are uploaded under `bundle/{product}/{file}`, product-scoped from the bundle YAML. | ||
| Upload changelog entries or bundle artifacts to S3 or Elasticsearch. | ||
| The command discovers `.yaml` and `.yml` files in a local directory and by default uploads only files whose content hash changed since the last run. |
There was a problem hiding this comment.
This sentence now overstates default behavior. With this PR, a file whose content differs from an existing remote key is not uploaded by default; it is refused unless --overwrite (or --skip-etag-check) is set.
Could you reword this line to mention both parts of the default behavior: unchanged files are skipped, and changed existing keys are refused unless overwrite is requested?
| /// <param name="skipEtagCheck">Upload every discovered file even when its content hash matches the remote object. Use to re-trigger downstream scrubbers without changing file content. Implies --overwrite.</param> | ||
| /// <param name="overwrite">Replace remote objects whose content differs. Today upload still replaces those objects even if you omit this flag. Pass it so GitHub Actions keep working after a later release that replaces only when the flag is set.</param> | ||
| /// <param name="skipEtagCheck">Upload every discovered file even when its content hash matches the remote object. Each upload emits s3:ObjectCreated, which re-triggers the scrubber Lambda on the private bucket. Default behavior (without this flag) skips unchanged files. Also replaces objects whose content differs, so you do not need --overwrite as well.</param> | ||
| /// <param name="overwrite">Replace remote objects whose content differs. Omit this flag to skip replacing those existing objects. Unchanged (ETag match) files and PR-alias markers are still skipped. Use --skip-etag-check to upload those too. When a replacement is refused, the warning includes the existing remote object.</param> |
There was a problem hiding this comment.
This help text sounds unconditional, but the implementation can’t always include the existing remote object content. When GetObject fails, the warning falls back to a "Could not fetch ..." message.
Can we qualify this wording (for example, "when readable") so CLI help doesn’t promise remote content in every refusal case?
|
Reverted to simpler #4136 |
This PR must be merged after (1) #4075, and (2) elastic/docs-actions#346
Summary
Omitting
--overwritenow leaves a different remote object in place and exits non-zero.This change must occur only after the docs-actions have been updated to include
--overwriteso their behaviour is unchanged.Details
If-None-Match: *--overwrite), exit non-zero--overwrite--skip-etag-checkThe CLI maps
Overwrite = overwrite || skipEtagCheck.S3UploadOptionsandChangelogUploadArgumentsdefaultOverwriteto false. Docs anddocs/cli-schema.jsonsay the same thing.Tests cover default refuse,
--overwritereplace, skip-etag Put, and new-keyIf-None-Match: *.Generative AI disclosure
Tool(s) and model(s) used: Cursor Grok 4.6