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

Fix readme generation when using snippet_files #6008

Merged
merged 3 commits into from
Jan 29, 2024

Conversation

DennisTraub
Copy link
Collaborator

This PR fixes a bug in the readme generation:

When using snippet_files instead of snippet_tags, the readme generation produced broken links for the respective actions and scenarios because they start with [language]/example_code/ even though the READMEs already are in that path.

This bug has led to broken links in multiple READMEs for Rust and JavaScript (EC2, Auto-Scaling, ELBv2, Lambda, Bedrock, and IAM).

I've patched scanner.py so that it removes the leading [language]/example_code, fixing the links for all affected single-service action and scenarios, and optionally adding ../cross-services/, fixing the links for all affected cross-service scenarios.


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

@github-actions github-actions bot added Javascript-v3 This issue relates to the AWS SDK for Javascript V3 Rust This issue relates to the AWS SDK for Rust (Preview) Tools This issue relates to a custom tooling to streamline development tasks labels Jan 26, 2024
Copy link
Contributor

@DavidSouther DavidSouther left a comment

Choose a reason for hiding this comment

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

1 lint issue (we use quotes the other way, " instead of ')

@DavidSouther DavidSouther added On Call Review needed This work needs an on-call review Bug An update to fix incorrect code or typos. labels Jan 26, 2024
@DennisTraub
Copy link
Collaborator Author

@DavidSouther I have fixed the quotes

@meyertst-aws meyertst-aws added On Call Review complete On call review complete and removed On Call Review needed This work needs an on-call review labels Jan 29, 2024
@meyertst-aws meyertst-aws force-pushed the fix/readme-generation branch from de5553d to 903209d Compare January 29, 2024 17:56
@meyertst-aws meyertst-aws merged commit c8a42e6 into awsdocs:main Jan 29, 2024
10 checks passed
@DennisTraub DennisTraub deleted the fix/readme-generation branch January 31, 2024 17:23
max-webster pushed a commit to max-webster/aws-doc-sdk-examples that referenced this pull request Mar 15, 2024
* Bug fix: Remove redundant path from snippet_files before rendering readmes

Co-authored-by: Dennis Traub <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug An update to fix incorrect code or typos. Javascript-v3 This issue relates to the AWS SDK for Javascript V3 On Call Review complete On call review complete Rust This issue relates to the AWS SDK for Rust (Preview) Tools This issue relates to a custom tooling to streamline development tasks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants