json encoder unable to handle decimal

Open
#60,739 25 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
python
Domain
backend

Research direction

Start by reviewing the referenced json_decimal.patch and the linked BPO issue discussion to understand the proposed Decimal handling and unresolved decisions. Confirm the intended JSON encoding behavior and identify the relevant CPython library tests before making changes; the issue is complete only when the behavior is agreed and covered by tests.

Written by the indexing model from the issue text.

Description

stdlib type-feature
BPO 16535
Nosy @rhettinger, @jcea, @etrepum, @mdickinson, @pitrou, @tiran, @ezio-melotti, @merwok, @serhiy-storchaka, @lesinigo
Files
  • json_decimal.patch: Patch file generated via "hg diff"
  • 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 = None
    closed_at = None
    created_at = <Date 2012-11-22.22:45:38.401>
    labels = ['type-feature', 'library', '3.10']
    title = 'json encoder unable to handle decimal'
    updated_at = <Date 2022-03-03.10:12:29.632>
    user = 'https://github.com/merwok'
    

    bugs.python.org fields:

    activity = <Date 2022-03-03.10:12:29.632>
    actor = 'luca.lesinigo'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Library (Lib)']
    creation = <Date 2012-11-22.22:45:38.401>
    creator = 'eric.araujo'
    dependencies = []
    files = ['30836']
    hgrepos = []
    issue_num = 16535
    keywords = ['patch']
    message_count = 16.0
    messages = ['176135', '176136', '176158', '176161', '176398', '179869', '192520', '213381', '214733', '214737', '224032', '224096', '274026', '289010', '349250', '383559']
    nosy_count = 16.0
    nosy_names = ['rhettinger', 'jcea', 'bob.ippolito', 'mark.dickinson', 'pitrou', 'christian.heimes', 'ezio.melotti', 'eric.araujo', 'Arfrever', 'zzzeek', 'cvrebert', 'serhiy.storchaka', 'ralhei', 'mjensen', 'risa2000', 'luca.lesinigo']
    pr_nums = []
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue16535'
    versions = ['Python 3.10']
    

    Dominant language
    Python
    Stars
    77.2k
    Forks
    36k
    Avg merge
    1d 9h
    Merged PRs (30d)
    558

    Contributor guide

    Open the contributing guide

    First steps

    1. Read the whole issue, then the project's contributing guide.
    2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
    3. Fork the repository and make your change on a branch.
    4. Open a pull request that references the issue number.

    More from python/cpython

    All issues in python/cpython

    Similar issues

    More Python issues

    Get new issues in your inbox

    A short digest of beginner-friendly GitHub issues.