Tkinter-Designer icon indicating copy to clipboard operation
Tkinter-Designer copied to clipboard

ERROR : Frame not found (BUT FRAME IS THERE)

Open Euclid737 opened this issue 2 years ago • 5 comments

I have created a Design file in Figma, following the steps of the Element Guide as described in https://github.com/ParthJadhav/Tkinter-Designer/blob/master/docs/instructions.md The created page (File URL) is https://www.figma.com/file/dL344FdpJakjdUg4kEHz6X/iMagine?type=design&node-id=0%3A1&mode=design&t=OpdSedRuJcmGgr19-1

I give this and my Token ID in 'gui.py' AND IT STARTS TO CREATE THE ELEMENTS BUT it gives this error : Frame not found in figma file or is empty

Here is the full error:

`PS D:\Tkinter-Designer-master> & "D:/Users/Computer Hub/AppData/Local/Programs/Python/Python312/python.exe" d:/Tkinter-Designer-master/gui/gui.py Creating Element { name: button, type: rectangle } Exception in Tkinter callback Traceback (most recent call last): File "D:\Tkinter-Designer-master\tkdesigner\designer.py", line 21, in to_code frame = Frame(f, self.figma_file, self.output_path, self.frameCounter) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\Tkinter-Designer-master\tkdesigner\figma\frame.py", line 30, in init self.create_element(child) File "D:\Tkinter-Designer-master\tkdesigner\figma\frame.py", line 51, in create_element download_image(image_url, image_path) File "D:\Tkinter-Designer-master\tkdesigner\utils.py", line 23, in download_image im = im.resize((im.size[0] // 2, im.size[1] // 2), Image.ANTIALIAS) ^^^^^^^^^^^^^^^ AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\Users\Computer Hub\AppData\Local\Programs\Python\Python312\Lib\tkinter_init_.py", line 1948, in call return self.func(*args) ^^^^^^^^^^^^^^^^ File "d:\Tkinter-Designer-master\gui\gui.py", line 72, in btn_clicked designer.design() File "D:\Tkinter-Designer-master\tkdesigner\designer.py", line 32, in design code = self.to_code() ^^^^^^^^^^^^^^ File "D:\Tkinter-Designer-master\tkdesigner\designer.py", line 23, in to_code raise Exception("Frame not found in figma file or is empty") Exception: Frame not found in figma file or is empty`

Please help me.

Euclid737 avatar Dec 16 '23 10:12 Euclid737

I had the same issue, but i resolved the issue. This error is occurring because one module in pillow package is deprecated. So if you have the latest python 3.12.1, you'll have to install latest pillow package version and use that latest module.

adetyay avatar Dec 17 '23 08:12 adetyay

I am having the same issue and only downloaded yesterday 12/3/24. I have tried to update Pillow but it has stated it is up to date. please help.

Creating Element { name: image, type: rectangle } Creating Element { name: button, type: ellipse } Exception in Tkinter callback Traceback (most recent call last): File "D:\Users\gaming\Python\source\Tkinter-Designer-master\tkdesigner\designer.py", line 21, in to_code frame = Frame(f, self.figma_file, self.output_path, self.frameCounter) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\Users\gaming\Python\source\Tkinter-Designer-master\tkdesigner\figma\frame.py", line 29, in init self.elements = [ ^ File "D:\Users\gaming\Python\source\Tkinter-Designer-master\tkdesigner\figma\frame.py", line 30, in self.create_element(child) File "D:\Users\gaming\Python\source\Tkinter-Designer-master\tkdesigner\figma\frame.py", line 51, in create_element download_image(image_url, image_path) File "D:\Users\gaming\Python\source\Tkinter-Designer-master\tkdesigner\utils.py", line 20, in download_image response = requests.get(url) ^^^^^^^^^^^^^^^^^ File "C:\Python311\Lib\site-packages\requests\api.py", line 76, in get return request('get', url, params=params, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Python311\Lib\site-packages\requests\api.py", line 61, in request return session.request(method=method, url=url, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Python311\Lib\site-packages\requests\sessions.py", line 528, in request prep = self.prepare_request(req) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Python311\Lib\site-packages\requests\sessions.py", line 456, in prepare_request p.prepare( File "C:\Python311\Lib\site-packages\requests\models.py", line 316, in prepare self.prepare_url(url, params) File "C:\Python311\Lib\site-packages\requests\models.py", line 390, in prepare_url raise MissingSchema(error) requests.exceptions.MissingSchema: Invalid URL 'None': No schema supplied. Perhaps you meant http://None?

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python311\Lib\tkinter_init_.py", line 1948, in call return self.func(*args) ^^^^^^^^^^^^^^^^ File "D:\Users\gaming\Python\source\Tkinter-Designer-master\gui\gui.py", line 72, in btn_clicked designer.design() File "D:\Users\gaming\Python\source\Tkinter-Designer-master\tkdesigner\designer.py", line 32, in design code = self.to_code() ^^^^^^^^^^^^^^ File "D:\Users\gaming\Python\source\Tkinter-Designer-master\tkdesigner\designer.py", line 23, in to_code raise Exception("Frame not found in figma file or is empty") Exception: Frame not found in figma file or is empty

orcnet avatar Mar 13 '24 13:03 orcnet

I am Having the Same Error

requests.exceptions.MissingSchema: Invalid URL 'None': No schema supplied. Perhaps you meant http://None?

During handling of the above exception, another exception occurred:
...
raise Exception("Frame not found in figma file or is empty")
Exception: Frame not found in figma file or is empty

like this, Please tell me if there's any solutions

ShevamV avatar Apr 20 '24 15:04 ShevamV

same here

EVINJSUBIN avatar Aug 13 '24 12:08 EVINJSUBIN