Can't find any not outdated answers, I'm creating a canvas and running a filepath through PhotoImage so I can create_image in the canvas, but I'm getting an error that says the image {path} does not exist, despite the image obviously existing because I used the exact same path to get it with requests, and I can open the file and there's nothing wrong with the path or the image. in init:
self.cover_canvas = Canvas(width=100, height=200)
later in the class:
def load_image(self):
self.cover_image = PhotoImage(self.image_loc)
self.cover_canvas.create_image(50, 100, image=self.cover_image)
self.cover_canvas.grid(row=4, column=1)
Edit: The PIL solution ended up working, thought it might be outdated because when I tried to pip install PIL it failed to find a current version, but I just tried PIP installing is with the name "Pillow" and at first I thought it still didn't work because when I tried to import from Pillow nothing worked, but when I tried importing from PIL after pip installing Pillow it worked. Kinda weird but wtv.