Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(ci): fix codegen diff #1063

Merged
merged 15 commits into from
Oct 9, 2023
Merged

chore(ci): fix codegen diff #1063

merged 15 commits into from
Oct 9, 2023

Conversation

aajtodd
Copy link
Contributor

@aajtodd aajtodd commented Oct 6, 2023

Issue #

fixes #732

upstream support: awslabs/aws-kotlin-repo-tools#16

Description of changes

Removes CRT builder from the equation as it is only good for building at the current HEAD. We need to be able to get dependencies at the correct base ref as well to generate accurate diffs. As such I've added some utility code to repo-tools and refactored the diff preview workflow to use that instead. Now we explicitly checkout our dependencies and rely on our builtin composite build (by having smithy-kotlin a sibling of the sdk directory).

This should now correctly handle not only xyz-branch -> main but also if you have long running feature branches across repos:

aw-sdk-kotlin
     feat-xyz <-- feat-xyz-child

smithy-kotlin
    feat-xyz

and:

aw-sdk-kotlin
     feat-xyz <-- feat-xyz-child

smithy-kotlin
    feat-xyz <-- feat-xyz-child

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@github-actions
Copy link

github-actions bot commented Oct 6, 2023

A new generated diff is ready to view.

  • No codegen difference in the AWS SDK

@github-actions
Copy link

github-actions bot commented Oct 6, 2023

A new generated diff is ready to view.

@github-actions
Copy link

github-actions bot commented Oct 6, 2023

A new generated diff is ready to view.

@sonarqubecloud
Copy link

sonarqubecloud bot commented Oct 6, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@github-actions
Copy link

github-actions bot commented Oct 6, 2023

A new generated diff is ready to view.

  • No codegen difference in the AWS SDK

@aajtodd aajtodd added the no-changelog Indicates that a changelog entry isn't required for a pull request. Use sparingly. label Oct 6, 2023
@aajtodd aajtodd marked this pull request as ready for review October 6, 2023 18:21
@aajtodd aajtodd requested a review from a team as a code owner October 6, 2023 18:21
Comment on lines +54 to +58
- uses: actions/checkout@v4
with:
repository: 'awslabs/smithy-kotlin'
fetch-depth: 0
path: 'smithy-kotlin'
Copy link
Member

Choose a reason for hiding this comment

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

Do we also need aws-crt-kotlin?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Technically smithy-kotlin could need a branch version of aws-crt-kotlin. However, in this case we mostly care about codegen output so I don't think we care.

@aajtodd aajtodd merged commit 087783c into main Oct 9, 2023
@aajtodd aajtodd deleted the fix-codegendiff branch October 9, 2023 12:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-changelog Indicates that a changelog entry isn't required for a pull request. Use sparingly.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Generate diff preview uses wrong smithy-kotlin version
2 participants