Closed Bug 1600916 Opened 2 years ago Closed 1 year ago

maven.mozilla.org: Make beetmover fail whenever an invalid MavenVersion is passed

Categories

(Release Engineering :: Release Automation: Uploading, enhancement)

enhancement
Not set
normal

Tracking

(firefox84 fixed)

RESOLVED FIXED
Tracking Status
firefox84 --- fixed

People

(Reporter: u504868, Assigned: alex.lopez.zorzano, Mentored)

References

(Depends on 1 open bug)

Details

(Keywords: good-first-bug)

Attachments

(4 files)

In order to prevent bug 1600914 from happening again, we need beetmover to error out whenever MavenVersion cannot parse the version. In fact, maven-lambda uses this parser to process the functions. Therefore, it's a matter of using it in beetmover too. We may need to parse the path defined in declarative artifacts.

[1] https://github.com/mozilla-releng/maven-lambda/blob/cca6eb9c67af6300b821c26a072ff0e3aedd174d/maven_lambda/metadata.py#L265

Found in triaging, not actively working on this bug, returning to the pool.
Happy to mentor someone to finish. It's a matter of re-doing the logic from https://github.com/mozilla-releng/scriptworker-scripts/blob/e57086624a11d3d58878f18e7664dd6416c0091c/beetmoverscript/src/beetmoverscript/utils.py#L190 in a slightly different place in beetmoverscript (parsing paths from the payload somewhere around or so https://github.com/mozilla-releng/scriptworker-scripts/blob/e57086624a11d3d58878f18e7664dd6416c0091c/beetmoverscript/src/beetmoverscript/task.py#L112 that is used called

Assignee: mtabara → nobody
Mentor: mtabara
Keywords: good-first-bug

I can try to help with this but I'll probably need some help getting started since I'm not familiar with the code. I'll read around and see if I can figure things out.

Hi Alex!

Thank you very much for your interest! Mihai is on vacation this week, but I can help you out in the meantime. Comment 2 contains the main pointers, but I understand if you'd need more context. I'm happy to provide answers either here on this bug or on chat.mozilla.org. On the latter, you can find me under the nickname jlorenzo.

Looking forward to hearing from you soon!

Under Johan's guidance I've made a first attempt at solving this. I don't know how to attach pull requests here, so I'll simply post the link for reference: https://github.com/mozilla-releng/scriptworker-scripts/pull/277.

Thanks a lot for working on this Alex!
Adjusting the bug fields to reflect reality. Thanks Johan for picking this up from our side!

Assignee: nobody → alex.lopez.zorzano
Mentor: mtabara → jlorenzo

(In reply to alex.lopez.zorzano from comment #5)

Under Johan's guidance I've made a first attempt at solving this. I don't know how to attach pull requests here, so I'll simply post the link for reference: https://github.com/mozilla-releng/scriptworker-scripts/pull/277.

Dropping this in the comments works as well, no worries! If you wanted to attach to the bug, one should

But again, this is not a requirement, a comment suffices too.

Attachment #9179892 - Attachment description: GitHub Pull Request → Check maven artifact version
Attachment #9179892 - Attachment description: Check maven artifact version → [beetmoverscript] Check maven artifact version

Thanks for adding that! I missed to mention to add the description as well, usually as the PR title. I did that just now.

Depends on: 1669991
Pushed by jlorenzo@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/0abf4e0c4d22
Change version field on geckoview beetmover to valid Maven version. r=jlorenzo
Pushed by smolnar@mozilla.com:
https://hg.mozilla.org/mozilla-central/rev/03de9a8a6f7c
Change version field on geckoview beetmover to valid Maven version. r=jlorenzo a=bustage-fix
Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED

Amazing job, Alex! This bug turned out to be much harder than a simple "good first bug" and you nailed it! I see today's geckoview nightly is green[1]. I'm glad we now have this check, thanks to you! It bit us in the past, and we now have a way to explicitly error out on it. Thank you!

[1] https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&searchStr=beetmover-geckoview&revision=03de9a8a6f7c949b046b5a1197988391ede9e84f

Blocks: 1672691
You need to log in before you can comment on or make changes to this bug.