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

Revamp Terminal Utilities and Queries #131

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

AnonymouX47
Copy link
Owner

@AnonymouX47 AnonymouX47 commented Sep 11, 2024

  • Adds .terminal submodule.
    • ActiveTerminalSyncProcess
    • TTY
    • get_active_terminal()
    • @with_active_terminal_lock
    • NoActiveTerminalError
    • NoMultiProcessSyncWarning

- Add: A submodule for terminal utilities.
- Add: `TTY` class.
- Add: `get_active_terminal()`.
- Add: To `.terminal`:
  - `ActiveTerminalSyncProcess`
  - `@active_terminal_sync`
  - `NoMultiProcessSyncWarning`

- Add: `TTY.lock` instance attribute.
@AnonymouX47 AnonymouX47 added new New feature implementation improvement Implementation of improvement to an existing feature terminal query Related to terminal queries utils Related to utilities labels Sep 11, 2024
@AnonymouX47 AnonymouX47 added this to the 0.8.0 milestone Sep 11, 2024
Copy link

github-actions bot commented Sep 11, 2024

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  src/term_image/terminal
  __init__.py 5-456, 484-791
Project Total  

This report was generated by python-coverage-comment-action

- Add: `NoActiveTerminalError`.
- Change: `get_active_terminal()` no longer returns `None`. Instead, it
  now raises `NoActiveTerminalError`.
- Add: `.read_raw()`, `.read_available()`.
- Add: `.query()`.
- Add: `TTY.lock()`.
- Change: `TTY.lock` -> `._lock`.
- Change: `@active_terminal_sync` -> `@with_active_terminal_lock`.
- Change: Update docstrings.
@AnonymouX47 AnonymouX47 force-pushed the terminal-utils-and-queries branch from 1fd0132 to 27bc0aa Compare September 27, 2024 16:41
- Add: `TerminalError`, `TTYError`.
- Change: `NoActiveTerminalError` now inherits from `TerminalError`.
- Change: Update the description of `NoActiveTerminalError` for
  `get_active_terminal()`.
- Add: `TTYSize`, `TTY.get_size()`.
- Add: `TERMINAL_INFO`, `ReadOnlyTerminalInfo`, `TerminalInfo`.
@AnonymouX47 AnonymouX47 force-pushed the terminal-utils-and-queries branch from 7eed77b to 26250bb Compare October 7, 2024 10:47
@AnonymouX47 AnonymouX47 force-pushed the terminal-utils-and-queries branch from cec8dcc to 47f62ae Compare October 7, 2024 10:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Implementation of improvement to an existing feature new New feature implementation terminal query Related to terminal queries utils Related to utilities
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant