I was confused on how to add a shape using a queue in canvas. I'm trying to add a triangle. This is the code I've got. I'm getting an error >>> AttributeError: 'Queue' object has no attribute 'enqueue'
I've been trying this for awhile now and I thought I had the right idea, I just need some guidelines thanks!
from tkinter import *
root = Tk()
from queue import *
self.items = 
return self.items == 
def enqueue(self, item):
def __init__(self, height=60, width=80):
self.queue = Queue()
self.button5 = Button(self.frame, text = "Add Arc", command = self.random_arc)
self.button5.pack(side = 'left')
w = random.randrange(45)
h = random.randrange(90)
tes = Recta()
tes = Queue()
For the module queue I don't see a function enqueue().
Is it possible, that python is taking the "wrong"
Queue, meaning the one from inside the module queue?
Maybe start by renaming your class "Queue" to something different like "Queue1".
Or just use the
queue.Queue from the module.