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

Add [piwheels] version badge #7656

Merged
merged 2 commits into from
Mar 2, 2022
Merged

Conversation

chris48s
Copy link
Member

Closes #6506

I don't often do PRs adding a new badge these days, but I'd like this one to exist :)
The transform method is fairly comprehensively unit tested, so I've kept the live tests fairly light-touch.

@chris48s chris48s added the service-badge Accepted and actionable changes, features, and bugs label Feb 27, 2022
@shields-ci
Copy link

shields-ci commented Feb 27, 2022

Messages
📖 ✨ Thanks for your contribution to Shields, @chris48s!

Generated by 🚫 dangerJS against 6d9a633

Copy link
Member

@calebcartwright calebcartwright left a comment

Choose a reason for hiding this comment

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

One inline question but also approving as I assume it's a simple answer/confirmation

Comment on lines +77 to +79
if (includePrereleases) {
return allReleases[0].version
}
Copy link
Member

Choose a reason for hiding this comment

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

I didn't see anything in the docs indicating a sort order, so figured I'd double check to confirm they are?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah its a good question. I did look over the source for piwheels. The code that generates the HTML pages and the JSON API does parse all the versions to PEP440 version objects and then sorts them. https://github.com/piwheels/piwheels/blob/fd6f3d12d9a33390ccb235a2995edb24a8fa782d/piwheels/master/the_scribe.py#L525-L542 I'm happy to rely on the ordering, even though it is not explicitly called out in the API docs.

@repo-ranger repo-ranger bot merged commit 76a64a7 into badges:master Mar 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
service-badge Accepted and actionable changes, features, and bugs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Badge request: piwheels package version
3 participants