Skip to content

Conversation

@daquinteroflex
Copy link
Collaborator

@daquinteroflex daquinteroflex commented Nov 26, 2025

this was happening before pypi on a successful autorelease run

Greptile Overview

Greptile Summary

This PR modifies the GitHub release workflow to ensure releases are only created after successful PyPI deployment. The github-release job now depends on the deploy-packages job and requires both deploy_pypi == 'true' and deploy-packages.result == 'success'.

Key Changes:

  • Added deploy-packages to the needs array of the github-release job
  • Added condition deploy_pypi == 'true' to restrict GitHub releases to PyPI deployments only
  • Added condition deploy-packages.result == 'success' to ensure PyPI deployment succeeded before creating release

Impact:

  • GitHub releases will no longer be created for draft or TestPyPI-only releases (breaking change from previous behavior)
  • GitHub releases will only be created after successful PyPI deployment, preventing release creation if deployment fails
  • An outdated comment at line 304 suggests GitHub releases should "always" be created, which is no longer accurate

Confidence Score: 4/5

  • This PR is mostly safe to merge with minor documentation improvements needed
  • The logic change correctly ensures GitHub releases happen after successful PyPI deployment, achieving the stated goal. However, there's a breaking behavior change (GitHub releases no longer created for non-PyPI releases) and an outdated comment that should be updated for code clarity
  • Pay attention to .github/workflows/tidy3d-python-client-release.yml for the comment update and potential breaking change in GitHub release behavior

Important Files Changed

File Analysis

Filename Score Overview
.github/workflows/tidy3d-python-client-release.yml 5/5 Added dependency on deploy-packages job and conditions to ensure GitHub release only created after successful PyPI deployment

Sequence Diagram

sequenceDiagram
    participant Scope as determine-workflow-scope
    participant Tests as compile-tests-results
    participant Deploy as deploy-packages
    participant GitHub as github-release

    Note over Scope: Determine release type<br/>and deployment targets
    Scope->>Tests: run if tests enabled
    Scope->>Deploy: run if deploy enabled
    Note over Tests: Compile test results<br/>and check if deployment<br/>should proceed
    Tests->>Deploy: proceed_deploy output
    Note over Deploy: Deploy to TestPyPI/PyPI<br/>(only if deploy_testpypi<br/>or deploy_pypi == true)
    Deploy->>GitHub: Wait for success
    Tests->>GitHub: Check proceed_deploy
    Scope->>GitHub: Check deploy_github_release<br/>and deploy_pypi flags
    Note over GitHub: Create GitHub release<br/>ONLY if:<br/>- deploy_pypi == true<br/>- deploy-packages succeeded<br/>- tests passed
Loading

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Additional Comments (1)

  1. .github/workflows/tidy3d-python-client-release.yml, line 304-305 (link)

    style: Comment is now outdated - GitHub releases are no longer created for all release types. Since line 479 requires deploy_pypi == 'true', GitHub releases are only created for PyPI releases, not for draft or TestPyPI-only releases.

1 file reviewed, 2 comments

Edit Code Review Agent Settings | Greptile

@daquinteroflex daquinteroflex changed the title fix: github release after pypi fix: github release after pypi (FXC-3911) Nov 26, 2025
@github-actions
Copy link
Contributor

Diff Coverage

Diff: origin/develop...HEAD, staged and unstaged changes

No lines with coverage information in this diff.

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