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

PyErrr_Display and traceback.format_exception_only behaviour #39709

Closed
jhermann mannequin opened this issue Dec 15, 2003 · 6 comments
Closed

PyErrr_Display and traceback.format_exception_only behaviour #39709

jhermann mannequin opened this issue Dec 15, 2003 · 6 comments
Assignees
Labels
extension-modules C modules in the Modules dir

Comments

@jhermann
Copy link
Mannequin

jhermann mannequin commented Dec 15, 2003

BPO 860326
Nosy @gvanrossum, @tim-one, @birkenfeld
Files
  • traceback.py.patch
  • tb_problem.py: Bug demonstration
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/gvanrossum'
    closed_at = <Date 2008-01-06.22:29:46.708>
    created_at = <Date 2003-12-15.13:37:04.000>
    labels = ['extension-modules']
    title = 'PyErrr_Display and traceback.format_exception_only behaviour'
    updated_at = <Date 2008-01-06.22:29:46.708>
    user = 'https://bugs.python.org/jhermann'

    bugs.python.org fields:

    activity = <Date 2008-01-06.22:29:46.708>
    actor = 'admin'
    assignee = 'gvanrossum'
    closed = True
    closed_date = None
    closer = None
    components = ['Extension Modules']
    creation = <Date 2003-12-15.13:37:04.000>
    creator = 'jhermann'
    dependencies = []
    files = ['5742', '5743']
    hgrepos = []
    issue_num = 860326
    keywords = ['patch']
    message_count = 6.0
    messages = ['45051', '45052', '45053', '45054', '45055', '45056']
    nosy_count = 4.0
    nosy_names = ['gvanrossum', 'tim.peters', 'georg.brandl', 'jhermann']
    pr_nums = []
    priority = 'normal'
    resolution = 'accepted'
    stage = None
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue860326'
    versions = ['Python 3.0']

    @jhermann
    Copy link
    Mannequin Author

    jhermann mannequin commented Dec 15, 2003

    PyErrr_Display and traceback.format_exception_only
    behave differently; namely, the first one prints the
    module of an exception, the latter not.

    The attached tb_problem.py illustrates the problem, it
    prints:

    Error: text

    Traceback (most recent call last):
      File "tb_problem.py", line 3, in ?
        raise uu.Error("text")
    uu.Error: text

    (note the diff betwen "Error:..." and "ui.Error:...")

    The attached patch fixes this. Python 2.2.2 has the
    same problem.

    @jhermann jhermann mannequin closed this as completed Dec 15, 2003
    @jhermann jhermann mannequin assigned gvanrossum Dec 15, 2003
    @jhermann jhermann mannequin added the extension-modules C modules in the Modules dir label Dec 15, 2003
    @jhermann jhermann mannequin closed this as completed Dec 15, 2003
    @jhermann jhermann mannequin assigned gvanrossum Dec 15, 2003
    @jhermann jhermann mannequin added the extension-modules C modules in the Modules dir label Dec 15, 2003
    @birkenfeld
    Copy link
    Member

    Logged In: YES
    user_id=849994

    Late is better than never ;)

    Thanks for the patch, I applied it as rev. 45321, 45322(2.4).

    @tim-one
    Copy link
    Member

    tim-one commented Apr 13, 2006

    Logged In: YES
    user_id=31435

    As noted on python-dev, the 2.4-branch backport should be
    reverted, because it changes visible behavior (including
    causing at least three of the standard tests to fail).

    @tim-one
    Copy link
    Member

    tim-one commented Apr 13, 2006

    Logged In: YES
    user_id=31435

    Opened this again. Anthony reverted the patch on both trunk
    and 2.4 branch. Whether it will be applied on the trunk
    again is being discussed on python-dev.

    @birkenfeld
    Copy link
    Member

    Logged In: YES
    user_id=849994

    Seems like this is an item for Python 3000.

    @gvanrossum
    Copy link
    Member

    Logged In: YES
    user_id=6380

    Committed in the p3yk branch as revision 51625.

    This isn't exactly the same patch, and also fixes the
    doctests that this here patch broke, but it fixes the same
    issue.

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 9, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    extension-modules C modules in the Modules dir
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants