Skip to content

Commit d0b958b

Browse files
authored
Merge pull request #9 from WorksApplications/fix/pip_install_error
Fix import error before installing dependent packages
2 parents 924dfc9 + 6367dcd commit d0b958b

File tree

3 files changed

+10
-6
lines changed

3 files changed

+10
-6
lines changed

chikkarpy/chikkar.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,11 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
from .dictionarylib import Dictionary
15+
from typing import TYPE_CHECKING
16+
17+
18+
if TYPE_CHECKING:
19+
from .dictionarylib import Dictionary
1620

1721

1822
class Chikkar(object):

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
dartsclone~=0.9.0
2-
sortedcontainers~=2.1.0
2+
sortedcontainers>=2.1.0

setup.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,6 @@
1616

1717
from setuptools import find_packages, setup
1818

19-
20-
download_dictionary()
21-
2219
setup(
2320
name="chikkarpy",
2421
use_scm_version=True,
@@ -37,6 +34,9 @@
3734
},
3835
install_requires=[
3936
"dartsclone~=0.9.0",
40-
"sortedcontainers~=2.1.0"
37+
"sortedcontainers>=2.1.0"
4138
]
4239
)
40+
41+
# Downloads the Sudachi Synonym dictionary
42+
download_dictionary()

0 commit comments

Comments
 (0)