1
0
Fork
You've already forked fb
0

Refreshing too many times causes app to crash #5

Closed
opened 2024年03月21日 23:55:04 +01:00 by WinFan3672 · 1 comment
 Traceback (most recent call last) ╮
 /home/REDACTED/venv/lib/python3.11/site-packages/textual/worker.py:362 in _run 
 
 359 self.state = WorkerState.RUNNING locals ╮ 
 360 app.log.worker(self) app = MainApp(title='', classes={'-dark-mode'}) 
 361 try: error = ValueError('task_done() called too many times') 
 ❱ 362 self._result = await self.run() self = <Worker ERROR name='_loader' description='_loader()'> 
 363 except asyncio.CancelledError as error: Traceback = <class 'rich.traceback.Traceback'> 
 364 self.state = WorkerState.CANCELLED ╰╯ 
 365 self._error = error 
 
 /home/REDACTED/venv/lib/python3.11/site-packages/textual/worker.py:346 in run 
 
 343 Returns: locals ╮ 
 344 Return value of the work. self = <Worker ERROR name='_loader' description='_loader()'> 
 345 """ ╰╯ 
 ❱ 346 return await ( 
 347 self._run_threaded() if self._thread_worker else self._run_async() 
 348 ) 
 349 
 
 /home/REDACTED/venv/lib/python3.11/site-packages/textual/worker.py:331 in _run_async 
 
 328 or hasattr(self._work, "func") locals ╮ 
 329 and inspect.iscoroutinefunction(self._work.func) self = <Worker ERROR name='_loader' description='_loader()'> 
 330 ): ╰╯ 
 ❱ 331 return await self._work() 
 332 elif inspect.isawaitable(self._work): 
 333 return await self._work 
 334 elif callable(self._work): 
 
 /home/REDACTED/venv/lib/python3.11/site-packages/textual/widgets/_directory_tree.py:442 in _loader 
 
 439 self._populate_node(node, content) locals ╮ 
 440 finally: content = [ 
 441 # Mark this iteration as done. PosixPath('/home/REDACTED/$GAMEDIR'), 
 ❱ 442 self._load_queue.task_done() PosixPath('/home/REDACTED/.aMule'), 
 443 PosixPath('/home/REDACTED/.android'), 
 444 async def _on_tree_node_expanded(self, event: Tree.NodeExpanded) -> None: PosixPath('/home/REDACTED/.aqbanking'), 
 445 event.stop() PosixPath('/home/REDACTED/.beef'), 
 PosixPath('/home/REDACTED/.bitmonero'), 
 PosixPath('/home/REDACTED/.bundle'), 
 PosixPath('/home/REDACTED/.cache'), 
 PosixPath('/home/REDACTED/.cargo'), 
 PosixPath('/home/REDACTED/.cert'), 
 ... +762 
 ] 
 node = TreeNode('/home/REDACTED', DirEntry(path=PosixPath('/home/REDACTED'), loaded=True)) 
 self = DirTree(id='ltDir') 
 worker = <Worker ERROR name='_loader' description='_loader()'> 
 ╰╯ 
 
 /usr/lib/python3.11/asyncio/queues.py:201 in task_done 
 
 198 the queue. locals ╮ 
 199 """ self = <Queue at 0x7fa7200d8950 maxsize=0> 
 200 if self._unfinished_tasks <= 0: ╰╯ 
 ❱ 201 raise ValueError('task_done() called too many times') 
 202 self._unfinished_tasks -= 1 
 203 if self._unfinished_tasks == 0: 
 204 self._finished.set() 
