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

[Console] Syntax highlighting breaks for long escaped strings #182771

Closed
sabarasaba opened this issue May 7, 2024 · 2 comments
Closed

[Console] Syntax highlighting breaks for long escaped strings #182771

sabarasaba opened this issue May 7, 2024 · 2 comments
Labels
bug Fixes for quality problems that affect the customer experience Feature:Console Dev Tools Console Feature Team:Kibana Management Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more

Comments

@sabarasaba
Copy link
Member

Console output can end up with broken syntax highlighting if we have a long escaped strtrings being rendered. I imagine this is something that will probable be fixed once we complete the Monaco migration.

// We should expect the email field here to be a string, instead its being parsed as an object
Screenshot 2024-05-07 at 09 19 11

Console snippet
POST _bulk
{ "index": { "_index": "your_index_name" } }
{"email": "[{\"_index\":\"your_index_name\",\"_id\":\"tiPeUY8BJdk-ibbgracT\",\"_score\":1,\"_source\":{\"email\":\"[email protected]\",\"phone\":\"+1234567890\",\"country\":\"USA\",\"age\":30,\"name\":\"John Doe\",\"address\":\"123 Main St\",\"city\":\"New York\",\"postcode\":\"10001\",\"company\":\"ABC Inc.\",\"date\":\"2024-05-07\"}},{\"_index\":\"your_index_name\",\"_id\":\"tyPfUY8BJdk-ibbgNae1\",\"_score\":1,\"_source\":{\"email\":\"[email protected]\",\"phone\":\"+1987654321\",\"country\":\"Canada\",\"age\":25,\"name\":\"Jane Smith\",\"address\":\"456 Maple Ave\",\"city\":\"Toronto\",\"postcode\":\"M5V 2J3\",\"company\":\"XYZ Corp\",\"date\":\"2024-05-07\"}},{\"_index\":\"your_index_name\",\"_id\":\"uCPgUY8BJdk-ibbgNae-\",\"_score\":1,\"_source\":{\"email\":\"Vice President 4\",\"name\":\"pepe\",\"phone\":\"+1987654321\",\"country\":\"Canada\",\"age\":25,\"name\":\"Jane Smith\",\"address\":\"456 Maple Ave\",\"city\":\"Toronto\",\"postcode\":\"M5V 2J3\",\"company\":\"XYZ Corp\",\"date\":\"2024-05-07\"}},{\"_index\":\"your_index_name\",\"_id\":\"uSPjUY8BJdk-ibbgpqdJ\",\"_score\":1,\"_source\":{\"email\":\"Vice President 4\",\"name\":\"pepe\",\"email_Address\":\"test_long_email_to_see_if_it_breaks@long_longlonglonglongdomain.com\",\"pet_name\":\"this is a long long pet name to see if syntax highlighting breaks\",\"phone\":\"+1987654321\",\"country\":\"Canada\",\"age\":25,\"name\":\"Jane Smith\",\"address\":\"456 Maple Ave\",\"city\":\"Toronto\",\"postcode\":\"M5V 2J3\",\"company\":\"XYZ Corp\",\"date\":\"2024-05-07\"}},{\"_index\":\"your_index_name\",\"_id\":\"uiPkUY8BJdk-ibbgCqep\",\"_score\":1,\"_ignored\":[\"email.keyword\"],\"_source\":{\"email\":\"Vice President 4\",\"name\":\"pepe\",\"email_Address\":\"test_long_email_to_see_if_it_breaks@long_longlonglonglongdomain.com\",\"pet_name\":\"this is a long long pet name to see if syntax highlighting breaks\",\"phone\":\"+1987654321\",\"country\":\"Canada\",\"age\":25,\"name\":\"Jane Smith\",\"address\":\"456 Maple Ave\",\"city\":\"Toronto\",\"postcode\":\"M5V 2J3\",\"company\":\"XYZ Corp\",\"date\":\"2024-05-07\"}},{\"_index\":\"your_index_name\",\"_id\":\"uyPkUY8BJdk-ibbgPacB\",\"_score\":1,\"_ignored\":[\"email.keyword\"],\"_source\":{\"email\":\"Vice President 4\",\"name\":\"pepe\",\"email_Address\":\"test_long_email_to_see_if_it_breaks@long_longlonglonglongdomain.com\",\"pet_name\":\"this is a long long pet name to see if syntax highlighting breaks\",\"phone\":\"+1987654321\",\"country\":\"Canada\",\"age\":25,\"name\":\"Jane Smith\",\"address\":\"456 Maple Ave\",\"city\":\"Toronto\",\"postcode\":\"M5V 2J3\",\"company\":\"XYZ Corp\",\"date\":\"2024-05-07\"}},{\"_index\":\"your_index_name\",\"_id\":\"vCPmUY8BJdk-ibbg1qeB\",\"_score\":1,\"_ignored\":[\"email.keyword\"],\"_source\":{\"email\":\"Vice President 4\",\"name\":\"pepe\",\"email_Address\":\"test_long_email_to_see_if_it_breaks@long_longlonglonglongdomain.com\",\"pet_name\":\"this is a long long pet name to see if syntax highlighting breaks\",\"phone\":\"+1987654321\",\"country\":\"Canada\",\"age\":25,\"name\":\"Jane Smith\",\"address\":\"456 Maple Ave\",\"city\":\"Toronto\",\"postcode\":\"M5V 2J3\",\"company\":\"XYZ Corp\",\"date\":\"2024-05-07\"}}]","phone":"+1987654321","country":"Canada","age":25,"name":"Jane Smith","address":"456 Maple Ave","city":"Toronto","postcode":"M5V 2J3","company":"XYZ Corp","date":"2024-05-07"}

GET your_index_name/_search
@sabarasaba sabarasaba added bug Fixes for quality problems that affect the customer experience Feature:Console Dev Tools Console Feature Team:Kibana Management Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more labels May 7, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-management (Team:Kibana Management)

@yuliacech
Copy link
Contributor

I think this is not reproducible in Monaco
Screenshot 2024-08-13 at 15 23 42

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience Feature:Console Dev Tools Console Feature Team:Kibana Management Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more
Projects
None yet
Development

No branches or pull requests

3 participants