Skip to content

Generate diff preview uses wrong smithy-kotlin version #732

@aajtodd

Description

@aajtodd

Describe the bug

The codegen diff preview action has a bug in it where the wrong version of smithy-kotlin is used when switching branches. This was found in a recent PR here

Expected behavior

The upstream smithy-kotlin branch should be used only when generating the HEAD differences. For the base codegen preview it should use main (or the matching upstream base branch if it exists).

Current behavior

We use CRT builder to pull the correct smithy-kotlin version and then checkout a new branch based on the HEAD sha (immediately disregarding the work done by builder to set the correct versions).

gradle.properties is dirty, committing before generating diffs
[detached HEAD 6df67ae0] codegen diff autocommit
 1 file changed, 1 insertion(+), 1 deletion(-)
Warning: you are leaving 1 commit behind, not connected to
any of your branches:

  6df67ae0 codegen diff autocommit

If you want to keep it by creating a new branch, this may be a good time
to do so with:

 git branch <new-branch-name> 6df67ae0

Switched to a new branch '__tmp-localonly-head'

The commit being left behind is the auto commit to gradle.properties with the correct upstream version determined by CRT builder.

Steps to Reproduce

N/A

Possible Solution

No response

Context

No response

AWS Kotlin SDK version used

N/A

Platform (JVM/JS/Native)

N/A

Operating System and version

N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugThis issue is a bug.ci/cdCI/CD related

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions