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

plistlib.FMT_BINARY behavior doesn't send required dict parameter #66087

Closed
n8henrie mannequin opened this issue Jun 30, 2014 · 4 comments
Closed

plistlib.FMT_BINARY behavior doesn't send required dict parameter #66087

n8henrie mannequin opened this issue Jun 30, 2014 · 4 comments
Assignees
Labels
stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error

Comments

@n8henrie
Copy link
Mannequin

n8henrie mannequin commented Jun 30, 2014

BPO 21888
Nosy @ronaldoussoren, @ned-deily, @serhiy-storchaka, @n8henrie
Files
  • plistlib_explicit_fmt.path
  • 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/serhiy-storchaka'
    closed_at = <Date 2014-07-23.16:04:38.539>
    created_at = <Date 2014-06-30.17:08:19.867>
    labels = ['type-bug', 'library']
    title = "plistlib.FMT_BINARY behavior doesn't send required dict parameter"
    updated_at = <Date 2014-07-23.16:04:38.539>
    user = 'https://github.com/n8henrie'

    bugs.python.org fields:

    activity = <Date 2014-07-23.16:04:38.539>
    actor = 'serhiy.storchaka'
    assignee = 'serhiy.storchaka'
    closed = True
    closed_date = <Date 2014-07-23.16:04:38.539>
    closer = 'serhiy.storchaka'
    components = ['Library (Lib)']
    creation = <Date 2014-06-30.17:08:19.867>
    creator = 'n8henrie'
    dependencies = []
    files = ['35888']
    hgrepos = []
    issue_num = 21888
    keywords = []
    message_count = 4.0
    messages = ['221969', '221977', '222483', '223743']
    nosy_count = 5.0
    nosy_names = ['ronaldoussoren', 'ned.deily', 'python-dev', 'serhiy.storchaka', 'n8henrie']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue21888'
    versions = ['Python 3.4', 'Python 3.5']

    @n8henrie
    Copy link
    Mannequin Author

    n8henrie mannequin commented Jun 30, 2014

    When using the new plistlib.load and the FMT_BINARY option, line 997:

    p = _FORMATS[fmt]['parser'](use_builtin_types=use_builtin_types)

    doesn't send the dict_type to _BinaryPlistParser.__init__ (line 601), which has dict_type as a required positional parameter, causing an error

    def __init__(self, use_builtin_types, dict_type):

    My first bugs.python.org report, hope I'm doing it right...

    @n8henrie n8henrie mannequin added stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error labels Jun 30, 2014
    @ned-deily
    Copy link
    Member

    Thanks for the report. Can you supply a test case and/or a fix patch? Ideally, the test case would be a patch to Lib/test/test_plistlib.py. If you're interested, there's more info here: https://docs.python.org/devguide/

    @serhiy-storchaka
    Copy link
    Member

    Here is a patch.

    @serhiy-storchaka serhiy-storchaka self-assigned this Jul 23, 2014
    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Jul 23, 2014

    New changeset 09746dc1a3b4 by Serhiy Storchaka in branch '3.4':
    Issue bpo-21888: plistlib's load() and loads() now work if the fmt parameter is
    http://hg.python.org/cpython/rev/09746dc1a3b4

    New changeset 275d02865d11 by Serhiy Storchaka in branch 'default':
    Issue bpo-21888: plistlib's load() and loads() now work if the fmt parameter is
    http://hg.python.org/cpython/rev/275d02865d11

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants