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

Extraneous linebreaks in show methods #69

Closed
jakobnissen opened this issue Jan 5, 2022 · 3 comments
Closed

Extraneous linebreaks in show methods #69

jakobnissen opened this issue Jan 5, 2022 · 3 comments

Comments

@jakobnissen
Copy link

This is quite minor, but it looks like most objects in this package prints an extra newline in their show methods, i.e. the methods use println. Best practise is to use print, since the Julia REPL automatically inserts a newline after each object.

For example, a vector of nodes is printed like:

julia> collect(nodeiter(tree))[1:2]
2-element Vector{LinkNode{OneRoot, String, Dict{String, Any}, LinkBranch{OneRoot, String, Dict{String, Any}, Float64}}}:
 LinkNode A, a tip of the tree with an incoming connection (branch 4).

 LinkNode B, a tip of the tree with an incoming connection (branch 3).


julia>
@richardreeve
Copy link
Member

Thanks @jakobnissen - this seems like an easy fix. I remember there being a problem a few years ago that vectors of phylogenetic elements were just appearing as an infinitely long line of unreadable text, but I guess that got changed?

@jakobnissen
Copy link
Author

Looks like it, yes.

@richardreeve
Copy link
Member

Finally fixed!

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