trap HUP does not what expected

Open
#2,760 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
50/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
macos, zsh

Research direction

Start by reproducing the trap 'touch ~/abc' HUP command in Warp with zsh, then compare window-closing behavior with Terminal.app on macOS. Trace how Warp handles the HUP signal when a terminal window closes; done means the trap creates ~/abc as it does in Terminal.app.

Written by the indexing model from the issue text.

Description

bug needs-info ready-to-implement triaged
Discord username (optional)

No response

Describe the bug

When running trap 'touch ~/abc' HUP I expect it to work same as in Terminal.app, which is that the file abc is to be created in home folder when closing Warp window.

Note

I'm using zsh in both Warp.app and Terminal.app.

To Reproduce

Using Warp.app

  1. Check that Warp.app is using zsh by running echo $0
  2. trap 'touch ~/abc' HUP
  3. Close terminal window
  4. See that no file named abc exists in home folder.
Expected behaviour

Using Terminal.app

  1. Check that Terminal.app is using zsh by running echo $0
  2. trap 'touch ~/abc' HUP
  3. Close terminal window
  4. See that a file named abc exists in home folder.
Screenshots

No response

Operating System

MacOS

OS Version

13.2

Shell Version

zsh 5.8.1 (x86_64-apple-darwin22.0)

Warp Version

v0.2023.03.07.08.02.stable_01

Additional context

No response

Does this block you from using Warp daily?

No

Warp Internal (ignore): linear-label:b8107fdf-ba31-488d-b103-d271c89cac3e

None

Dominant language
Rust
Stars
65.1k
Forks
5.6k
PR merge metrics
PR metrics pending

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from warpdotdev/warp

All issues in warpdotdev/warp

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.