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

If writeable is OK, so is overwriteable #23

Open
wants to merge 16 commits into
base: master
Choose a base branch
from

Conversation

gitworkflows
Copy link
Contributor

@gitworkflows gitworkflows commented Dec 10, 2024

User description

Notes for Reviewers

This PR fixes #

Signed commits

  • Yes, I signed my commits.

PR Type

configuration changes


Description

  • Updated the GitHub Actions workflow configuration for codetypo-actions to skip additional paths.
  • Added ./codetypo_lib/tests/data to the skip list to prevent unnecessary checks on this directory.

Changes walkthrough 📝

Relevant files
Configuration changes
codetypo.yml
Update codetypo-actions skip paths in workflow configuration

.github/workflows/codetypo.yml

  • Updated the skip option in the codetypo-actions configuration.
  • Added ./codetypo_lib/tests/data to the list of paths to skip.
  • +1/-1     

    💡 PR-Agent usage: Comment /help "your question" on any pull request to receive relevant information

    Summary by CodeRabbit

    • New Features

      • Updated the list of paths ignored by the codetypo action in the workflow.
      • Enhanced the dictionary with numerous spelling corrections and variations.
      • Added new British and American English terms to respective wordlists.
    • Bug Fixes

      • Corrected multiple spelling errors in the dictionary files.
    • Documentation

      • Updated entries in the British to American English conversion dictionary for consistency.

    Copy link

    sourcery-ai bot commented Dec 10, 2024

    Reviewer's Guide by Sourcery

    This PR updates the codetypo workflow configuration by modifying the skip pattern to include an additional directory path in the exclusion list.

    No diagrams generated as the changes look simple and do not need a visual representation.

    File-Level Changes

    Change Details Files
    Updated the skip pattern in the codetypo workflow configuration
    • Added './codetypo_lib/tests/data' to the list of paths to skip during the codetypo check
    .github/workflows/codetypo.yml

    Tips and commands

    Interacting with Sourcery

    • Trigger a new review: Comment @sourcery-ai review on the pull request.
    • Continue discussions: Reply directly to Sourcery's review comments.
    • Generate a GitHub issue from a review comment: Ask Sourcery to create an
      issue from a review comment by replying to it.
    • Generate a pull request title: Write @sourcery-ai anywhere in the pull
      request title to generate a title at any time.
    • Generate a pull request summary: Write @sourcery-ai summary anywhere in
      the pull request body to generate a PR summary at any time. You can also use
      this command to specify where the summary should be inserted.

    Customizing Your Experience

    Access your dashboard to:

    • Enable or disable review features such as the Sourcery-generated pull request
      summary, the reviewer's guide, and others.
    • Change the review language.
    • Add, remove or edit custom review instructions.
    • Adjust other review settings.

    Getting Help

    Copy link

    coderabbitai bot commented Dec 10, 2024

    Warning

    Rate limit exceeded

    @gitworkflows has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 1 minutes and 17 seconds before requesting another review.

    ⌛ How to resolve this issue?

    After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

    We recommend that you space out your commits to avoid hitting the rate limit.

    🚦 How do rate limits work?

    CodeRabbit enforces hourly rate limits for each developer per organization.

    Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

    Please see our FAQ for further information.

    📥 Commits

    Reviewing files that changed from the base of the PR and between d7be468 and b463950.

    📒 Files selected for processing (2)
    • .github/workflows/codetypo.yml (1 hunks)
    • codetypo/data/dictionary.txt (88 hunks)

    Walkthrough

    The changes in this pull request involve updates to several files related to spelling corrections and adjustments to a GitHub Actions workflow. The .github/workflows/codetypo.yml file has been modified to include an additional path in the skip parameter to exclude certain directories from spelling checks. The dictionary.txt file has undergone extensive spelling corrections and the addition of new entries. Similarly, the British to American English dictionary and additional wordlists have been updated with new entries to standardize spelling variations.

    Changes

    File Path Change Summary
    .github/workflows/codetypo.yml Updated skip parameter to include ./codetypo_lib/tests/data in the list of ignored paths.
    codetypo/data/dictionary.txt Added multiple corrected spellings and variations, including terms like "ago," "after," and "payload."
    codetypo/data/dictionary_en-GB_to_en-US.txt Updated 200 entries to convert British English spellings to American English, including "colour" to "color."
    codetypo/tests/data/en_GB-additional.wordlist Added new British English words such as "overwriteable," "writeable," and various process-related terms.
    codetypo/tests/data/en_US-additional.wordlist Introduced new entries for American English, including terms related to programming like "overwritable" and "virtualization."

    Poem

    🐇 In the land of code where bunnies hop,
    We fixed our words, made errors stop.
    With paths now clear and spellings bright,
    Our dictionary shines, a joyful sight!
    So let’s celebrate, with a leap and a cheer,
    For every correct word brings us near! 🌟


    Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

    ❤️ Share
    🪧 Tips

    Chat

    There are 3 ways to chat with CodeRabbit:

    • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
      • I pushed a fix in commit <commit_id>, please review it.
      • Generate unit testing code for this file.
      • Open a follow-up GitHub issue for this discussion.
    • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
      • @coderabbitai generate unit testing code for this file.
      • @coderabbitai modularize this function.
    • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
      • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
      • @coderabbitai read src/utils.ts and generate unit testing code.
      • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
      • @coderabbitai help me debug CodeRabbit configuration file.

    Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

    CodeRabbit Commands (Invoked using PR comments)

    • @coderabbitai pause to pause the reviews on a PR.
    • @coderabbitai resume to resume the paused reviews.
    • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
    • @coderabbitai full review to do a full review from scratch and review all the files again.
    • @coderabbitai summary to regenerate the summary of the PR.
    • @coderabbitai generate docstrings to generate docstrings for this PR. (Experiment)
    • @coderabbitai resolve resolve all the CodeRabbit review comments.
    • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
    • @coderabbitai help to get help.

    Other keywords and placeholders

    • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
    • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
    • Add @coderabbitai anywhere in the PR title to generate the title automatically.

    CodeRabbit Configuration File (.coderabbit.yaml)

    • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
    • Please see the configuration documentation for more information.
    • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

    Documentation and Community

    • Visit our Documentation for detailed information on how to use CodeRabbit.
    • Join our Discord Community to get help, request features, and share feedback.
    • Follow us on X/Twitter for updates and announcements.

    Copy link

    PR Reviewer Guide 🔍

    Here are some key observations to aid the review process:

    ⏱️ Estimated effort to review: 1 🔵⚪⚪⚪⚪
    🧪 No relevant tests
    🔒 No security concerns identified
    ⚡ Recommended focus areas for review

    Configuration Update
    Verify that adding './codetypo_lib/tests/data' to the skip list won't exclude important files that should be checked for typos

    Copy link

    PR Code Suggestions ✨

    No code suggestions found for the PR.

    Copy link

    @sourcery-ai sourcery-ai bot left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Hey @gitworkflows - I've reviewed your changes - here's some feedback:

    Overall Comments:

    • Consider updating the PR title to better reflect the change (e.g., 'Add test data directory to codetypo skip list')
    Here's what I looked at during the review
    • 🟢 General issues: all looks good
    • 🟢 Security: all looks good
    • 🟢 Testing: all looks good
    • 🟢 Complexity: all looks good
    • 🟢 Documentation: all looks good

    Sourcery is free for open source - if you like our reviews please consider sharing them ✨
    Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

    Copy link

    codiumai-pr-agent-free bot commented Dec 10, 2024

    CI Failure Feedback 🧐

    (Checks updated until commit b463950)

    Action: Test Windows

    Failed stage: Run pytest codetypo [❌]

    Failed test name: test_dictionary_looping

    Failure summary:

    The action failed due to two test failures in the codetypo/tests/test_dictionary.py file:

  • test_dictionary_looping failed because the error 'agrv' was found in the dictionary_code.txt file,
    which already exists in the dictionary.txt file.
  • test_ran_all failed because the pair ('dictionary.txt', 'dictionary_code.txt') was not found in the
    global_pairs set.

  • Relevant error logs:
    1:  ##[group]Operating System
    2:  Microsoft Windows Server 2022
    ...
    
    328:  comma-separated list of custom dictionary files that
    329:  contain spelling corrections. If this flag is not
    330:  specified or equals "-" then the default dictionary is
    331:  used.
    332:  --builtin BUILTIN-LIST
    333:  comma-separated list of builtin dictionaries to
    334:  include (when "-D -" or no "-D" is passed). Current
    335:  options are:
    336:  - 'clear' for unambiguous errors
    337:  - 'rare' for rare (but valid) words that are likely to
    338:  be errors
    ...
    
    379:  default any alphanumeric character, the underscore,
    380:  the hyphen, and the apostrophe are used to build
    381:  words. This option cannot be specified together with
    382:  --write-changes.
    383:  --uri-regex URI_REGEX
    384:  regular expression that is used to find URIs and
    385:  emails. A default expression is provided.
    386:  -s, --summary         print summary of fixes
    387:  --count               print the number of errors as the last line of stderr
    ...
    
    458:  rootdir: D:\a\codetypo\codetypo
    459:  configfile: pyproject.toml
    460:  plugins: cov-5.0.0, dependency-0.6.0
    461:  collected 114 items
    462:  codetypo\tests\test_basic.py .....s....................................s [ 37%]
    463:  .................                                                        [ 52%]
    464:  codetypo\tests\test_dictionary.py ..............................ssssssss [ 85%]
    465:  ssssssss....F..F                                                         [100%]
    466:  ================================== FAILURES ===================================
    467:  _ test_dictionary_looping[D:\\a\\codetypo\\codetypo\\codetypo\\tests\\..\\data\\dictionary_code.txt-in_aspell4-in_dictionary4] _
    468:  codetypo\tests\test_dictionary.py:333: in test_dictionary_looping
    469:  assert err not in other_err_dict, (
    470:  E   AssertionError: error 'agrv' in dictionary dictionary_code.txt already exists in dictionary dictionary.txt
    471:  E   assert 'agrv' not in {'1nd': ['1st'], '2rd': ['2nd'], '2st': ['2nd'], '3nd': ['3rd'], ...}
    472:  ________________________________ test_ran_all _________________________________
    473:  codetypo\tests\test_dictionary.py:373: in test_ran_all
    474:  assert (f1, f2) in global_pairs
    475:  E   AssertionError: assert ('dictionary.txt', 'dictionary_code.txt') in {('dictionary.txt', 'dictionary.txt'), ('dictionary.txt', 'dictionary_en-GB_to_en-US.txt'), ('dictionary.txt', 'dictio...', 'dictionary_names.txt'), ('dictionary.txt', 'dictionary_rare.txt'), ('dictionary.txt', 'dictionary_usage.txt'), ...}
    476:  -------- generated xml file: D:\a\codetypo\codetypo\junit-results.xml ---------
    477:  =========================== short test summary info ===========================
    478:  SKIPPED [1] codetypo\tests\test_basic.py:210: Only supported on Linux
    479:  SKIPPED [1] codetypo\tests\test_basic.py:628: requires os.mkfifo
    480:  SKIPPED [16] codetypo\tests\test_dictionary.py:223: requires aspell-en
    481:  ============= 2 failed, 94 passed, 18 skipped in 71.63s (0:01:11) =============
    482:  ##[error]Process completed with exit code 1.
    

    ✨ CI feedback usage guide:

    The CI feedback tool (/checks) automatically triggers when a PR has a failed check.
    The tool analyzes the failed checks and provides several feedbacks:

    • Failed stage
    • Failed test name
    • Failure summary
    • Relevant error logs

    In addition to being automatically triggered, the tool can also be invoked manually by commenting on a PR:

    /checks "https://github.com/{repo_name}/actions/runs/{run_number}/job/{job_number}"
    

    where {repo_name} is the name of the repository, {run_number} is the run number of the failed check, and {job_number} is the job number of the failed check.

    Configuration options

    • enable_auto_checks_feedback - if set to true, the tool will automatically provide feedback when a check is failed. Default is true.
    • excluded_checks_list - a list of checks to exclude from the feedback, for example: ["check1", "check2"]. Default is an empty list.
    • enable_help_text - if set to true, the tool will provide a help message with the feedback. Default is true.
    • persistent_comment - if set to true, the tool will overwrite a previous checks comment with the new feedback. Default is true.
    • final_update_message - if persistent_comment is true and updating a previous checks message, the tool will also create a new message: "Persistent checks updated to latest commit". Default is true.

    See more information about the checks tool in the docs.

    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    Status: Backlog
    Development

    Successfully merging this pull request may close these issues.

    1 participant