flet-dev / serious-python

Python runtime for Flutter apps
Apache License 2.0
211 stars 22 forks source link

Error during `flet build` when requirements.txt contains empty lines or comments #102

Closed allieus closed 1 month ago

allieus commented 4 months ago

Description

When running the flet build command, an error occurs if the requirements.txt file in the project contains empty lines. This results in an ERROR: Invalid requirement: '' message, preventing the successful packaging of the Flet application.

image

Note: Removing all empty lines from requirements.txt allows the build to complete successfully.

image

Reproduction Steps

  1. Create a Flet project with a requirements.txt file.
  2. Add one or more empty lines between package names in requirements.txt.

last line is empty.

flet==0.23.2
  1. Run the flet build command.
  2. Observe the error message: ERROR: Invalid requirement: ''
ndonkoHenri commented 4 months ago

Will be fixed along with https://github.com/flet-dev/flet/issues/3596