1*9c5db199SXin Li# Copyright (c) 2017 The Chromium Authors. All rights reserved. 2*9c5db199SXin Li# Use of this source code is governed by a BSD-style license that can be 3*9c5db199SXin Li# found in the LICENSE file. 4*9c5db199SXin Li 5*9c5db199SXin Li""" 6*9c5db199SXin LiConvenience functions that determine things about runtime environment. 7*9c5db199SXin Li 8*9c5db199SXin LiAvoid adding any unneeded dependencies to this module, since we may want to 9*9c5db199SXin Liimport it in a variety of unusual environments. 10*9c5db199SXin Li""" 11*9c5db199SXin Li 12*9c5db199SXin LiIN_MOD_WSGI = False 13*9c5db199SXin Litry: 14*9c5db199SXin Li # Per mod_wsgi documentation, this import will only suceed if we are running 15*9c5db199SXin Li # inside a mod_wsgi process. 16*9c5db199SXin Li # pylint: disable=unused-import 17*9c5db199SXin Li from mod_wsgi import version 18*9c5db199SXin Li IN_MOD_WSGI = True 19*9c5db199SXin Liexcept: 20*9c5db199SXin Li pass 21