-
Notifications
You must be signed in to change notification settings - Fork 68
Open
Labels
Description
Bug Report
Expected Behaviour
saving and opening text files should work
Actual Behaviour
produces errors for saveBox and openBox respectively
Any error messages produced by appJar
Exception in Tkinter callback
Traceback (most recent call last):
File "/usr/lib/python3.10/tkinter/__init__.py", line 1921, in __call__
return self.func(*args)
File "/home/name/.local/lib/python3.10/site-packages/appJar/appjar.py", line 3783, in <lambda>
return lambda *args: funcName(param)
File "/home/name/example.py", line 43, in menus
if win.textAreaChanged("win"): save()
File "/home/name/example.py", line 19, in save
file.write(text)
AttributeError: 'str' object has no attribute 'write'
Exception in Tkinter callback
Traceback (most recent call last):
File "/usr/lib/python3.10/tkinter/__init__.py", line 1921, in __call__
return self.func(*args)
File "/home/name/.local/lib/python3.10/site-packages/appJar/appjar.py", line 3783, in <lambda>
return lambda *args: funcName(param)
File "/home/name/example.py", line 38, in menus
open()
File "/home/name/example.py", line 9, in open
contents = file.read()
AttributeError: 'str' object has no attribute 'read'
Fix
add asFile=True
parameter to saveBox and openBox