Skip to content
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] Disable console output #351

Closed
Lorkenpeist opened this issue Jan 27, 2022 · 4 comments · Fixed by #352
Closed

[Feature Request] Disable console output #351

Lorkenpeist opened this issue Jan 27, 2022 · 4 comments · Fixed by #352
Labels
type: enhancement New feature or request

Comments

@Lorkenpeist
Copy link

Is your feature request related to a problem? Please describe.
The console output that htmlextra produces (version, progress bar, created report) is cluttering my CLI.

Describe the solution you'd like
An option to disable said console output.

Describe alternatives you've considered
I was able to suppress the progress bar and the end message by enabling newman's built-in progress bar with option {silent: true}, and suppress the start message by setting console.log = function () {} in my own script. But I had to dig in the htmlextra source code to figure that out, and it's still a hackish solution. (Incidentally, the start message logs even when the htmlextra progress bar is suppressed, but the end message only logs when the htmlextra progress bar is also enabled, which is inconsistent and seems like it might be unintentional.)

Additional context
I am using a custom script to run many collections in parallel, which outputs a 1-line summary to console when each collection finishes. I just tried using htmlextra instead of html and now I am getting 4 lines per collection, 3 of which are from htmlextra.

@Lorkenpeist Lorkenpeist added the type: enhancement New feature or request label Jan 27, 2022
@DannyDainton
Copy link
Owner

Hey @Lorkenpeist 👋🏻

Your use case would cause multiple outputs as your running collections in parallel, Newman would still remain a 1 for 1 running of the collection and each run would be a separate report. I can see why having that polluting the logs wouldn't be a great experience when run in parallel.

Sounds like you've been having a look at it already - Would you like to make that change and submit a PR?

@DannyDainton
Copy link
Owner

I went ahead and removed the option to display the progress bar by default, you would now need to supply the flag to see this in the CLI.

image

@Lorkenpeist
Copy link
Author

Awesome, thanks for the quick turnaround! I'm already loving the improved HTML reports :)

@github-actions
Copy link

github-actions bot commented May 4, 2022

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 4, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: enhancement New feature or request
Projects
None yet
2 participants