AVATEAM-IT-SYSTEMHAUS / mkdocs-kroki-plugin

MkDocs plugin for Kroki-Diagrams
MIT License
41 stars 27 forks source link

Question about usage of @from_file: option #24

Closed AlbertoCortina closed 1 year ago

AlbertoCortina commented 1 year ago

Hello,

I am trying to use this plugin (no configuration applied on the mkdocs.yml) to render some excalidraw diagrams so I would like to use this feature to avoid copy-pasting the diagram however I am not able to make it work... I tried with a BPMN and it doesn't work either.

 ```kroki-excalidraw
 @from_file:assets/test.excalidraw
```

The path specified it's relative to the MarkDown file but also tried to put the whole path from the docs folder.

I see the following: image

Here are the logs of the application in case it helps,

INFO - kroki.plugin Configuring: {'ServerURL': 'https://kroki.io', 'EnableBlockDiag': True, 'Enablebpmn': True, 'EnableExcalidraw': True, 'EnableMermaid': True, 'EnableDiagramsnet': False, 'HttpMethod': 'GET', 'DownloadImages': False, 'EmbedImages': False, 'DownloadDir': 'images/kroki_generated', 'FencePrefix': 'kroki-', 'FileTypes': ['svg'], 'FileTypeOverrides': {}}
INFO - kroki.config File and Diagram types configured: {'bytefield': 'svg', 'ditaa': 'svg', 'erd': 'svg', 'graphviz': 'svg', 'nomnoml': 'svg', 'plantuml': 'svg', 'structurizr': 'svg', 'c4plantuml': 'svg', 'svgbob': 'svg', 'vega': 'svg', 'vegalite': 'svg', 'wavedrom': 'svg', 'pikchr': 'svg', 'umlet': 'svg', 'blockdiag': 'svg', 'seqdiag': 'svg', 'actdiag': 'svg', 'nwdiag': 'svg', 'packetdiag': 'svg', 'rackdiag': 'svg', 'bpmn': 'svg', 'excalidraw': 'svg', 'mermaid': 'svg'}
INFO - kroki.client Initialized: GET, https://kroki.io
INFO - kroki.plugin Cleaning <TemporaryDirectory '/tmp/mkdocs_kroki_t9mm0qt0'>

Am I using it wrong?

Thanks!

m-roberts commented 1 year ago

I had this problem - the issue was that this functionality is not yet available on PyPI. I had to install from pre-release to get this to work.

AlbertoCortina commented 1 year ago

Thanks @m-roberts! I tried using the pre-release and it worked. I was expecting all the features explained in the README file will be released.