Graphviz Plantuml在线和本地呈现差异 使用,考虑下面的图表:

Graphviz Plantuml在线和本地呈现差异 使用,考虑下面的图表:,graphviz,plantuml,Graphviz,Plantuml,由以下代码指定: @startuml title FooBar endtitle cloud Cloud { node "Machine" #beige { node OPT #yellow [ Optimizer ] } } node Torch #yellow OPT ==> Torch : response Torch ==> OPT : request @enduml 但是,当我在本地计算机上渲染完全相同的代

由以下代码指定:

@startuml
title
  FooBar
endtitle
cloud Cloud {
node "Machine" #beige {
  node OPT #yellow [
    Optimizer   
    ]   
  }   
}

node Torch #yellow

OPT    ==> Torch  : response
Torch  ==> OPT    : request
@enduml
但是,当我在本地计算机上渲染完全相同的代码(复制粘贴)时,我会得到一个粗糙、丑陋、不可接受的渲染:

$ cat > hairball.txt   
 <<< paste the above text >>>
$ plantuml hairball.txt 
$ xdg-open hairball.png 
我不知道如何诊断和修复此问题,非常感谢您的帮助。

如何:

  • 安装插件:PlantUML集成

    • 背景→ 插件→ 搜索“PlantUML集成”→ 安装
  • 皮查姆→ 设置→ 其他设置→ PlantUML→ “Graphviz doe可执行文件:
    您的dot.exe路径

  • 测试泵


  • 看起来不错。

    这似乎是一个环境/OS设置问题。不确定
    PyCharm
    是否回答了这个问题……我确认Debian/Buster/Stable上的相同错误呈现:
    shell$dot-V dot-graphviz版本2.40.1(20161225.0304)$java-jar~/.local/bin/plantuml.jar-V(0.000-124 Mo)117 Mo-plantuml版本1.2019.04(0.009-124 Mo)117 Mo-GraphicsEnvironment.ishadless()错误(0.009-124 Mo)117 Mo-强制在OpenJdk上加载资源(0.124-124 Mo)112 Mo-找到0个文件$java-版本OpenJdk 11.0.3 2019-04-16 OpenJdk运行时环境(构建11.0.3+7-post-Debian-5)OpenJdk 64位服务器VM(构建11.0.3+7-post-Debian-5,混合模式,共享)
    $ dot -V
    dot - graphviz version 2.40.1 (20161225.0304)
    $ plantuml -v
    (0.000 - 1008 Mo) 1000 Mo - PlantUML Version 1.2019.05