question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error when trying to add Chinese text

See original GitHub issue

Basically it is the same issue as in https://github.com/3b1b/manim/issues/570, however it was not clear how the person solved the issue, for he stated that he didn’t know how he managed to solve it. I am using Windows 10 and MiKTeX. I tried to edit constants.py, TEX_USE_CTEX = False was changed to True and it returns the error:

 File "D:\Programs\manim\manim\manimlib\extract_scene.py", line 153, in main
    scene = SceneClass(**scene_kwargs)
  File "D:\Programs\manim\manim\manimlib\scene\scene.py", line 54, in __init__
    self.construct()
  File "tutorial/1_text_format.py", line 5, in construct
    text = TextMobject("你好")
  File "D:\Programs\manim\manim\manimlib\mobject\svg\tex_mobject.py", line 144, in __init__
    self, self.arg_separator.join(tex_strings), **kwargs
  File "D:\Programs\manim\manim\manimlib\mobject\svg\tex_mobject.py", line 45, in __init__
    self.template_tex_file_body
  File "D:\Programs\manim\manim\manimlib\utils\tex_file_writing.py", line 19, in tex_to_svg_file
    dvi_file = tex_to_dvi(tex_file)
  File "D:\Programs\manim\manim\manimlib\utils\tex_file_writing.py", line 67, in tex_to_dvi
    "See log output above or the log file: %s" % log_file)
Exception: Xelatex error converting to xdv. See log output above or the log file: D:\Programs\manim\manim\manimlib\files\Tex\6d518d13918960fc.log

And the command is extremely simple:

class WriteText(Scene): 
    def construct(self): 
        text = TextMobject("你好")
        self.play(Write(text))
        self.wait(3)

Anyway that has proven to work to solve the issue? For I am not the first one encountering this.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:12

github_iconTop GitHub Comments

3reactions
angelfly2000commented, May 7, 2020

#680 This is very helpful! And my project is working now. thanks a lot 😃

0reactions
TonyCranecommented, Jul 28, 2020

Hey everybody, would you like to try #1187 ? One of my friends had faced the same problem and got the same log file as you. After doing this, he succeed.

There is one thing I have to say: even though Text is good to use, but it doesn’t support formulas and it has some bug now. So use Text entirely instead of Tex(t)Mobject is not a good idea.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Chinese (Simplified) input method doesn't work - Microsoft Learn
When the user tries to type by using the Chinese input method, Windows continues to type and display in English.
Read more >
LO48551: CHINESE CHARACTERS DISPLAY ERROR IN ...
send a message with Chinese characters in title and content 3.recipient log in at ultralite and open this message The bug appear with...
Read more >
Fix: Can't Display Chinese Filenames in Windows 10 - YouTube
Can't display chinese filenames in Windows 10? It's quite easy to fix the problem. Right click on Windows Start button I File Explorer...
Read more >
Invalid token or compile time error for japanese/chinese ...
try to add Chinese in control panel take a look stackoverflow.com/questions/16520473/… – dt170. May 13, 2020 at 7:07. Probably an issue ...
Read more >
V10 RestAPI add account call returns error on Chinese ...
When customer used Chinese characters in Restapi body call body, http 400 error code was returned. Please refer to below screenshot.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found