Conversation
8153360 to
1a78ddf
Compare
📝 WalkthroughWalkthroughThis PR adds an optional top-level Sequence Diagram(s)sequenceDiagram
participant YAML as Bundle YAML
participant Loader as BundleLoader
participant Ser as ReleaseNotesSerialization
participant DTO as BundleDto
participant Model as Bundle
participant Merger as MergeBundleGroup
participant Service as ChangelogRenderingService
participant Context as ChangelogRenderContext
participant Renderer as Markdown/Asciidoc Renderer
participant Output
YAML->>Loader: Load bundle files
Loader->>Ser: Deserialize into BundleDto
Ser->>Model: Parse dto.ReleaseDate -> Bundle.ReleaseDate (DateOnly?)
Loader->>Merger: Merge bundles for same target
Merger->>Model: Aggregate distinct ReleaseDate values (dedupe)
Service->>Model: Collect bundle ReleaseDate(s)
Service->>Service: Validate distinct dates (warn if >1)
Service->>Context: Build ChangelogRenderContext(BundleReleaseDate)
Context->>Renderer: Render with BundleReleaseDate
Renderer->>Output: Emit "## {version}" then blank line + "_Released: {date}_" then content
Possibly related PRs
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches✨ Simplify code
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@src/services/Elastic.Changelog/Rendering/ChangelogRenderingService.cs`:
- Around line 155-171: The code treats identical release dates from multiple
bundles as a conflict because bundleReleaseDates uses raw values; update the
logic to deduplicate the extracted dates (from validationResult.Bundles ->
bundleReleaseDates) before checking Count (e.g., replace the ToList() with a
distinct collection or call .Distinct() and then ToList()), then use the single
unique value to set renderReleaseDate or emit the warning via
collector.EmitWarning only when more than one distinct release date remains.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 0b3231e0-35a4-4d22-ba88-2e9a1722b9cf
📒 Files selected for processing (13)
docs/cli/changelog/bundle.mddocs/syntax/changelog.mdsrc/Elastic.Documentation.Configuration/ReleaseNotes/Bundle.cssrc/Elastic.Documentation.Configuration/ReleaseNotes/BundleLoader.cssrc/Elastic.Documentation.Configuration/ReleaseNotes/ReleaseNotesSerialization.cssrc/Elastic.Documentation/ReleaseNotes/Bundle.cssrc/Elastic.Markdown/Myst/Directives/Changelog/ChangelogInlineRenderer.cssrc/services/Elastic.Changelog/Rendering/Asciidoc/ChangelogAsciidocRenderer.cssrc/services/Elastic.Changelog/Rendering/ChangelogRenderContext.cssrc/services/Elastic.Changelog/Rendering/ChangelogRenderingService.cssrc/services/Elastic.Changelog/Rendering/Markdown/IndexMarkdownRenderer.cstests/Elastic.Changelog.Tests/Changelogs/BundleLoading/BundleLoaderTests.cstests/Elastic.Markdown.Tests/Directives/ChangelogBasicTests.cs
This pull request introduces support for an optional
release-datefield in changelog bundle YAML files. The release date is parsed, preserved through serialization and merging, and rendered in the output (Markdown and AsciiDoc) as informative, italicized text after the version heading. The feature is particularly useful for components released outside the main stack lifecycle. The implementation includes updates to documentation, data models, serialization logic, rendering, and comprehensive tests.Key changes include:
Feature: Release Date Support in Bundles
release-datefield to bundle YAML files, documented its usage, and updated examples in both user and syntax documentation. The field is purely informative and intended for end-users. [1] [2] [3] [4]BundleandBundleDtoclasses to include a nullableReleaseDateproperty, and ensured the property is parsed from and serialized to theYYYY-MM-DDformat. [1] [2]Serialization and Merging
release-datefield, including parsing from YAML, serializing to YAML, and preserving the field during bundle merging. [1] [2] [3] [4]Rendering Enhancements
_Released: Month Day, Year_. [1] [2] [3] [4] [5]Testing
release-datefield.