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

Print attributes according to their type #121

Merged
merged 1 commit into from
Aug 3, 2024

Conversation

ymtdzzz
Copy link
Owner

@ymtdzzz ymtdzzz commented Aug 3, 2024

related: #120

traces

image

metrics

image

logs

image

sort.Strings(keys)

for _, k := range keys {
attr := tview.NewTreeNode(fmt.Sprintf("%s: %s", k, attrs[k]))
v, _ := attrs.Get(k)
attr := tview.NewTreeNode(fmt.Sprintf("%s: %s", k, v.AsString()))
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In this case, I think it's enough to just use AsString()

@ymtdzzz ymtdzzz merged commit 2feaf82 into main Aug 3, 2024
4 checks passed
@ymtdzzz ymtdzzz deleted the feature/improve_attribute_tree_in_detail branch August 3, 2024 12:35
@codefromthecrypt
Copy link

thanks for the polish!

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

Successfully merging this pull request may close these issues.

2 participants