Skip to content

test sorcery#19

Closed
tkoscieln wants to merge 4 commits into
mainfrom
add-utils
Closed

test sorcery#19
tkoscieln wants to merge 4 commits into
mainfrom
add-utils

Conversation

@tkoscieln
Copy link
Copy Markdown
Owner

No description provided.

Copy link
Copy Markdown

@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 there - I've reviewed your changes - here's some feedback:

  • Fix the typo in the count_words function (sentene -> sentence) and add a docstring for consistency.
  • Correct the spelling in the Celsius conversion comment.
  • Consider adding type annotations and basic input validation to these utility functions for better robustness.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Fix the typo in the count_words function (sentene -> sentence) and add a docstring for consistency.
- Correct the spelling in the Celsius conversion comment.
- Consider adding type annotations and basic input validation to these utility functions for better robustness.

## Individual Comments

### Comment 1
<location> `simple_utils.py:7-8` </location>
<code_context>
+    """Reverses the characters in a string."""
+    return text[::-1]
+
+def count_words(sentence):
+    return len(sentene.split())
+
+def celsius_to_fahrenheit(celsius):
</code_context>

<issue_to_address>
**issue (typo):** Typo in variable name 'sentene' should be 'sentence'.

This typo will result in a NameError when the function is called.

```suggestion
def count_words(sentence):
    return len(sentence.split())
```
</issue_to_address>

### Comment 2
<location> `simple_utils.py:10-11` </location>
<code_context>
+def count_words(sentence):
+    return len(sentene.split())
+
+def celsius_to_fahrenheit(celsius):
+    # Celsdius
+    return (celsius * 9/5) + 32
\ No newline at end of file
</code_context>

<issue_to_address>
**nitpick (typo):** Typo in comment: 'Celsdius' should be 'Celsius'.

Please update the spelling to maintain clarity.
</issue_to_address>

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.

Comment thread simple_utils.py
Comment on lines +7 to +8
def count_words(sentence):
return len(sentene.split())
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

issue (typo): Typo in variable name 'sentene' should be 'sentence'.

This typo will result in a NameError when the function is called.

Suggested change
def count_words(sentence):
return len(sentene.split())
def count_words(sentence):
return len(sentence.split())

Comment thread simple_utils.py
Comment on lines +10 to +11
def celsius_to_fahrenheit(celsius):
# Celsdius
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

nitpick (typo): Typo in comment: 'Celsdius' should be 'Celsius'.

Please update the spelling to maintain clarity.

@tkoscieln tkoscieln closed this Dec 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant