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

Sweep: write py code for this story that i will write in the comments #4

Open
1 task done
alkanet88 opened this issue Sep 25, 2023 · 1 comment · May be fixed by #5
Open
1 task done

Sweep: write py code for this story that i will write in the comments #4

alkanet88 opened this issue Sep 25, 2023 · 1 comment · May be fixed by #5
Labels
sweep Sweep your software chores

Comments

@alkanet88
Copy link
Owner

alkanet88 commented Sep 25, 2023

Terpsichore, the muse of dance, tells you about this dance sequence that is to be animated in python:
o
/|
/\

it goes left, then right, right on the screen, moving 3 spaces each time, then repeats for 5 times

Checklist
@upmortem-sweep upmortem-sweep bot added the sweep Sweep your software chores label Sep 25, 2023
@upmortem-sweep
Copy link
Contributor

upmortem-sweep bot commented Sep 25, 2023

Here's the PR! #5.

💎 Sweep Pro: I'm creating this ticket using GPT-4. You have unlimited GPT-4 tickets.

Actions (click)

  • ↻ Restart Sweep

Step 1: 🔎 Searching

I found the following snippets in your repository. I will now analyze these snippets and come up with a plan.

Some code snippets I looked at (click to expand). If some file is missing from here, you can mention the path in the ticket description.

# Upgraded Pancake
This repository is a test for Sweep, a meticulous engineer. The content here is a placeholder, waiting for the muses to inspire the actual story.
## How to Use
1. Clone the repository: `git clone https://github.com/alkanet88/upgraded-pancake.git`
2. Install necessary dependencies: `npm install` (This is a placeholder, replace with actual command if necessary)
3. Run the code: `npm start` (This is a placeholder, replace with actual command if necessary)
## The Story
In the world of coding, the muses take on different forms. They inspire creativity, problem-solving, and the pursuit of perfection. Each muse has a role to play in the creation of this repository:
- Calliope, the muse of epic poetry, inspires the overarching structure and design of the code.
- Clio, the muse of history, ensures that each commit tells a part of the repository's story.
- Erato, the muse of love poetry, brings passion and care into every line of code.
- Euterpe, the muse of music, guides the rhythm and flow of the code.
- Melpomene, the muse of tragedy, reminds us of the importance of error handling and robustness.
- Polyhymnia, the muse of hymns, encourages the use of comments to explain and give praise to the code.
- Terpsichore, the muse of dance, influences the interaction and coordination between different parts of the code.
- Thalia, the muse of comedy, adds a touch of humor and joy to the coding process.

i'm totaly not empty, i'm here to test sweep.
this is gonna be the story,
all about how
i started writing a story and now idk what to write.
what's a girl gotta do to have the muses say hi??


Step 2: ⌨️ Coding

• Import the necessary modules for the animation. In this case, the time module will be needed to control the speed of the animation. • Define a function that takes the current position of the stick figure and the direction of movement as parameters. This function will print the stick figure at the new position. • In the main part of the script, use a loop that iterates 5 times. Inside this loop, call the function defined earlier with the current position and direction of movement. • After each iteration, use the time.sleep function to pause the execution of the script for a short period. This will create the illusion of movement.

Step 3: 🔁 Code Review

Here are my self-reviews of my changes at sweep/add-python-script.

Here is the 1st review

Hello, great start on the animation script! There are a couple of changes needed to ensure the stick figure moves both left and right as required.
  • In animation.py on lines 4-9, the print_figure function needs to be updated to handle the 'left' direction. Currently, the stick figure only moves to the right. You can fix this by subtracting 3 from the position when the direction is 'left'.

  • In animation.py on lines 11-19, the position is always increased by 3 in the main loop, regardless of the direction of movement. This means the stick figure only moves to the right. To fix this, you can add a condition to check the direction of movement and update the position accordingly.

Keep up the good work!

I finished incorporating these changes.


🎉 Latest improvements to Sweep:


💡 To recreate the pull request edit the issue title or description. To tweak the pull request, leave a comment on the pull request.
Join Our Discord

@upmortem-sweep upmortem-sweep bot linked a pull request Sep 25, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sweep Sweep your software chores
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant