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

Add support for escaping '---' in incoming messages #5

Open
AleksandarFaraj opened this issue Jul 11, 2023 · 0 comments
Open

Add support for escaping '---' in incoming messages #5

AleksandarFaraj opened this issue Jul 11, 2023 · 0 comments
Labels
good first issue Good for newcomers

Comments

@AleksandarFaraj
Copy link
Contributor

Use Case: Improve handling of incoming messages

Description:

We currently have two functions, DeserializeMessageThread and SerializeMessageThread, which are used for deserializing and serializing message threads. However, these functions do not properly escape the '---' character when new incoming messages are added to the thread.

Currently these files

Expected Behavior:

When new incoming messages are added to the message thread, the '---' character should be properly escaped to prevent any parsing issues with YAML or other serialization formats.

Steps to Reproduce:

  1. Use the DeserializeMessageThread function to parse a string containing a message thread.
  2. Add a new incoming message to the thread that includes the '---' character.
  3. Use the SerializeMessageThread function to serialize the modified message thread back into string.
  4. Attempt to deserialize the serialized string using DeserializeMessageThread.
  5. Observe that the original '---' character is not properly escaped in the deserialized message.

Expected Outcome:

When the '---' character is encountered in an incoming message, it should be escaped to ensure proper handling and serialization of the message thread.

Files to Modify:

  • pkg/tzapfile/tzapfile.go
@AleksandarFaraj AleksandarFaraj added the good first issue Good for newcomers label Jul 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant