aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/Pygments/py3/pygments/plugin.py
diff options
context:
space:
mode:
authororivej <orivej@yandex-team.ru>2022-02-10 16:44:49 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:44:49 +0300
commit718c552901d703c502ccbefdfc3c9028d608b947 (patch)
tree46534a98bbefcd7b1f3faa5b52c138ab27db75b7 /contrib/python/Pygments/py3/pygments/plugin.py
parente9656aae26e0358d5378e5b63dcac5c8dbe0e4d0 (diff)
downloadydb-718c552901d703c502ccbefdfc3c9028d608b947.tar.gz
Restoring authorship annotation for <orivej@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'contrib/python/Pygments/py3/pygments/plugin.py')
-rw-r--r--contrib/python/Pygments/py3/pygments/plugin.py24
1 files changed, 12 insertions, 12 deletions
diff --git a/contrib/python/Pygments/py3/pygments/plugin.py b/contrib/python/Pygments/py3/pygments/plugin.py
index b1085b7ae4e..dc649c59def 100644
--- a/contrib/python/Pygments/py3/pygments/plugin.py
+++ b/contrib/python/Pygments/py3/pygments/plugin.py
@@ -40,30 +40,30 @@ STYLE_ENTRY_POINT = 'pygments.styles'
FILTER_ENTRY_POINT = 'pygments.filters'
-def iter_entry_points(group_name):
- try:
- import pkg_resources
+def iter_entry_points(group_name):
+ try:
+ import pkg_resources
except (ImportError, OSError):
- return []
-
- return pkg_resources.iter_entry_points(group_name)
-
-
+ return []
+
+ return pkg_resources.iter_entry_points(group_name)
+
+
def find_plugin_lexers():
- for entrypoint in iter_entry_points(LEXER_ENTRY_POINT):
+ for entrypoint in iter_entry_points(LEXER_ENTRY_POINT):
yield entrypoint.load()
def find_plugin_formatters():
- for entrypoint in iter_entry_points(FORMATTER_ENTRY_POINT):
+ for entrypoint in iter_entry_points(FORMATTER_ENTRY_POINT):
yield entrypoint.name, entrypoint.load()
def find_plugin_styles():
- for entrypoint in iter_entry_points(STYLE_ENTRY_POINT):
+ for entrypoint in iter_entry_points(STYLE_ENTRY_POINT):
yield entrypoint.name, entrypoint.load()
def find_plugin_filters():
- for entrypoint in iter_entry_points(FILTER_ENTRY_POINT):
+ for entrypoint in iter_entry_points(FILTER_ENTRY_POINT):
yield entrypoint.name, entrypoint.load()