gazpachoking / deluge-seedtime

Deluge plugin to stop torrents after seeding for a certain amount of time.
22 stars 12 forks source link

Allow fractions of a day in configuration #1

Open rpglover64 opened 11 years ago

rpglover64 commented 11 years ago

The UI seems to suggest a floating point value for seed time, but if something that's not a whole number is entered, it is rounded.

gazpachoking commented 11 years ago

Hmm, yeah I round it to 2 decimal places to fit in the gtkui box, it will however allow you to set a more precise number. I just realized that rounding when displaying will also override your original number when you apply the preferences again. You need a time with greater than 15 minute precision (0.01 days)?

rpglover64 commented 11 years ago

When I tried to input a time of e.g. 0.1 days, it rounded down to 0.00 days.

It works fine in the per-torrent settings, just not in the default time box.

gazpachoking commented 11 years ago

Okay, I'm seeing that too. I'll try to have a peek at what's going wrong.

gazpachoking commented 11 years ago

I'm thinking this is because deluge configs don't allow type changes and I put the default as 7 and not 7.0. Try editing the seedtime config manually (while the daemon is shut down) and see if everything works after that. I'll update the default to be 7.0, but I'm not sure how to fix this for people who already have an integer in the config without having them manually edit it.

rpglover64 commented 11 years ago

That seems to have done it.

Thanks.

MacroPolo commented 7 years ago

For anyone looking to use fractions of days on Windows, you can edit the seedtime.conf file in %APPDATA%\deluge.