Skip to content

envoy.code.check: remove stale entries_layout access in changelog date validation - #5223

Closed
phlax with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-attribute-error-changelogs
Closed

envoy.code.check: remove stale entries_layout access in changelog date validation#5223
phlax with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-attribute-error-changelogs

Conversation

Copilot AI commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

envoy.base.utils removed AChangelogs.entries_layout, but envoy.code.check still referenced it in AChangelogStatus.check_date, causing an AttributeError at runtime when checking current changelogs. This PR aligns envoy.code.check with the one-layout model and hardens the test that previously masked the stale lookup.

  • Date-check logic update (AChangelogStatus.check_date)

    • Drop project.changelogs.entries_layout from the current-changelog guard.
    • Current changelog now always short-circuits date validation:
    async def check_date(self) -> tuple[str, ...]:
        if self.is_current:
            return ()
        ...
  • Test hardening (test_abstract_changelog.py)

    • Tighten test_changelogstatus_check_date_current by patching AChangelogStatus.project via PropertyMock and asserting it is not accessed, so stale project.changelogs.* lookups cannot pass via truthy MagicMock chains.
    • Remove now-unneeded project mocking from test_changelogstatus_check_date.
  • entries_layout cleanup scope

    • Remove remaining entries_layout usage under py/envoy.code.check (source/tests), keeping changes limited to this fix path only.

@netlify

netlify Bot commented Sep 11, 2026

Copy link
Copy Markdown

Deploy Preview for nifty-bassi-e26446 ready!

Name Link
🔨 Latest commit 82d8045
🔍 Latest deploy log https://app.netlify.com/projects/nifty-bassi-e26446/deploys/6aa3cc5c634cc40008900e32
😎 Deploy Preview https://deploy-preview-5223--nifty-bassi-e26446.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Co-authored-by: phlax <454682+phlax@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix AttributeError in AChangelogStatus.check_date due to removed entries_layout envoy.code.check: remove stale entries_layout access in changelog date validation Sep 11, 2026
Copilot AI requested a review from phlax September 11, 2026 09:41
@phlax phlax closed this Sep 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants