Night Light not working on Fedora 37

I upgraded yesterday from Fedora 36 to Fedora 37. I had no problems except that the Night Light does not work any more. Toggling it or changing its intensity doesn’t change anything. On Fedora 36 it was working normally.

I’m using an HP Pavillion BC401NV with an NVIDIA GTX 1050 graphics card. I’m on a GNOME Xorg session with the 520.56.06 NVIDIA driver:

$ nvidia-smi 
Thu Nov 17 23:43:59 2022       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 520.56.06    Driver Version: 520.56.06    CUDA Version: 11.8     |

Here are the contents of my /etc/defaults/grub file:

GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX="resume=UUID=23b410be-1e65-4660-8475-820cefe0abac rd.driver.blacklist=nouveau modprobe.blacklist=nouveau nvidia-drm.modeset=1"
GRUB_DISABLE_RECOVERY="true"
GRUB_ENABLE_BLSCFG=true
#GRUB_GFXMODE=1920x1080x32
#GRUB_GFXPAYLOAD_LINUX=keep

Does anyone else have this issue? How can I get Night Light working again?

1 Like

Could you please create a new user and see if it works there? That’ll be the first test.

It’s working on all three of my machines, one of which is Nvidia too. So it looks like it’s OK on my installations, but we can debug it further so we know if there’s a special set of components that breaks it.

1 Like

I created a new user and indeed Night Light works there. So there must be a user config that doesn’t let it work.

I have already reset dconf settings to their defaults, but it didn’t make a difference. Where should I look next?

1 Like

I’m not sure, may try disabling it and enabling it again in settings, and perhaps tinkering with the more detailed settings there—like the sunrise to sunset and the “warmth” slider etc.?

Have you turned on the automatic location service(Gnome-settings) otherwise it could be that night-light does not work soemtimes?

I had already tried that. No change unfortunately.

Yes I have. I have also used Manual Schedule. Still the same. It doesn’t work.

I guess its time to see if the journal has any errors. I seem to have a few messages but they don’t seem to be causing any issues:

$ journalctl -b | grep -i night
Nov 14 21:47:30 thor gnome-shell[7023]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 14 21:47:32 thor gnome-shell[7023]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 14 21:47:33 thor gnome-shell[7873]:   inflating: /home/asinha/.local/share/gnome-shell/extension-updates/openweather-extension@jenslody.de/media/status/weather-clear-night-symbolic.svg
Nov 14 21:47:33 thor gnome-shell[7873]:   inflating: /home/asinha/.local/share/gnome-shell/extension-updates/openweather-extension@jenslody.de/media/status/weather-few-clouds-night-symbolic.svg
Nov 14 21:47:57 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 14 21:47:58 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 15 08:16:01 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 15 08:16:01 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 16 08:23:12 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 16 08:23:12 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 18 07:55:28 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type
Nov 18 07:55:29 thor gnome-shell[9334]: g_settings_get_enum() called on key 'control-nightlight' which is not associated with an enumerated type

We know that it works in a new user, so it’s something related to the existing user conf. Can you check your extensions too? Maybe disable them all (to try to get to as vanilla a setup as we can get) and see if that works? Similarly, any theme changes/tweaks could also interfere, so worth temporarily disabling them too.

journalctl -b | grep -i night shows nothing. I have tried disabling all extensions and rebooting, but still nothing. I don’t use any themes.

I have also went to ~/.cache, ~/.config and ~/.local and removed a bunch of unneeded files and directories in hope of finding the conflicting config, but had no luck. I also didn’t find something that could seemingly affect Night Light there.

Also, it may worth mentioning that when I turn Night Light on, the icon shows up in the system menu as expected.

I finally managed to solve this! It seems that after the upgrade, the color profiles for both my laptop and external monitor were disabled and were shown as Not calibrated in Settings → Color (see screenshot below, where I have already added a color profile for the external monitor but not for the laptop screen):

To add a profile, select the screen and click Add Profile. Then select a color profile from the Add Profile window that opens and click Add:

image

Night Light works properly after that. Thanks @ankursinha and @heliosstyx for your suggestions and willingness to help!

3 Likes

I didn’t know that the colour profile settings are required for night light etc. Good to know!