Title: WorkspaceBuilder creates "main-horizontal" layout with a very thin main pane · Issue #667 · tmux-python/tmuxp · GitHub
Open Graph Title: WorkspaceBuilder creates "main-horizontal" layout with a very thin main pane · Issue #667 · tmux-python/tmuxp
X Title: WorkspaceBuilder creates "main-horizontal" layout with a very thin main pane · Issue #667 · tmux-python/tmuxp
Description: Step 1: Provide a summary of your problem I am trying to use tmuxp.workspacebuilder.WorkspaceBuilder with a simple main-horizontal 3-panes scenario and the created result has the main pane of 1 line high. When invoked from command line w...
Open Graph Description: Step 1: Provide a summary of your problem I am trying to use tmuxp.workspacebuilder.WorkspaceBuilder with a simple main-horizontal 3-panes scenario and the created result has the main pane of 1 lin...
X Description: Step 1: Provide a summary of your problem I am trying to use tmuxp.workspacebuilder.WorkspaceBuilder with a simple main-horizontal 3-panes scenario and the created result has the main pane of 1 lin...
Opengraph URL: https://github.com/tmux-python/tmuxp/issues/667
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"WorkspaceBuilder creates \"main-horizontal\" layout with a very thin main pane","articleBody":"### Step 1: Provide a summary of your problem\r\n\r\nI am trying to use ` tmuxp.workspacebuilder.WorkspaceBuilder` with a simple `main-horizontal` 3-panes scenario and the created result has the main pane of 1 line high.\r\n\r\n- When invoked from command line with a yaml config file, the issue is not reproduced.\r\n- When configrued with an explicit layout, the issue is not reproduced (see configurations below)\r\n\r\n### Step 2: Provide tmuxp details\r\n\r\n```\r\n➜ tmuxp debug-info\r\n-------------------------\r\nenvironment:\r\n dist: Linux-5.4.0-65-generic-x86_64-with-glibc2.29\r\n arch: x86_64\r\n uname: Linux; exfo7255; 5.4.0-65-generic\r\n version: #73-Ubuntu SMP Mon Jan 18 17:25:17 UTC 2021\r\n-------------------------\r\npython version: 3.8.7 (default, Feb 2 2021, 16:09:27) [GCC 9.3.0]\r\nsystem PATH: \u003cREDACTED>/.venv/bin:\u003cREDACTED>\r\ntmux version: 3.0\r\nlibtmux version: 0.8.5\r\ntmuxp version: 1.7.2\r\ntmux path: /usr/bin/tmux\r\ntmuxp path:\u003cREDACTED>/.venv/lib/python3.8/site-packages/tmuxp/__init__.py\r\nshell: /usr/bin/zsh\r\n-------------------------\r\ntmux sessions:\r\n myproject: 1 windows (created Thu Feb 18 20:48:37 2021) (attached)\r\n\r\ntmux windows:\r\n 0: mainwindow* (3 panes) [189x53] [layout 0ecd,189x53,0,0[189x1,0,0,81,189x51,0,2{93x51,0,2,82,95x51,94,2,83}]] @37 (active)\r\n\r\ntmux panes:\r\n 0: [189x1] [history 14/2000, 9178 bytes] %81\r\n 1: [93x51] [history 13/2000, 6476 bytes] %82 (active)\r\n 2: [95x51] [history 14/2000, 6613 bytes] %83\r\n\r\ntmux global options:\r\n activity-action other\r\n assume-paste-time 1\r\n base-index 0\r\n bell-action none\r\n default-command\r\n default-shell /usr/bin/zsh\r\n default-size 80x24\r\n destroy-unattached off\r\n detach-on-destroy on\r\n display-panes-active-colour red\r\n display-panes-colour blue\r\n display-panes-time 1000\r\n display-time 750\r\n history-limit 2000\r\n key-table root\r\n lock-after-time 0\r\n lock-command \"lock -np\"\r\n message-command-style fg=yellow,bg=black\r\n message-style fg=black,bg=yellow\r\n mouse on\r\n prefix C-a\r\n prefix2 None\r\n renumber-windows off\r\n repeat-time 500\r\n set-titles off\r\n set-titles-string \"#S:#I:#W - \\\"#T\\\" #{session_alerts}\"\r\n silence-action other\r\n status on\r\n status-bg green\r\n status-fg black\r\n status-format[0] \"#[align=left range=left #{status-left-style}]#{T;=/#{status-left-length}:status-left}#[norange default]#[list=on align=#{status-justify}]#[list=left-marker]\u003c#[list=right-marker]>#[list=on]#{W:#[range=window|#{window_index} #{window-status-style}#{?#{&&:#{window_last_flag},#{!=:#{window-status-last-style},default}}, #{window-status-last-style},}#{?#{&&:#{window_bell_flag},#{!=:#{window-status-bell-style},default}}, #{window-status-bell-style},#{?#{&&:#{||:#{window_activity_flag},#{window_silence_flag}},#{!=:#{window-status-activity-style},default}}, #{window-status-activity-style},}}]#{T:window-status-format}#[norange default]#{?window_end_flag,,#{window-status-separator}},#[range=window|#{window_index} list=focus #{?#{!=:#{window-status-current-style},default},#{window-status-current-style},#{window-status-style}}#{?#{&&:#{window_last_flag},#{!=:#{window-status-last-style},default}}, #{window-status-last-style},}#{?#{&&:#{window_bell_flag},#{!=:#{window-status-bell-style},default}}, #{window-status-bell-style},#{?#{&&:#{||:#{window_activity_flag},#{window_silence_flag}},#{!=:#{window-status-activity-style},default}}, #{window-status-activity-style},}}]#{T:window-status-current-format}#[norange list=on default]#{?window_end_flag,,#{window-status-separator}}}#[nolist align=right range=right #{status-right-style}]#{T;=/#{status-right-length}:status-right}#[norange default]\"\r\n status-format[1] \"#[align=centre]#{P:#{?pane_active,#[reverse],}#{pane_index}[#{pane_width}x#{pane_height}]#[default] }\"\r\n status-interval 15\r\n status-justify left\r\n status-keys vi\r\n status-left \"[#S] \"\r\n status-left-length 10\r\n status-left-style default\r\n status-position bottom\r\n status-right \"#{?window_bigger,[#{window_offset_x}#,#{window_offset_y}] ,}\\\"#{=21:pane_title}\\\" %H:%M %d-%b-%y\"\r\n status-right-length 40\r\n status-right-style default\r\n status-style fg=black,bg=green\r\n update-environment[0] DISPLAY\r\n update-environment[1] KRB5CCNAME\r\n update-environment[2] SSH_ASKPASS\r\n update-environment[3] SSH_AUTH_SOCK\r\n update-environment[4] SSH_AGENT_PID\r\n update-environment[5] SSH_CONNECTION\r\n update-environment[6] WINDOWID\r\n update-environment[7] XAUTHORITY\r\n visual-activity off\r\n visual-bell off\r\n visual-silence off\r\n word-separators \" \"\r\n\r\ntmux window options:\r\n aggressive-resize off\r\n allow-rename off\r\n alternate-screen on\r\n automatic-rename on\r\n automatic-rename-format \"#{?pane_in_mode,[tmux],#{pane_current_command}}#{?pane_dead,[dead],}\"\r\n clock-mode-colour blue\r\n clock-mode-style 24\r\n main-pane-height 24\r\n main-pane-width 80\r\n mode-keys vi\r\n mode-style fg=black,bg=yellow\r\n monitor-activity off\r\n monitor-bell on\r\n monitor-silence 0\r\n other-pane-height 0\r\n other-pane-width 0\r\n pane-active-border-style fg=green\r\n pane-base-index 0\r\n pane-border-format \"#{?pane_active,#[reverse],}#{pane_index}#[default] \\\"#{pane_title}\\\"\"\r\n pane-border-status off\r\n pane-border-style default\r\n remain-on-exit off\r\n synchronize-panes off\r\n window-active-style default\r\n window-size smallest\r\n window-style default\r\n window-status-activity-style reverse\r\n window-status-bell-style reverse\r\n window-status-current-format \"#I:#W#{?window_flags,#{window_flags}, }\"\r\n window-status-current-style default\r\n window-status-format \"#I:#W#{?window_flags,#{window_flags}, }\"\r\n window-status-last-style default\r\n window-status-separator \" \"\r\n window-status-style default\r\n wrap-search on\r\n xterm-keys on\r\n```\r\n\r\n### Step 3: Describe the problem:\r\n#### Steps to reproduce:\r\n\r\nRun the following script\r\n\r\n```python\r\nimport tmuxp.workspacebuilder\r\nimport tmuxp.config\r\nimport libtmux.server\r\nimport libtmux.exc\r\n\r\ntmuxp_config = {} # see below\r\n\r\nbuilder = tmuxp.workspacebuilder.WorkspaceBuilder(\r\n tmuxp.config.trickle(\r\n tmuxp.config.expand(tmuxp_config, \".\")\r\n ),\r\n server=libtmux.server.Server()\r\n)\r\ntry:\r\n builder.build()\r\nexcept libtmux.exc.TmuxSessionExists:\r\n builder.build(builder.session)\r\nbuilder.session.attach_session()\r\nfor plugin in builder.plugins:\r\n plugin.before_script(builder.session)\r\n```\r\n\r\n#### Observed Results:\r\n\r\nThree panes are nicely, but the main (top) one has only one line of heigth\r\n\r\n#### Expected Results:\r\n\r\nPanes created with configured size.\r\n\r\n#### Relevant Code:\r\n\r\n```python\r\ntmuxp_config = {\r\n \"session_name\": \"myproject\",\r\n \"start_directory\": \".\",\r\n \"shell_command_before\": [],\r\n \"windows\": [\r\n {\r\n \"window_name\": \"mainwindow\",\r\n \"focus\": True,\r\n ### this \"abstract\" layout reproduces the issue\r\n \"layout\": \"main-horizontal\",\r\n ### This \"specific\" layout does not reproduces the issue\r\n # \"layout\": \"3951,189x53,0,0[189x35,0,0,51,189x17,0,36{94x17,0,36,52,94x17,95,36,53}]\"\r\n \"options\": {\r\n \"main-pane-height\": 35\r\n },\r\n \"panes\": [\r\n \"pane\",\r\n \"pane\",\r\n \"pane\"\r\n ]\r\n }\r\n ]\r\n}\r\n```\r\n","author":{"url":"https://github.com/cblegare","@type":"Person","name":"cblegare"},"datePublished":"2021-02-19T02:28:32Z","url":"https://github.com/tmux-python/tmuxp/issues/667"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:a6f1461d-9404-0bf9-52c2-5f6f86195d71 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8BB8:AD4E:2060E4:2D361C:6B006816 |
| html-safe-nonce | cad3d66dff045bac1e94b7447c995c891555e55a79b4696d33f108d3cca867bc |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4QkI4OkFENEU6MjA2MEU0OjJEMzYxQzo2QjAwNjgxNiIsInZpc2l0b3JfaWQiOiI0NzU1NDQ4NzU4OTg3MTU1NDc4IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 2f5ba5b4302916d0eea0f991a864c04e24067f355070c7ebdf615f40b9a67de6 |
| hovercard-subject-tag | issue:811628210 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/tmux-python/tmuxp/667/issue_layout |
| twitter:image | https://opengraph.githubassets.com/a0c3fc320d6823b679c18203800d679116dc3897605e5f71457fcb1fe9868215/tmux-python/tmuxp/issues/667 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/a0c3fc320d6823b679c18203800d679116dc3897605e5f71457fcb1fe9868215/tmux-python/tmuxp/issues/667 |
| og:image:alt | Step 1: Provide a summary of your problem I am trying to use tmuxp.workspacebuilder.WorkspaceBuilder with a simple main-horizontal 3-panes scenario and the created result has the main pane of 1 lin... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | cblegare |
| hostname | github.com |
| expected-hostname | github.com |
| None | 25854482a1773a7c1ebb8be3d2bc1c6e61d82d78126be63b5044474a86d44d9e |
| turbo-cache-control | no-preview |
| go-import | github.com/tmux-python/tmuxp git https://github.com/tmux-python/tmuxp.git |
| octolytics-dimension-user_id | 37234308 |
| octolytics-dimension-user_login | tmux-python |
| octolytics-dimension-repository_id | 12398170 |
| octolytics-dimension-repository_nwo | tmux-python/tmuxp |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 12398170 |
| octolytics-dimension-repository_network_root_nwo | tmux-python/tmuxp |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | e4f5c239e31f1f680e6bbc419ff92d774da616ec |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width