Homebrew formula updater generates invalid Ruby class names with prerelease versions
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 85/100
Research direction
Start with .github/homebrew_formula_up.sh at lines 42-43 and reproduce it with the v0.40.0-alpha.1 example. Check the generated Formula/eolang@.rb and verify that the archived formula's Ruby class name is valid and accepted by Homebrew for prerelease versions.
Written by the indexing model from the issue text.
Description
Symptom
The Homebrew formula updater turns a version into a Ruby class name by merely removing dots. Prerelease versions can contain hyphens, which are not valid in Ruby constants.
Steps to reproduce
- Run
.github/homebrew_formula_up.sh <token> v0.40.0-alpha.1. - Inspect the archived formula produced under
Formula/eolang@<old>.rb.
Actual result
DOTLESS_VERSION becomes 0400-alpha1, and line 43 writes class EolangAT0400-alpha1. Ruby parses the hyphen as subtraction, so Homebrew rejects the formula instead of accepting the prerelease archive.
Expected result
Normalize prerelease identifiers into a valid constant name, or skip archival class renaming for versions that cannot be represented as a Ruby constant.
Evidence
.github/homebrew_formula_up.sh:42-43 removes only . and then inserts the result verbatim into a Ruby class declaration.
- Dominant language
- JavaScript
- Stars
- 36
- Forks
- 64
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 17
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from objectionary/eoc
-
bug good-title
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
objectionary/eoc#1360 ·
-
bug good-title
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
objectionary/eoc#1359 ·
-
bug good-title
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
objectionary/eoc#1358 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
objectionary/eoc#1357 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
objectionary/eoc#1356 ·
All issues in objectionary/eoc
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
HarperFast/skills#96 ·
-
[Block] Latest Posts [Type] Bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/studio#4908 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
sugarlabs/musicblocks#8847 ·