please set a system env PAODING_DIC_HOME or Config paoding.dic.home in paoding-dic-home.properties p

Posted wgwyanfs

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了please set a system env PAODING_DIC_HOME or Config paoding.dic.home in paoding-dic-home.properties p相关的知识,希望对你有一定的参考价值。

在使用paoding分词的时候。出现了错误,please set a system env PAODING_DIC_HOME or Config paoding.dic.home in paoding-dic-home.properties point to the dictionaries!

这是由于在老版本号的PaodingMaker.getFile()方法中採用的是老版本号的java.net.URL.getFile(),不可以识别中文或者空格。须要改动源码又一次打包。仅仅有採用URL.toRUL().getPath()才干识别汉字与空格。


这部分是自己加的代码
//这部分代码是自己加入的,主要是解决路径中不能有空格的问题
  File dicHomeFile2 = getFile(dicHome);
  String path = "";
  try{
   path = URLDecoder.decode(dicHomeFile2.getPath(),"UTF-8");
  }catch(UnsupportedEncodingException e){
   e.printStackTrace();
  }
  File dicHomeFile = new File(path);


以上是关于please set a system env PAODING_DIC_HOME or Config paoding.dic.home in paoding-dic-home.properties p的主要内容,如果未能解决你的问题,请参考以下文章

python manage.py makemigrat Please select a fix: 1) Provide a one-off default now (will be set on

eggjs 项目报错 Cookie need secret key to sign and encrypt. Please set config.keys first

Plugin is too old, please update to a more recent version, or set ANDROID_DAILY_OVERRIDE environment

Environment variable ORACLE_UNQNAME not defined.Please set ORACLE_UNQNAME to database unique name.(示

Internal error. Please report to https://code.google.com/p/an

python安装失败提示“one or more issues caused the setup to fail . Please fix the issues and then retry set