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
Issues with flet build --template_dir option (flet 0.19.0) #2437
Comments
Option has been fixed in the docs. What is the problem? Actually, it is absolute path to the And why are you using |
@taaaf11 , thanks for fixing the typo in the guide. If From:
To:
I used
|
Yup you are right. Actually, it's a path relative to the HOME directory of the user. Like, when I was trying to reproduce, it suggests that it searches for the the template in path |
On macOS, below is the code to build specifying the local template.
If there's no plan to fix Flet codes to accept relative path soon, the online guide should explain "--template-dir option specifies an absolute path to a cookiecutter template in a repository." |
|
@tokyohandsome wait a second, that |
nope, I tried, but it gave an error like |
OK, will take a look. But again, it's only when |
yes |
Sorry for not getting back sooner. |
You are right. Absolute path works |
OK, I'm going to resolve --template-dir relative to the current directory (pwd). |
OK, have a misunderstanding here! Look, to provide a path to a directory with your custom template you have to use
For example, if my template is in
or (relatively to current dir):
or I can specify
so, |
Description
A couple of issues when building app with
--template_dir
option.Code example to reproduce the issue:
--template_dir
explained in the online document must be a typo.--template-dir
(not an underscore but a dash between template and dir) is correct.Result with
--template_dir
:flet build macos --template-dir flet-build-template
won't work. Need to give it a full-path or usepwd
like:--template-dir `pwd`/flet-build-template
.Result of relative path:
Describe the results you received:
See above.
Describe the results you expected:
See above.
Flet version (
pip show flet
):Name: flet
Version: 0.19.0
Summary: Flet for Python - easily build interactive multi-platform apps in Python
Home-page:
Author: Appveyor Systems Inc.
Author-email: hello@flet.dev
License: Apache-2.0
Location: /Users/handsome/Documents/Python/passgen/.venv/lib/python3.11/site-packages
Requires: cookiecutter, flet-runtime, packaging, qrcode, watchdog, websocket-client, websockets
Required-by:
Operating system:
OS: macOS 14.2.1
Additional environment details:
pipenv version 2023.10.24
The text was updated successfully, but these errors were encountered: