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

Feature shortcode does not behave correctly for versions > "0.10.0" (2 digit minor version) #650

Closed
aLekSer opened this issue Mar 14, 2019 · 2 comments
Labels
area/site The website itself - including redirects, styling, search, etc kind/bug These are bugs.
Milestone

Comments

@aLekSer
Copy link
Collaborator

aLekSer commented Mar 14, 2019

Steps to reproduce:
Set expiryVersion to 0.10.0 and base_version to 0.9.0 in one of md files.
Run make site-server.
We will not see the doc part inside the shortcode:

{{% feature expiryVersion="0.10.0" %}}
{{% /feature %}}

While {{% feature expiryVersion="0.9.1" %}} works as expected.
The reason seems to be lexicographic comparison between strings, we should split the version into parts and compare them separately.

@aLekSer aLekSer changed the title Feature shortcode does not behave correctly for versions > "0.10.0" (2 digits minor version)) Feature shortcode does not behave correctly for versions > "0.10.0" (2 digits minor version) Mar 14, 2019
@markmandel
Copy link
Member

Oh! That's a nice find. And frustrating! We should fix this 😢

@markmandel markmandel added kind/bug These are bugs. area/site The website itself - including redirects, styling, search, etc labels Mar 14, 2019
@aLekSer aLekSer changed the title Feature shortcode does not behave correctly for versions > "0.10.0" (2 digits minor version) Feature shortcode does not behave correctly for versions > "0.10.0" (2 digit minor version) Mar 14, 2019
@aLekSer
Copy link
Collaborator Author

aLekSer commented Mar 14, 2019

I will fix this shortcode tomorrow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/site The website itself - including redirects, styling, search, etc kind/bug These are bugs.
Projects
None yet
Development

No branches or pull requests

2 participants