Conf_path is deprecated but what is its replacement? Im upgrading a D7 module to D8 and it turns out conf_path() is deprecated but I cant find the replacement.  

I found a github page that said use this 

 DrupalKernel::findSitePath(Request::createFromGlobals())


but I still WSOD when that is called.
One of two change records for conf_path() is Bootstrap refactored to use the kernel. This states that


  Note: In D8, instead of using conf_path(), \Drupal\Core\DrupalKernel::getSitePath() instead. If the kernel is unavailable (such as above, where the code shows the booting of the D8 kernel) or the site path needs to be recalculated then Drupal\Core\DrupalKernel::findSitePath() can be used


So if you have access to the DrupalKernel object, then calling getSitePath() on that object will work. This is probably not the case. 

However, there is a service for this called site.path that can be injected into a class that you need it. I think the change record could be updated to reference this factory class.

Using the global Drupal object:

$conf_path = \Drupal::service('site.path');