Make manual control compatible with redshift >= 1.12
ClosedPublic

Authored by vermeeren on Aug 21 2019, 8:32 PM.

Details

Summary

BUG: 395641

Redshift version >= 1.12 requires the -P option to clear the existing gamma ramps for one-shot mode. Without it the screen gets darker and darker until it is impossible to see anything.

Quoting from the redshift 1.12 manual page:

-O TEMP One-shot manual mode (set color temperature). Use this with the -P option to clear the existing gamma ramps before applying the new color temperature.
-P Reset existing gamma ramps before applying new color effect.

Diff Detail

Repository
R885 Redshift Control for Plasma
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
vermeeren created this revision.Aug 21 2019, 8:32 PM
Restricted Application added a project: Plasma. · View Herald TranscriptAug 21 2019, 8:32 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
vermeeren requested review of this revision.Aug 21 2019, 8:32 PM

I am not sure how the version scheme will work now that this plasmoid is officially part of KDE, but once this is merged the version should definitely be bumped as this is a critical issue preventing use of manual mode. See also: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=910901

Is redshift -P -O fully backwards-compatible with older versions of redshift? If not, then this will just break everyone not using >=1.12.

vermeeren updated this revision to Diff 64263.Aug 21 2019, 11:12 PM

Only add -P option for redshift >= 1.12, avoids breaking redshift < 1.12.

Is redshift -P -O fully backwards-compatible with older versions of redshift? If not, then this will just break everyone not using >=1.12.

I checked and this is not the case, previous versions will error because of the unknown option. Updated the patch so it adds -P only for >= 1.12.

vermeeren set the repository for this revision to R885 Redshift Control for Plasma.Sep 2 2019, 12:57 PM

Is there any news regarding this? The updated diff has been tested (both version paths) and works properly. It should be ready for merge as is, and will close a bug over a year old. Urgency is rather high in my opinion, as both Debian >= buster and Ubuntu >= cosmic are shipping redshift 1.12 meaning this bug is now reaching end users in stable production systems.

Also, does this change superceded both D14068, D14245 and D23401 ?

Also, does this change superceded both D14068, D14245 and D23401 ?

Yes, unlike those this one doesn't break old redshift < 1.12.

mart accepted this revision.Oct 16 2019, 11:57 AM
mart added a subscriber: mart.

lgtm

This revision is now accepted and ready to land.Oct 16 2019, 11:57 AM
This revision was automatically updated to reflect the committed changes.