Skip to content
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

自定义IOAdapter时com.hankcs.hanlp.dictionary.other.CharType 存在BUG #1480

Closed
wanzhidan opened this issue May 27, 2020 · 2 comments
Closed

Comments

@wanzhidan
Copy link

Describe the bug
A clear and concise description of what the bug is.
在使用hanlp 作为 阿里的elasicsearch云分词插件时,阿里云限制了插件写文件权限,只能远程访问hanlp字典文件,因此自定义 IOAdapter,但CharType 类保存 data/dictionary/other/CharType.bin 文件时,未使用IOUtil类,直接使用了FileOutputStream 类保存,导致无法写入文件异常
Code to reproduce the issue
CharType.java

 DataOutputStream out = new DataOutputStream(new FileOutputStream(HanLP.Config.CharTypePath));
@hankcs
Copy link
Owner

hankcs commented May 27, 2020

【自动回复】你好,感谢反馈。
由于未按要求填写,本issue被自动关闭。请按issue模板认真修改,然后耐心等待下周末处理。
如果您提的是bug或feature request,那么请您按模板认真改一改,reopen这个issue。否则,咨询类的问题应该好好改一改,写清楚前因后果发在论坛而不是GitHub上。
如果您不修改的话,恐怕没有人能够回复您,我们也会错失一次改进的机会或者一次友好的讨论。开源项目维护不易,只能在周末受理友好的提问,造成不便还望海涵。

@hankcs
Copy link
Owner

hankcs commented May 27, 2020

感谢反馈,已经修复,请参考上面的commit。
如果还有问题,欢迎重开issue。

hankcs added a commit that referenced this issue May 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants