How do I prevent GPS location being enabled automatically on Android 8.0.0 The GPS is sporadically enabled on my phone without my consent or even a notification. I have to keep an eye on it and turn it off when I notice it's on. Is there a "global" setting I can use to prevent this or at least ensure I get a notification when it's about to be enabled?
automation as suggested in comment  seems to come close to what OP wants.

Many automation apps are available. I prefer using MacroDroid , since it is free (upto 5 macros) and easy to learn. To understand how MacroDroid works and required settings,  my answer here



Your macro would look like this


Macro : GPS on Alert (name of macro )


Trigger: GPS enabled/disabled &rarr;*GPS enabled * 

Actions: 


Display Notification &rarr; Enter the desired text. I suggest you choose hour, minute and second to pinpoint the exact time
Speak text - enter the desired text


Constraints: None ( Macro runs always )

This will not tell you when it is about to be enabled but tells you after it is enabled. 

Once you have the time stamp, use an app or other methods suggested in logging &amp; logcat to try and pinpoint the app causing it (read their tag wiki's by clicking on learn more). Disable or uninstall such app(s)