File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change 15
15
from libtmux .exc import LibTmuxException
16
16
from tmuxp import cli , config , exc
17
17
from tmuxp .cli import (
18
- command_ls ,
19
18
command_debug_info ,
19
+ command_ls ,
20
20
get_config_dir ,
21
21
is_pure_name ,
22
22
load_workspace ,
@@ -533,7 +533,7 @@ def test_shell(
533
533
{},
534
534
{},
535
535
LibTmuxException ,
536
- r'.*DoesNotExist\s\(No such file or directory\) .*' ,
536
+ r'.*DoesNotExist.*' ,
537
537
),
538
538
(
539
539
[
Original file line number Diff line number Diff line change @@ -83,7 +83,10 @@ def raise_if_tmux_not_running(server):
83
83
try :
84
84
server .sessions
85
85
except LibTmuxException as e :
86
- if 'No such file or directory' in str (e ):
86
+ if any (
87
+ needle in str (e )
88
+ for needle in ['No such file or directory' , 'no server running on' ]
89
+ ):
87
90
raise LibTmuxException (
88
91
'no tmux session found. Start a tmux session and try again. \n '
89
92
'Original error: ' + str (e )
You can’t perform that action at this time.
0 commit comments