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

WIP. Empty window titles cause errors. #183 #189

Closed
wants to merge 4 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix equality to None. flake8
  • Loading branch information
BlitzKraft committed Aug 16, 2020
commit 7316fddefa8f6afe768237042c39258f630bec31
2 changes: 1 addition & 1 deletion tmuxp/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ def expand(sconf, cwd=None, parent=None):
if 'session_name' in sconf:
sconf['session_name'] = expandshell(sconf['session_name'])
if 'window_name' in sconf:
if not (sconf['window_name'] == None):
if not (sconf['window_name'] is None):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if not (sconf['window_name'] is None):
if sconf['window_name'] is not None:

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This does not change the outcome of the test_window_title. As expected. The if statements - before and after the suggested changes - are equivalent. Were you expecting something different?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Found something. window_name is being set to tmux. Hence the failing assertion. Now, need to dig where this is happening.

sconf['window_name'] = expandshell(sconf['window_name'])
else:
sconf['shell_command'] = 'tmux rename-session \'\''
Expand Down