╰
``` Traceback (most recent call last) ╮ /home/REDACTED/venv/lib/python3.11/site-packages/textual/worker.py:362 in _run 359 self.state = WorkerState.RUNNING locals ╮ 360 app.log.worker(self) app = MainApp(title='', classes={'-dark-mode'}) 361 try: error = ValueError('task_done() called too many times') ❱ 362 self._result = await self.run() self = <Worker ERROR name='_loader' description='_loader()'> 363 except asyncio.CancelledError as error: Traceback = <class 'rich.traceback.Traceback'> 364 self.state = WorkerState.CANCELLED ╰╯ 365 self._error = error /home/REDACTED/venv/lib/python3.11/site-packages/textual/worker.py:346 in run 343 Returns: locals ╮ 344 Return value of the work. self = <Worker ERROR name='_loader' description='_loader()'> 345 """ ╰╯ ❱ 346 return await ( 347 self._run_threaded() if self._thread_worker else self._run_async() 348 ) 349 /home/REDACTED/venv/lib/python3.11/site-packages/textual/worker.py:331 in _run_async 328 or hasattr(self._work, "func") locals ╮ 329 and inspect.iscoroutinefunction(self._work.func) self = <Worker ERROR name='_loader' description='_loader()'> 330 ): ╰╯ ❱ 331 return await self._work() 332 elif inspect.isawaitable(self._work): 333 return await self._work 334 elif callable(self._work): /home/REDACTED/venv/lib/python3.11/site-packages/textual/widgets/_directory_tree.py:442 in _loader 439 self._populate_node(node, content) locals ╮ 440 finally: content = [ 441 # Mark this iteration as done. PosixPath('/home/REDACTED/$GAMEDIR'), ❱ 442 self._load_queue.task_done() PosixPath('/home/REDACTED/.aMule'), 443 PosixPath('/home/REDACTED/.android'), 444 async def _on_tree_node_expanded(self, event: Tree.NodeExpanded) -> None: PosixPath('/home/REDACTED/.aqbanking'), 445 event.stop() PosixPath('/home/REDACTED/.beef'), PosixPath('/home/REDACTED/.bitmonero'), PosixPath('/home/REDACTED/.bundle'), PosixPath('/home/REDACTED/.cache'), PosixPath('/home/REDACTED/.cargo'), PosixPath('/home/REDACTED/.cert'), ... +762 ] node = TreeNode('/home/REDACTED', DirEntry(path=PosixPath('/home/REDACTED'), loaded=True)) self = DirTree(id='ltDir') worker = <Worker ERROR name='_loader' description='_loader()'> ╰╯ /usr/lib/python3.11/asyncio/queues.py:201 in task_done 198 the queue. locals ╮ 199 """ self = <Queue at 0x7fa7200d8950 maxsize=0> 200 if self._unfinished_tasks <= 0: ╰╯ ❱ 201 raise ValueError('task_done() called too many times') 202 self._unfinished_tasks -= 1 203 if self._unfinished_tasks == 0: 204 self._finished.set() ╰ ```
Author
Owner
Copy link

Manual refreshes are disabled as of 0.2.2, therefore this issue is highly unlikely to occur.

Manual refreshes are disabled as of 0.2.2, therefore this issue is highly unlikely to occur.
Sign in to join this conversation.
No Branch/Tag specified
main
v0.3.1
v0.3.0
v0.2.3
v0.2.2
v0.2.1
v0.2.0
v0.1.0
Labels
Clear labels
Kind/Breaking
Breaking change that won't be backward compatible
Kind/Bug
Something is not working
Kind/Documentation
Documentation changes
Kind/Enhancement
Improve existing functionality
Kind/Feature
New functionality
Kind/Security
This is security issue
Kind/Testing
Issue or pull request related to testing
Priority
Critical
The priority is critical
Priority
High
The priority is high
Priority
Low
The priority is low
Priority
Medium
The priority is medium
Reviewed
Confirmed
Issue has been confirmed
Reviewed
Duplicate
This issue or pull request already exists
Reviewed
Invalid
Invalid issue
Reviewed
Won't Fix
This issue won't be fixed
Status
Abandoned
Somebody has started to work on this but abandoned work
Status
Blocked
Something is blocking this issue or pull request
Status
Need More Info
Feedback is required to reproduce issue or to continue work
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
WinFan3672/fb#5
Reference in a new issue
WinFan3672/fb
No description provided.
Delete branch "%!s()"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?