Skip to content

Commit

Permalink
chore: migrate to importlib
Browse files Browse the repository at this point in the history
  • Loading branch information
arbimaq committed Dec 9, 2024
1 parent c456911 commit 988a1ef
Showing 1 changed file with 10 additions and 13 deletions.
23 changes: 10 additions & 13 deletions code_annotations/contrib/config/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,14 @@
"""
import os

import pkg_resources
import importlib_resources

FEATURE_TOGGLE_ANNOTATIONS_CONFIG_PATH = importlib_resources.files(
"code_annotations") / os.path.join("contrib", "config", "feature_toggle_annotations.yaml")

SETTING_ANNOTATIONS_CONFIG_PATH = importlib_resources.files(
"code_annotations") / os.path.join("contrib", "config", "setting_annotations.yaml")

OPENEDX_EVENTS_ANNOTATIONS_CONFIG_PATH = importlib_resources.files(
"code_annotations") / os.path.join("contrib", "config", "openedx_events_annotations.yaml")

FEATURE_TOGGLE_ANNOTATIONS_CONFIG_PATH = pkg_resources.resource_filename(
"code_annotations",
os.path.join("contrib", "config", "feature_toggle_annotations.yaml"),
)
SETTING_ANNOTATIONS_CONFIG_PATH = pkg_resources.resource_filename(
"code_annotations",
os.path.join("contrib", "config", "setting_annotations.yaml"),
)
OPENEDX_EVENTS_ANNOTATIONS_CONFIG_PATH = pkg_resources.resource_filename(
"code_annotations",
os.path.join("contrib", "config", "openedx_events_annotations.yaml"),
)

0 comments on commit 988a1ef

Please sign in to comment.