Skip to content

fix(utils): improve ANSI handling and logging debug information#720

Closed
Kaibalya-Mohanty wants to merge 7 commits into
kubeflow:mainfrom
Kaibalya-Mohanty:fix-ansi-handling
Closed

fix(utils): improve ANSI handling and logging debug information#720
Kaibalya-Mohanty wants to merge 7 commits into
kubeflow:mainfrom
Kaibalya-Mohanty:fix-ansi-handling

Conversation

@Kaibalya-Mohanty

@Kaibalya-Mohanty Kaibalya-Mohanty commented Mar 20, 2026

Copy link
Copy Markdown

Summary

This PR improves utility functions in kale/utils.py.

Changes

  • Improved ANSI escape sequence handling using a more robust regex
  • Added type checking for safer input handling
  • Enhanced logging with debug statements for better traceability

Motivation

This change improves log readability and debugging experience.

Impact

  • No breaking changes
  • Improves internal utility functions

Signed-off-by: KAIBALYA MOHANTY <168870673+Kaibalya-Mohanty@users.noreply.github.com>
Signed-off-by: KAIBALYA MOHANTY <168870673+Kaibalya-Mohanty@users.noreply.github.com>
Signed-off-by: KAIBALYA MOHANTY <168870673+Kaibalya-Mohanty@users.noreply.github.com>
Signed-off-by: KAIBALYA MOHANTY <168870673+Kaibalya-Mohanty@users.noreply.github.com>
Signed-off-by: KAIBALYA MOHANTY <168870673+Kaibalya-Mohanty@users.noreply.github.com>
- Improved ANSI escape sequence handling with robust regex
- Added type safety for non-string inputs
- Enhanced logging with debug statements for better traceability

Signed-off-by: KAIBALYA MOHANTY <168870673+Kaibalya-Mohanty@users.noreply.github.com>
@google-oss-prow

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign stefanofioravanzo for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@Kaibalya-Mohanty Kaibalya-Mohanty changed the title - Improved ANSI escape sequence handling with robust regex - Added type safety for non-string inputs - Enhanced logging with debug statements for better traceability fix(utils): improve ANSI handling and logging debug information Mar 20, 2026
@ada333

ada333 commented Mar 23, 2026

Copy link
Copy Markdown
Collaborator

hi @Kaibalya-Mohanty I believe this PR should not have the DocString changes from #714

@Kaibalya-Mohanty

Copy link
Copy Markdown
Author

@ada333 Thanks for pointing this out!
I'll remove the docstring changes from this PR and keep it focused on the ANSI handling and logging improvements.

Updated docstrings to be more concise while retaining essential information.

Signed-off-by: KAIBALYA MOHANTY <168870673+Kaibalya-Mohanty@users.noreply.github.com>
@ederign

ederign commented Jun 27, 2026

Copy link
Copy Markdown
Member

@Kaibalya-Mohanty as both are doc improvements, can you please combine both changes on #704 ?

@ederign ederign closed this Jun 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants