You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2021/09/24 16:20:43 UTC
[GitHub] [beam] lostluck commented on a change in pull request #15580: Go Lint fix for wordcount and metrics
lostluck commented on a change in pull request #15580:
URL: https://github.com/apache/beam/pull/15580#discussion_r715746178
##########
File path: sdks/go/examples/wordcount/wordcount.go
##########
@@ -110,16 +110,16 @@ func init() {
}
var (
- wordRE = regexp.MustCompile(`[a-zA-Z]+('[a-z])?`)
- empty = beam.NewCounter("extract", "emptyLines")
- small_word_length = flag.Int("small_word_length", 9, "small_word_length")
- small_words = beam.NewCounter("extract", "small_words")
- lineLen = beam.NewDistribution("extract", "lineLenDistro")
+ wordRE = regexp.MustCompile(`[a-zA-Z]+('[a-z])?`)
+ empty = beam.NewCounter("extract", "emptyLines")
+ smallWordLength = flag.Int("small_word_length", 9, "smallWordLength")
Review comment:
Note that the 2nd string parameter is the flag's description when --help is called. I should have caught this in the initial change, but we should put a proper description of the flag's purpose there instead of repeating the variable.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org