Skip to content

Commit

Permalink
importlib_resources for Python<3.9
Browse files Browse the repository at this point in the history
  • Loading branch information
reynoldsnlp committed Nov 20, 2023
1 parent 3a1bc51 commit 7785d04
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
10 changes: 7 additions & 3 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,11 @@ classifiers =
Operating System :: POSIX :: Linux
Programming Language :: Python :: 3
Programming Language :: Python :: 3 :: Only
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: 3.11
Programming Language :: Python :: 3.12
Topic :: Education
Topic :: Education :: Computer Aided Instruction (CAI)
Topic :: Scientific/Engineering :: Artificial Intelligence
Expand All @@ -39,13 +42,14 @@ install_requires =
bs4
fastapi
# hfst # python3.8 + install using `apt-get install python3-hfst`
importlib_resources
nltk
pandas
pexpect
sphinx_autodoc_typehints
stanza>=1.1.1
uvicorn
python_requires = >2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*
python_requires = >2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, !=3.6.*, !=3.7.*
include_package_data = True
package_dir =
=src
Expand Down
5 changes: 4 additions & 1 deletion src/udar/misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

from collections import namedtuple
from enum import Enum
from importlib.resources import files
try:
from importlib.resources import files
except ImportError:
from importlib_resources import files # < Python 3.9
import os
from pathlib import Path
import re
Expand Down

0 comments on commit 7785d04

Please sign in to comment.