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

Infinite Loop in food_ordering_system.py #23

Open
slayer321 opened this issue Apr 9, 2021 · 1 comment · May be fixed by #24
Open

Infinite Loop in food_ordering_system.py #23

slayer321 opened this issue Apr 9, 2021 · 1 comment · May be fixed by #24

Comments

@slayer321
Copy link

There is an error in the dequeue method in the Queue class as when I'm running this program
food_ordering_system.py . I'm getting an infinite loop

Placing order for: samosa
Placing order for:Now serving:  pizza
 pasta
Placing order for: biryani
Placing order for: burger
Now serving:  samosa
Now serving:  pasta
Now serving:  biryani
Now serving:  burger
Queue is empty
Now serving:  None
Queue is empty
Now serving:  None
Queue is empty
Now serving:  None
Queue is empty
Now serving:  None
Queue is empty
Now serving:  None
Queue is empty
Now serving:  None 

and it goes on
I think this error can be solved by using the try and except block
I'm new to open source and trying to make my contribution.
I will work on this issue.
can you guide me?

@slayer321
Copy link
Author

got the solution
I'm going to PR
please do merge it

@slayer321 slayer321 linked a pull request Apr 9, 2021 that will close this issue
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 a pull request may close this issue.

1 participant