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

log = None cannot complete suppress stdout in GOEnrichmentStudyNS #238

Closed
illumination-k opened this issue Apr 3, 2022 · 2 comments
Closed

Comments

@illumination-k
Copy link

illumination-k commented Apr 3, 2022

Thanks for the great project!

I want to stop logging completely, but __init__ function in GOEnrichmentStudy has print regardless of log kwd, so I cannot.

print('\nLoad {OBJNAME} Gene Ontology Analysis ...'.format(OBJNAME=self.name))

I think if log is None, nothing should be output to stdout.
This is not a so big problem, but not useful when redirecting or something.

tanghaibao added a commit that referenced this issue Apr 3, 2022
#238) (#239)

* Check `log` before print() in go_enrichment.py (thanks @illumination-k, #238)

* One commented-out import
@tanghaibao
Copy link
Owner

@illumination-k

Thank you for the issue report. I added the fix that considered the log keyword.

@tanghaibao
Copy link
Owner

@dvklopfenstein

Longer-term, we could move to using logging instead of using prt and log parameter throughout the code, as suggested in #159.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants