Skip to content

Traceback: Expose local rendering options in install#3415

Open
IoannisP-ITENG wants to merge 2 commits intoTextualize:masterfrom
IoannisP-ITENG:feature/expose_local_rendering_options_in_traceback
Open

Traceback: Expose local rendering options in install#3415
IoannisP-ITENG wants to merge 2 commits intoTextualize:masterfrom
IoannisP-ITENG:feature/expose_local_rendering_options_in_traceback

Conversation

@IoannisP-ITENG
Copy link
Copy Markdown

@IoannisP-ITENG IoannisP-ITENG commented Jul 6, 2024

Type of changes

  • Bug fix
  • New feature
  • Documentation / docstrings
  • Tests
  • Other

Checklist

  • I've run the latest black with default args on new code.
  • I've updated CHANGELOG.md and CONTRIBUTORS.md where appropriate.
  • I've added tests for new code.
  • I accept that @willmcgugan may be pedantic in the code review.

Description

Add locals_max_depth and locals_overflow to tracebacks to enable truncating deep objects or wrapping long strings.

    install(
        width=500,
        extra_lines=3,
        theme=None,
        word_wrap=True,
        show_locals=True,
        locals_max_length=10,
        locals_max_string=1000,
        locals_max_depth=3,
        locals_hide_dunder=True,
        locals_hide_sunder=True,
        locals_overflow="fold",
        indent_guides=True,
        suppress=(),
        max_frames=10,
    )

image

Add locals_max_depth and locals_overflow to tracebacks
@IoannisP-ITENG IoannisP-ITENG force-pushed the feature/expose_local_rendering_options_in_traceback branch from 7d52649 to c076b05 Compare July 6, 2024 18:23
@ruben-iteng
Copy link
Copy Markdown

Hey! @willmcgugan @darrenburns do you have any comments on this PR? This would make using the tracebacks even more usable 😊

@willmcgugan
Copy link
Copy Markdown
Member

master has changed since you did this. Would you mind resolving the conflicts? LGTM otherwise.

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.

3 participants