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

Invalid File URL #412

Closed
HailKagamine123 opened this issue May 18, 2024 · 7 comments
Closed

Invalid File URL #412

HailKagamine123 opened this issue May 18, 2024 · 7 comments

Comments

@HailKagamine123
Copy link

I followed your instruction on how to copy the File URL but for the past few hours I kept receiving the error message, "Please enter a valid file URL." I even tried clicking the frame first before actually trying to copy the file URL, but it still wont work.

image

@anuragverma77
Copy link

go to gui/gui.py and replace at line #48
r'https://www.figma.com/file/([0-9A-Za-z]+)', URL.strip())
with
r'https://www.figma.com/design/([0-9A-Za-z]+)', URL.strip())

@RiumiToki
Copy link

RiumiToki commented May 18, 2024

go to gui/gui.py and replace at line #48 r'https://www.figma.com/file/([0-9A-Za-z]+)', URL.strip()) with r'https://www.figma.com/design/([0-9A-Za-z]+)', URL.strip())

F:\Tkinter-Designer-master>python -u "f:\Tkinter-Designer-master\gui\gui.py"
Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.2544.0_x64__qbz5n2kfra8p0\Lib\tkinter_init_.py", line 1967, in call
return self.func(*args)
^^^^^^^^^^^^^^^^
File "f:\Tkinter-Designer-master\gui\gui.py", line 72, in btn_clicked
designer.design()
File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 32, in design
code = self.to_code()
^^^^^^^^^^^^^^
File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 19, in to_code
for f in self.file_data["document"]["children"][0]["children"]:
~~~~~~~~~~~~~~^^^^^^^^^^^^
KeyError: 'document'

@AngeleAkane
Copy link

go to gui/gui.py and replace at line #48 r'https://www.figma.com/file/([0-9A-Za-z]+)', URL.strip()) with r'https://www.figma.com/design/([0-9A-Za-z]+)', URL.strip())

F:\Tkinter-Designer-master>python -u "f:\Tkinter-Designer-master\gui\gui.py" Exception in Tkinter callback Traceback (most recent call last): File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.2544.0_x64__qbz5n2kfra8p0\Lib\tkinter__init__.py", line 1967, in call return self.func(*args) ^^^^^^^^^^^^^^^^ File "f:\Tkinter-Designer-master\gui\gui.py", line 72, in btn_clicked designer.design() File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 32, in design code = self.to_code() ^^^^^^^^^^^^^^ File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 19, in to_code for f in self.file_data["document"]["children"][0]["children"]: ~~~~~~~~~~~~~~^^^^^^^^^^^^ KeyError: 'document'

I dunno what you did but it worked for me.

@RiumiToki
Copy link

go to gui/gui.py and replace at line #48 r'https://www.figma.com/file/([0-9A-Za-z]+)', URL.strip()) with r'https://www.figma.com/design/([0-9A-Za-z]+)', URL.strip())

F:\Tkinter-Designer-master>python -u "f:\Tkinter-Designer-master\gui\gui.py" Exception in Tkinter callback Traceback (most recent call last): File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.2544.0_x64__qbz5n2kfra8p0\Lib\tkinter__init__.py", line 1967, in call return self.func(*args) ^^^^^^^^^^^^^^^^ File "f:\Tkinter-Designer-master\gui\gui.py", line 72, in btn_clicked designer.design() File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 32, in design code = self.to_code() ^^^^^^^^^^^^^^ File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 19, in to_code for f in self.file_data["document"]["children"][0]["children"]: ~~~~~~~~~~~~~~^^^^^^^^^^^^ KeyError: 'document'

I dunno what you did but it worked for me.

Do you mind sending me the full gui.py code please? or better help me generate the code from my figma file. It would be such a great help. https://www.figma.com/design/pRjWLN5nq838lUUXdz4FIi/Untitled?node-id=0%3A1&t=FOS74B01VILl6m4C-1 ty

@mozaddedalfeshani
Copy link

Thank's man it's work for me

@ParthJadhav
Copy link
Owner

solved in latest commit.

@AngeleAkane
Copy link

go to gui/gui.py and replace at line #48 r'https://www.figma.com/file/([0-9A-Za-z]+)', URL.strip()) with r'https://www.figma.com/design/([0-9A-Za-z]+)', URL.strip())

F:\Tkinter-Designer-master>python -u "f:\Tkinter-Designer-master\gui\gui.py" Exception in Tkinter callback Traceback (most recent call last): File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.2544.0_x64__qbz5n2kfra8p0\Lib\tkinter__init__.py", line 1967, in call return self.func(*args) ^^^^^^^^^^^^^^^^ File "f:\Tkinter-Designer-master\gui\gui.py", line 72, in btn_clicked designer.design() File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 32, in design code = self.to_code() ^^^^^^^^^^^^^^ File "F:\Tkinter-Designer-master\tkdesigner\designer.py", line 19, in to_code for f in self.file_data["document"]["children"][0]["children"]: ~~~~~~~~~~~~~~^^^^^^^^^^^^ KeyError: 'document'

I dunno what you did but it worked for me.

Do you mind sending me the full gui.py code please? or better help me generate the code from my figma file. It would be such a great help. https://www.figma.com/design/pRjWLN5nq838lUUXdz4FIi/Untitled?node-id=0%3A1&t=FOS74B01VILl6m4C-1 ty

Sorry for this last response. Try to download again Tkinter Designer and do the steps. Probably you deleted something.

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

No branches or pull requests

6 participants