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

[Bug]: YAML is not correctly formatted for some strings #522

Closed
1 of 4 tasks
jverre opened this issue Oct 31, 2024 · 2 comments · Fixed by #599
Closed
1 of 4 tasks

[Bug]: YAML is not correctly formatted for some strings #522

jverre opened this issue Oct 31, 2024 · 2 comments · Fixed by #599
Labels
bug Something isn't working work in progress

Comments

@jverre
Copy link
Collaborator

jverre commented Oct 31, 2024

Willingness to contribute

No. I can't contribute a fix for this bug at this time.

What component(s) are affected?

  • Python SDK
  • Opik UI
  • Opik Server
  • Documentation

Opik version

  • Opik version: 1.0.3

Describe the problem

Sometimes when I log data, the data is rendered nicely when viewing it using the YAML formatter and new line characters are rendered using new lines. However sometimes the input is displayed as a string and not formatted in an easy to read manner. This seems related to some special characters like \r or \t

Reproduction steps

%pip install opik
import opik

opik.configure()

client=opik.Opik()
client.trace(name="test", input={"input": "\n\rtest\n"})
@jverre jverre added the bug Something isn't working label Oct 31, 2024
@jverre
Copy link
Collaborator Author

jverre commented Oct 31, 2024

This is an issue with the underlying library we are using, we patched it for \t last week: https://github.com/comet-ml/opik/pull/476/files. Seems like there is a similar issue with other characters as well. We will look at adding support for common "special characters": \t, \n, \r, \v, \f and \b

@jverre
Copy link
Collaborator Author

jverre commented Nov 5, 2024

@ferc Can you take a look

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working work in progress
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant