luxel/ramile

All strings must be XML compatible: Unicode or ASCII, no NULL bytes or control characters

Opened this issue · 2 comments

All strings must be XML compatible: Unicode or ASCII, no NULL bytes or control characters
请问这个报错怎么处理呢?

I'm going to extract 300000000.0 lines from E:\workspace\xiaoxi\moye\XDataCenter_Server\AdIncome\client. 
Traceback (most recent call last): 
  File "C:\Users\Administrator\Desktop\ramile-master\ramile-cli.py", line 30, in <module> 
    main()
  File "C:\Users\Administrator\Desktop\ramile-master\ramile-cli.py", line 26, in main
  File "C:\Python39\lib\site-packages\fire\core.py", line 141, in Fire
    component_trace = _Fire(component, args, parsed_flag_args, context, name)
  File "C:\Python39\lib\site-packages\fire\core.py", line 466, in _Fire
    component, remaining_args = _CallAndUpdateTrace(
  File "C:\Python39\lib\site-packages\fire\core.py", line 681, in _CallAndUpdateTrace
    component = fn(*varargs, **kwargs)
  File "C:\Users\Administrator\Desktop\ramile-master\ramile-cli.py", line 12, in extract
    project.run()
  File "C:\Users\Administrator\Desktop\ramile-master\ramile\project.py", line 37, in run
    self.export(output)
  File "C:\Users\Administrator\Desktop\ramile-master\ramile\project.py", line 77, in export
    self.paragraph.add_run(line)
  File "C:\Python39\lib\site-packages\docx\text\paragraph.py", line 37, in add_run
    run.text = text
  File "C:\Python39\lib\site-packages\docx\text\run.py", line 163, in text
    self._r.text = text
  File "C:\Python39\lib\site-packages\docx\oxml\text\run.py", line 104, in text
    _RunContentAppender.append_to_run_from_text(self, text)
  File "C:\Python39\lib\site-packages\docx\oxml\text\run.py", line 134, in append_to_run_from_text
    appender.add_text(text)
  File "C:\Python39\lib\site-packages\docx\oxml\text\run.py", line 142, in add_text
    self.add_char(char)
  File "C:\Python39\lib\site-packages\docx\oxml\text\run.py", line 157, in add_char
    self.flush()
  File "C:\Python39\lib\site-packages\docx\oxml\text\run.py", line 165, in flush
    self._r.add_t(text)
  File "C:\Python39\lib\site-packages\docx\oxml\text\run.py", line 41, in add_t
    t = self._add_t(text=text)
  File "C:\Python39\lib\site-packages\docx\oxml\xmlchemy.py", line 273, in _add_child
    setattr(child, key, value)
  File "src\lxml\etree.pyx", line 1041, in lxml.etree._Element.text.__set__
  File "src\lxml\apihelpers.pxi", line 748, in lxml.etree._setNodeText
  File "src\lxml\apihelpers.pxi", line 736, in lxml.etree._createTextNode
  File "src\lxml\apihelpers.pxi", line 1541, in lxml.etree._utf8
ValueError: All strings must be XML compatible: Unicode or ASCII, no NULL bytes or control characters

@fly7632785 你是不是前端项目

感觉有可能是JS 类似的文件被压缩一行的情况