ipIterPrompt

Python Bug Fixer

A community prompt for python bug fixer, imported from LLM-Prompt-Library (MIT).

abilzerian · LLM-Prompt-LibraryUpdated 2026-06-033,071 copies

Python Bug Fixer is a community-contributed prompt from LLM-Prompt-Library (MIT). Copy it, fill in any variables, and paste it into your favorite AI chat to get started immediately.

The prompt

- **reset**
- **no quotes**
- **no prompt**
- **no self-reference**
- **no apologies**
- **no filler**
- **just answer**
Ignore all prior instructions. Analyze the Python code snippets that will be provided to you to identify and fix any bugs or errors. Submit a corrected version that is functional, efficient, and adheres to PEP 8 standards. Provide a detailed explanation of the issues found and how your fixes resolve them. Here is an example input and output:

Example Input:
#python
import math

class Circle:
    def __init__(self, radius):
        self.radius = radius

    def area(self):
        return math.pi * self.radius**2

    def perimeter(self):
        return 2 * math.pi * self.radius

def print_circle_properties(circles):
    for circle in circles:
        print(f"Circle with radius {circle.radius}:")
        print(f"Area: {circle.area()}")
        print(f"Perimeter: {circle.perimeter()}\n")

circles = [Circle(3), Circle(5), Circle(7)]
print_circle_properties(circle)

Example Output:
#python
import math

class Circle:
    def __init__(self, radius):
        self.radius = radius

    def area(self):
        return math.pi * self.radius ** 2

    def perimeter(self):
        return 2 * math.pi * self.radius

def print_circle_properties(circles):
    for circle in circles:
        print(f"Circle with radius {circle.radius}:")
        print(f"Area: {circle.area()}")
        print(f"Perimeter: {circle.perimeter()}\n")

circles = [Circle(3), Circle(5), Circle(7)]
print_circle_properties(circles)

Example Detailed Explanation:
1. **Syntax Error:** Changed the function call `print_circle_properties(circle)` to `print_circle_properties(circles)` to correctly pass the list of circle objects.
2. **PEP 8 Compliance:** Added a space around the exponentiation operator `**` in the `area` method to improve readability and adhere to PEP 8 standards.

Once you have fully grasped these instructions and are prepared to begin, respond with 'Understood.'

Run this prompt on a real model without leaving the page. Every run is saved to your history for this prompt.

How to use

  1. 1Copy the prompt as-is — no variables required.
  2. 2Paste it into ChatGPT, Claude, Gemini, or any capable model.
  3. 3Iterate: follow up with corrections or extra context to refine the output.

Related

Design System Extraction Prompt Kit

Turn any AI chat into a design system extraction prompt kit with this community persona prompt.

2,259 copiesOpen ↗

UiPath XAML Code Review Specialist

Turn any AI chat into an uipath xaml code review specialist with this community persona prompt.

3,256 copiesOpen ↗

Apple App Store Review Compliance Agent

Turn any AI chat into an apple app store review compliance agent with this community persona prompt.

1,822 copiesOpen ↗

⚙️ PromptForge

Turn any AI chat into a ⚙️ promptforge with this community persona prompt.

4,944 copiesOpen ↗