Title: Creating standalone executable - possibly SOLVED · Issue #38 · webui-dev/python-webui · GitHub
Open Graph Title: Creating standalone executable - possibly SOLVED · Issue #38 · webui-dev/python-webui
X Title: Creating standalone executable - possibly SOLVED · Issue #38 · webui-dev/python-webui
Description: Hi, I had problem with creating standalone executable, but I have figured it out. I am not confident to make a pull request, but I'd like to share it at least this way. I am using auto-py-to-exe to make the binary both on Windows and Lin...
Open Graph Description: Hi, I had problem with creating standalone executable, but I have figured it out. I am not confident to make a pull request, but I'd like to share it at least this way. I am using auto-py-to-exe to...
X Description: Hi, I had problem with creating standalone executable, but I have figured it out. I am not confident to make a pull request, but I'd like to share it at least this way. I am using auto-py-to-ex...
Opengraph URL: https://github.com/webui-dev/python-webui/issues/38
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Creating standalone executable - possibly SOLVED","articleBody":"Hi, I had problem with creating standalone executable, but I have figured it out. I am not confident to make a pull request, but I'd like to share it at least this way.\nI am using auto-py-to-exe to make the binary both on Windows and Linux. The problem was:\n\n1. Missing dynamic library from webui\n2. Wrong path to web files - if you want them separately, like `examples/andershell3000` with `ui` folder, resulting in \"Resource Not Available\" at runtime window.\n\nThe solution to missing library was to adding this option in auto-py-to-exe: `Advanced` ➝ `What to bundle, where to search` ➝ `--collect-binaries` type: `webui`\nSo the complete pyinstaller command was like this in my case: `pyinstaller --noconfirm --onefile --windowed --add-data \"/home/gordon/Dokumenty/PlatformIO/Projects/python-webui/examples/andershell3000/ui:ui/\" --collect-binaries \"webui\" \"/home/gordon/Dokumenty/PlatformIO/Projects/python-webui/examples/andershell3000/andershell3000.py\"` Do not forget to add the `ui` folder as well.\n\nThe solution to wrong webfile's path was to dynamically creating absolute path on runtime. Let's take `examples/andershell3000/andershell3000.py`. By changing it like this:\n```\nimport os\n.\n.\n.\nhtml_folder = os.path.join(os.path.dirname(__file__), \"ui\")\nMyWindow.set_root_folder(html_folder)\n.\n.\n.\n```\nthe problem is gone. It took me quite some time to figure it out. Could you please review my approach and implement it if feasible?","author":{"url":"https://github.com/triuk","@type":"Person","name":"triuk"},"datePublished":"2025-07-01T12:17:05.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/38/python-webui/issues/38"}
| 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:5a425283-3d5f-73eb-d6ac-5d7f034cea23 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9900:3276F1:6D1430:977157:6978BCC0 |
| html-safe-nonce | 9010e8098a9a14d3f41d5cb62830a526fd1f693ee21ce8e8edc758c3141cbacf |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5OTAwOjMyNzZGMTo2RDE0MzA6OTc3MTU3OjY5NzhCQ0MwIiwidmlzaXRvcl9pZCI6IjY4MjcwNjMzMjU4MDExMDI1MjkiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 2a78fee9a4d16ddde11ea74d605978775386db6b54015d476f89561e30dc9738 |
| hovercard-subject-tag | issue:3192251120 |
| 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/webui-dev/python-webui/38/issue_layout |
| twitter:image | https://opengraph.githubassets.com/6bcd8af65f4ba792bd474a88f4cfaa82e21b1dcead7b745dd32b07eaddd68612/webui-dev/python-webui/issues/38 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/6bcd8af65f4ba792bd474a88f4cfaa82e21b1dcead7b745dd32b07eaddd68612/webui-dev/python-webui/issues/38 |
| og:image:alt | Hi, I had problem with creating standalone executable, but I have figured it out. I am not confident to make a pull request, but I'd like to share it at least this way. I am using auto-py-to-exe to... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | triuk |
| hostname | github.com |
| expected-hostname | github.com |
| None | 2981c597c945c1d90ac6fa355ce7929b2f413dfe7872ca5c435ee53a24a1de50 |
| turbo-cache-control | no-preview |
| go-import | github.com/webui-dev/python-webui git https://github.com/webui-dev/python-webui.git |
| octolytics-dimension-user_id | 133399259 |
| octolytics-dimension-user_login | webui-dev |
| octolytics-dimension-repository_id | 639987720 |
| octolytics-dimension-repository_nwo | webui-dev/python-webui |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 639987720 |
| octolytics-dimension-repository_network_root_nwo | webui-dev/python-webui |
| 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 | 9520342ca7ead2f1a011aa96eaff82fc054a4970 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width