-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: rebot - Option to embed images in html #5125
Comments
I can see that this would be convenient in some cases. Implementing it would require parsing logged HTML messages, finding references to images, and replacing them with embedded versions. It wouldn't be too hard with A problem would be that embedding images could easily increase the log file size considerably. It would often make sense to reduce the image size to mitigate that issue, but that would require using an external module like Pillow. Such a module could also be useful otherwise to support various image formats. Because I consider the possibility to change image sizes pretty much a must and because we don't want to have external dependencies, I got a feeling this would be best to be implemented as an external tool that could then be used with |
The increase in file size was the reason I said it should be disabled by default, not desirable by default. My thought is just have a warning/note about the large file size in the help text for the option and embed the images as provided, then no need for Pillow or any extra code to resize images. |
I'm fairly certain users would request that images could be resized and/or quality dropped to make the file size smaller if this kind of functionality would be added. That would then require an external dependency or implementing a more powerful tool externally. The more I think about this, the less I see benefits with the functionality being in the core. It anyway needed to be enabled with something like |
Sounds good to me 👍 |
Not sure if this is the right place for this feature request?
Feature request to add an option to rebot's command line to embed images (e.g. screenshots) into the html body rather then linking to the image file on the filesystem, so the log.html would be a self contained file.
I'd expect this option would be disabled by default, so images would only be embedded if someone specifically asked for it.
This feature request was inspired by this forum post and other like it I've seen in the past:
https://forum.robotframework.org/t/how-to-add-screenshot-in-allure-report-for-failure-test-cases-allure-repot/7263
The text was updated successfully, but these errors were encountered: