-
Notifications
You must be signed in to change notification settings - Fork 32
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
Distinctive difference between package name and version #76
Comments
Sorry; what packages are you referring to? I'm afraid I don't fully understand what you're trying to do and what the problem is. |
I would try to clarify. announced: April 29, 2014
fixed_in:
- Firefox 29
- Firefox ESR 24.5
- Thunderbird 24.5
- Seamonkey 2.26
impact: High Now, I need to take out the fixed_in packages in a (Firefox, 29)
(Firefox ESR, 24.5)
(Thunderbird, 24.5)
(Seamonkey, 2.26) I could create the above tuples using name=" ".join(fixed_in.split(" ")[0:-1])
version=fixed_in.split(" ")[-1]
(name, version) But here I'm assuming that a version must follow at the end of the package name and would be separated by space. It could be a right assumption but there doesn't exist any validation currently for me to be sure of it. fixed_in:
- Firefox-29 then my current code would not be able to figure out the version from the name. I was hoping to have a validation to make sure the package name follows a certain pattern. Please let me know if it makes sense. |
We treat it as a free fork text field in our own validation schema. All other products are usually copy&paste and manual work - unless @tomrittervg has made local changes to his repo, which aren't on GitHub yet. :) |
The website also expects it to be in the |
Thank you so much. This is exactly what I was looking for.
Can you please mention this in the readme so that it is always clear that this pattern will hold.
I guess a validation that checks the last field is version (an int with dots) should be good too.
From the terminal
Hritik Vijay
Sent from ProtonMail Mobile
…On Mon, Mar 22, 2021 at 7:27 PM, Paul McLanahan ***@***.***> wrote:
The website also expects it to be in the <product name> <version> format. The code for that is here:
https://github.com/mozilla/bedrock/blob/bd0f50a1c0a7455115cc2bf9eb3ae9027586a024/bedrock/security/models.py#L28-L30
—
You are receiving this because you authored the thread.
Reply to this email directly, [view it on GitHub](#76 (comment)), or [unsubscribe](https://github.com/notifications/unsubscribe-auth/ABY4SKLT57RHBE4QFTGRNLLTE5EGBANCNFSM4ZPMJRSQ).
|
Mozilla website uses rsplit to extract the name and version so it should be better in any case. https://github.com/mozilla/bedrock/blob/765a60450235d810cf941676e4a29f012a9eaaba/bedrock/security/models.py#L29 Based on discussion here mozilla/foundation-security-advisories#76 Signed-off-by: Hritik Vijay <[email protected]>
Mozilla website uses rsplit to extract the name and version so it should be better in any case. https://github.com/mozilla/bedrock/blob/765a60450235d810cf941676e4a29f012a9eaaba/bedrock/security/models.py#L29 Based on discussion here mozilla/foundation-security-advisories#76 Signed-off-by: Hritik Vijay <[email protected]>
Mozilla website uses rsplit to extract the name and version so it should be better in any case. https://github.com/mozilla/bedrock/blob/765a60450235d810cf941676e4a29f012a9eaaba/bedrock/security/models.py#L29 Based on discussion here mozilla/foundation-security-advisories#76 Signed-off-by: Hritik Vijay <[email protected]>
Mozilla website uses rsplit to extract the name and version so it should be better in any case. https://github.com/mozilla/bedrock/blob/765a60450235d810cf941676e4a29f012a9eaaba/bedrock/security/models.py#L29 Based on discussion here mozilla/foundation-security-advisories#76 Signed-off-by: Hritik Vijay <[email protected]>
Mozilla website uses rsplit to extract the name and version so it should be better in any case. https://github.com/mozilla/bedrock/blob/765a60450235d810cf941676e4a29f012a9eaaba/bedrock/security/models.py#L29 Based on discussion here mozilla/foundation-security-advisories#76 Signed-off-by: Hritik Vijay <[email protected]>
Mozilla website uses rsplit to extract the name and version so it should be better in any case. https://github.com/mozilla/bedrock/blob/765a60450235d810cf941676e4a29f012a9eaaba/bedrock/security/models.py#L29 Based on discussion here mozilla/foundation-security-advisories#76 Signed-off-by: Hritik Vijay <[email protected]>
Hi
I'm writing a package url for the packages in the advisories and I would need the names and versions of packages explicitly. Currently, it appears that the pattern follows
package_name version
and package_name is also allowed to have spaces.Though there is no validation to make sure this pattern follows.
Something like the following should be fine:
The text was updated successfully, but these errors were encountered: