-
-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add sudachipy like import path #96
Add sudachipy like import path #96
Conversation
python/tests/test_dictionary.py
Outdated
@@ -15,7 +15,8 @@ | |||
import os | |||
import unittest | |||
|
|||
from sudachi import Dictionary, Tokenizer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that original imports were better, we are promoting new ways of import as the correct usage, am I correct?
But we still need to have a test that old ways of import do not break (a new one, which only does imports inside test methods).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that original imports were better, we are promoting new ways of import as the correct usage, am I correct?
Currently we don't have concrete plan about this.
I personally think we can put everything in the root module since the amount is not so large.
In the future we will change the API along with the rust API and may want a different module structure.
For that time, I guess we can keep current (old) path as default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I personally think we can put everything in the root module since the amount is not so large.
Completely agree with that, and it is also easier to use it that way.
I would think that we should move to having the public API under the main package (sudachi
) by default and keep the old modules only for compatibility (without deprecating them though).
#84.
We can still use direct import path like
from sudachi import Dictionary