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

Remove uneeded guard when ID3Tag tries to find an unknown genre #125

Merged
merged 1 commit into from
Jun 18, 2018
Merged

Remove uneeded guard when ID3Tag tries to find an unknown genre #125

merged 1 commit into from
Jun 18, 2018

Conversation

alex-quiterio
Copy link
Contributor

The guard rescue nil can now be safely removed since the original issue
is fixed by krists/id3tag#19

related with: #118

@julik
Copy link
Contributor

julik commented Jun 13, 2018

@alex-quiterio good stuff, thanks! Can you also bump the gem version dependency for id3tag in .gemspec since you need it to be 0.10.1 or newer?

@julik
Copy link
Contributor

julik commented Jun 15, 2018

🎉 almost! We probably should use the additional constraint though, since we do not strictly forbid 0.11 and such. See https://guides.rubygems.org/patterns/

If you want to allow use of newer backwards-compatible versions but need a specific bug fix you can use a compound requirement:

@alex-quiterio
Copy link
Contributor Author

alex-quiterio commented Jun 16, 2018

Interesting indeed.

I didn't know about the existence of compound requirements. So in the end, we fixed the issue with the call on nil and made sure the version number of id3tag doesn't go off the fence with 0.11.

@julik thanks very much for the tip!

minor update:

Actually, after having a closer look at the documentation for Ruby's pessimistic operator we can actually make sure that by using the combination '~> 0.10.0', '>= 0.10.1' we constraint the gem to not be bumped to the next minor version.

Although, I don't think we actually need to specify that constraint for the id3tag gem, so the ideal situation would be something like: '~> 0.10', '>= 0.10.1'.

Hope this helps to be more strict without losing the flexibility we want to keep. 🙇

The guard `rescue nil` can now be safely removed since the original issue
is fixed by krists/id3tag#19

related with: #118
@julik
Copy link
Contributor

julik commented Jun 18, 2018

🎉 👍

@julik julik merged commit be4d032 into WeTransfer:master Jun 18, 2018
@alex-quiterio alex-quiterio deleted the id3tag-bug branch June 18, 2018 23:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants