Closed oliverunger closed 10 months ago
Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.
@oliverunger thanks for the report, can you confirm, did you try to generate PDF without GitHub action? did it work?
Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.
might be that we need to improve https://github.com/asyncapi/github-action-for-generator/blob/master/Dockerfile and follow what we did in https://github.com/asyncapi/generator/blob/master/Dockerfile (so have puppeteer dedicated config).
@oliverunger can you open a PR?
Hello @derberg
Thank you for your quick response!
Using
asyncapi generate fromTemplate my_asyncapi.yml @asyncapi/html-template@0.28.0 -p pdf=true singleFile=true
worked well and generated a .pdf and a .html for me with the following logs:
PDF is generating...
PDF generated!
Generation in progress. Keep calm and wait a bit... done
Check out your shiny new generated files at C:\git-repos\myproject.
This worked for me in my github workflow but its suboptimal:
- name: Install Asyncapi generator
run: npm install -g @asyncapi/generator
- name: Generating PDF from my AsyncAPI document
run: ag my_asyncapi.yml @asyncapi/html-template@0.28.0 -p pdf=true singleFile=true -o wiki/diagrams
Very bad: The generated pdf is full expanded. Good: Links are clickable
The fact that PDF is fully expanded was done intentionally. I'm not a PDF expert and assumption was it must be expanded, otherwise generated PDF will be "broken" as we were not sure expand/collapse will work + cntrl + f
will not work
looks like fixed.
if there is a strong and clear vision how to improve PDF, please open an issue in https://github.com/asyncapi/html-template
Describe the bug
Generator fails to create asyncapi pdf
How to Reproduce
Using the following step:
Github Actions Log: PDF is generating... Error: Failed to launch the browser process! spawn /node_modules/@asyncapi/generator/node_modules/puppeteer/.local-chromium/linux-1002410/chrome-linux/chrome ENOENT
TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md
Expected behavior
Should create a beautiful pdf of my asyncapi.