Bug #16437
closedCodespell report for Ruby 2.6.5 (and 2.7.0-rc1)
Description
The FOSS server fossies.org offers a new feature "Source code misspelling reports":
https://fossies.org/features.html#codespell
Although such reports are normally only generated on request, as Fossies administrator I have just created (for testing purposes) an analysis for the current Ruby release 2.6.5:
https://fossies.org/linux/misc/ruby/codespell.html
That version-independent URL should redirect always to the last report (if available), so currently to
https://fossies.org/linux/misc/ruby-2.6.5.tar.gz/codespell.html
Although after a first review some obviously wrong matches ("false positives") are already filtered out (ignored) please inform me if you find more of them so that I can force a new improved check if applicable.
Just for information there are also two supplemental pages
https://fossies.org/linux/misc/ruby/codespell_conf.html
showing some used "codespell" configurations and
https://fossies.org/linux/misc/ruby/codespell_fps.html
showing all resulting obvious "false positives".
Since a lot of spelling errors seem recently been fixed a similar check was done also for the new release candidate 2.7.0-rc1
https://fossies.org/linux/misc/ruby-2.7.0-rc1.tar.gz/codespell.html
Jens
Updated by mame (Yusuke Endoh) about 5 years ago
- Status changed from Open to Feedback
Is there anyone who is interested in this? I'd be happy if anyone could look through the result and create a patch. Contribution is welcome.
@jschleus Thanks. If possible, could you apply the checker to master? In the tarballs, there are auto-generated files and bundled third party's code, many of which are difficult to fix.
Updated by nobu (Nobuyoshi Nakada) about 5 years ago
- Status changed from Feedback to Closed
Applied in changeset git|db166290088fb7d39d01f68b9860253893d4f1a7.
Fixed misspellings
Fixed misspellings reported at [Bug #16437], only in ruby and rubyspec.
Updated by nobu (Nobuyoshi Nakada) about 5 years ago
Fixed for ruby core, standard libraries, default gems and rubyspec.
Could you report other upstreams (rubygems, bundler, minitest, rake, test-unit, and unicode.org)?
BTW, I'm unsure what word is appropriate to the variable for the “read” (past participle) number.
Updated by hsbt (Hiroshi SHIBATA) about 5 years ago
You can see a list of the upstream with https://github.com/ruby/ruby/blob/master/doc/maintainers.rdoc#default-gems-maintainers
Updated by jschleus (Jens Schleusener) about 5 years ago
There was now also a check done for Ruby master but since the according tarball isn't embedded into the Fossies standard services a test folder was used:
https://fossies.org/linux/test/ruby-master.tar.gz/codespell.html
(https://fossies.org/linux/test/ruby-master-d76c8cf.191222.tar.gz/codespell.html)
Additionally a codespell check was done for the new release candidate 2.7.0-rc2
https://fossies.org/linux/misc/ruby-2.7.0-rc2.tar.gz/codespell.html
Here the results for the currently used codespell configuration:
spelling error
Ruby occurences types
2.6.5 583 369
2.7.0-rc1 463 299
2.7.0-rc2 362 243
master d76c8cf 172 122
Although the numbers are not completely comparable it looks now much better!
Not really understood I have the remark
"Could you report other upstreams (rubygems, bundler, minitest, rake, test-unit, and unicode.org)"
If that is addressed to me, I found separate tarballs only for rubygems and rake. The other mentioned ones appear to be partially contained in the main ruby tarball? Sorry, I'm not very familiar with the complete Ruby system.
Updated by nobu (Nobuyoshi Nakada) about 5 years ago
jschleus (Jens Schleusener) wrote:
There was now also a check done for Ruby master but since the according tarball isn't embedded into the Fossies standard services a test folder was used:
https://fossies.org/linux/test/ruby-master.tar.gz/codespell.html
(https://fossies.org/linux/test/ruby-master-d76c8cf.191222.tar.gz/codespell.html)Additionally a codespell check was done for the new release candidate 2.7.0-rc2
https://fossies.org/linux/misc/ruby-2.7.0-rc2.tar.gz/codespell.html
Here the results for the currently used codespell configuration:
spelling error Ruby occurences types 2.6.5 583 369 2.7.0-rc1 463 299 2.7.0-rc2 362 243 master d76c8cf 172 122
Although the numbers are not completely comparable it looks now much better!
Some are not misspells (a part of path name or URL, a person's name, an abbreviation, an API name, a part of the interface, ...), and some are intentional typos for tests.
And we generate ChangeLog from the git commit log at packaging but we don't use force-push, so typos in that file cannot be modified.
Not really understood I have the remark
"Could you report other upstreams (rubygems, bundler, minitest, rake, test-unit, and unicode.org)"If that is addressed to me, I found separate tarballs only for rubygems and rake. The other mentioned ones appear to be partially contained in the main ruby tarball? Sorry, I'm not very familiar with the complete Ruby system.
Some files under gems/, lib/, spec/, test/ are imported from external gems.
I had mistaken that the files under enc/trans/JIS/ are copied from Unicode.org, but they are come from Citrus Project which seems finished.
Updated by jschleus (Jens Schleusener) about 5 years ago
Yes, your mentioned types of false positives are often found and I had tried to eliminate them before. Some nevertheless overseen ones are now also excluded. Additionally the mentioned sub-directories of external gems are now also excluded. Assuming the word "exapmle" is an intentional typo it looks now very well and the (unimportant) Fossies ranking for 2.7.0-rc2 and master is "A+". Congratulation!
Updated by nobu (Nobuyoshi Nakada) about 5 years ago
Thank you, yes, "exapmle" in test/openssl/test_x509name.rb is intentional to test malformed RDN by a typo.
And for others:
- Fixed the typos in debug_counter.h and error.c.
- I see the word "unuseful" in some online dictionaries.
-
spawnve
is an old function name provided by Microsoft and some platforms. - The URLs in "enc/x_emoji.h" come from NTT-DoCoMo.
Although the pages for developers in English seem no longer provided, its Japanese version has the same word.
Maybe %-escape can avoid the false positive. - "lib/rubygems.rb" comes from the external library rubygems.
-
PRES
stands for "private resident", an abbreviation in FreeBSD.
Updated by nobu (Nobuyoshi Nakada) about 5 years ago
And as I added fixing typos in ChangeLog file taking from git-notes, the file in the next package will be fixed.
Updated by duerst (Martin Dürst) about 5 years ago
nobu (Nobuyoshi Nakada) wrote:
- I see the word "unuseful" in some online dictionaries.
Yes, but that doesn't mean it's best. As an example, "unuseful" shows up on Google about 363,000 times, but "useless" shows up on Google about 120,000,000 times. So replacing "unuseful" by "useless" is definitely an improvement; the sentence reads much more naturally that way.