Closed ShaiAvr closed 7 months ago
Thanks for opening your first issue here! Engagement like this is essential for open source projects! :hugs:
If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.
If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).
Welcome to the EBP community! :tada:
Done in f17b2ab74356e0c6dd5bb0e99079950f7062769c.
A
Context
I use
sphinx-autobuild
in my project, and I noticed the--delay
parameter which controls how long to wait before opening a browser is of typeint
as can be seen from the code incli.py
and in the command line:This seems odd to me since time can obviously be a
float
.The
--delay
parameter is directly passed as the parameteropen_url_delay
to theServer.serve()
method of thelivereload
package as can be seen here. Looking at the documentation of this package, it seems that this parameter doesn't have a problem withfloat
values. Furthermore, looking at the code ofServer.serve
, this parameter is simply passed totime.sleep
which obviously can handle floating values.Therefore, it is extremely easy to allow support for floating values of the
--delay
parameter. We just need to change the argument's type tofloat
instead ofint
and it should work without further changes.Proposal
Change the type of the
--delay
argument tofloat
to allow specifying floating time. It should be the only change necessary to support floating values for this parameter. I can write a PR to implement this change if there are no problems with it (Note that it would be the first time I make a PR).Tasks and updates
No response