-
Notifications
You must be signed in to change notification settings - Fork 24
ci: detect misspellings using typos-cli during tests #51
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
Conversation
|
🤔 Hmmm... The https://github.com/slackapi/slack-cli/actions/runs/14541228740/job/40799485080?pr=51#step:4:68 Edit: Related changes are in #52! |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #51 +/- ##
==========================================
- Coverage 62.91% 62.90% -0.01%
==========================================
Files 210 210
Lines 22152 22152
==========================================
- Hits 13936 13935 -1
+ Misses 7132 7131 -1
- Partials 1084 1086 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
📣 Good news is that this check can cause CI to fail! 🔍 Bad news is that I tried to allow this pattern... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
license-eye has checked 593 files.
| Valid | Invalid | Ignored | Fixed |
|---|---|---|---|
| 462 | 1 | 130 | 0 |
Click to see the invalid file list
- .typos.toml
Use this command to fix any missing license headers
```bash
docker run -it --rm -v $(pwd):/github/workspace apache/skywalking-eyes header fix
</details>
zimeg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📝 A few notes on the worded and ignored changes!
I noticed with a configuration file some more words are found, which might not've been known otherwise. It makes for somewhat more predictable tests too IMO 👾
| "alle", | ||
| "groupe", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are reserved constants not found in the included wordbanks:
slack-cli/internal/pkg/create/constants.go
Lines 210 to 225 in f3ba824
| var reserved = []string{ | |
| "alle", | |
| "allgemein", | |
| "aquí", | |
| "canais", | |
| "canal", | |
| "channel", | |
| "chaîne", | |
| "conversation", | |
| "eu", | |
| "everyone", | |
| "false", | |
| "general", | |
| "geral", | |
| "group", | |
| "groupe", |
| extend-ignore-identifiers-re = [ | ||
| "alle", | ||
| "groupe", | ||
| "UE1", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This pattern appears as a testing placeholder sometimes!
slack-cli/internal/prompts/app_select_test.go
Line 4042 in f3ba824
| const enterprise1UserID = "UE1" |
| {Command: "auth login", Meaning: "Login to a Slack account with prompts"}, | ||
| {Command: "auth login --no-prompt", Meaning: "Login to a Slack account without prompts, this returns a ticket"}, | ||
| {Command: "auth login --challenge 6d0a31c9 --ticket ISQWLiZT0OtMLO3YWNTJO0...", Meaning: "Complete login using ticket and challenge code"}, | ||
| {Command: "auth login --challenge 6d0a31c9 --ticket ISQWLiZT0tOMLO3YWNTJO0...", Meaning: "Complete login using ticket and challenge code"}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The diff is not so clear, but "Ot" was replaced with "tO" to avoid unexpected identifiers found. It also reads more like "token" which is neat 🎉
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
|
🔍 Here is a link to the spell checker passing tests: https://github.com/slackapi/slack-cli/actions/runs/14543476644/job/40805487762?pr=51#step:4:37 |
|
📣 I realize an open issue in the slackapi/slack-health-score project to implement this might be ideal so I will be closing this PR now. |
|
📝 The issue mentioned above can be found here: slackapi/slack-health-score#99 |
Summary
This PR follows up from changes in #35 to check
typosduring tests.Notes
Additional configuration is not included and this is instead left as a CI check to avoid drifting dependencies! 👾 ✨
I am of course interested in discussing this, but am hoping we can guard against regressions with these changes ❄️
Edit: Of course, also a kind thanks to @seratch for sharing this!
Requirements