[PR #985] [CLOSED] Add deadlock guard for Queue{Update,Event} #1099

Closed
opened 2026-03-04 01:09:26 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/rivo/tview/pull/985
Author: @diamondburned
Created: 5/8/2024
Status: Closed

Base: masterHead: deadlock-guard


📝 Commits (1)

  • 986849f Add deadlock guard for Queue{Update,Event}

📊 Changes

2 files changed (+61 additions, -0 deletions)

View changed files

📝 application.go (+13 -0)
application_test.go (+48 -0)

📄 Description

This commit adds an atomic bool into Application that ensures that the
user can never call QueueUpdate or QueueEvent in the main loop.

Previously, when the user does this, the application would deadlock and
freeze forever. The user would often have to kill the process manually
to get out of this state. Now, the application will panic, indicating
the bug immediately.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/rivo/tview/pull/985 **Author:** [@diamondburned](https://github.com/diamondburned) **Created:** 5/8/2024 **Status:** ❌ Closed **Base:** `master` ← **Head:** `deadlock-guard` --- ### 📝 Commits (1) - [`986849f`](https://github.com/rivo/tview/commit/986849f093419122e6e698aebcb53554d8a1e795) Add deadlock guard for Queue{Update,Event} ### 📊 Changes **2 files changed** (+61 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `application.go` (+13 -0) ➕ `application_test.go` (+48 -0) </details> ### 📄 Description This commit adds an atomic bool into Application that ensures that the user can never call QueueUpdate or QueueEvent in the main loop. Previously, when the user does this, the application would deadlock and freeze forever. The user would often have to kill the process manually to get out of this state. Now, the application will panic, indicating the bug immediately. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-04 01:09:26 +03:00
Sign in to join this conversation.
No milestone
No project
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
starred/tview#1099
No description provided.