mailbox: other programs' messages can vanish without trace

Open
#44,251 52 comments 0 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
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
python
Domain
backend

Research direction

Start by reviewing mailbox-unified.patch, mailbox-unified2-test.diff, and the later mailbox-tests-2.7 patches, then run the mailbox tests they modify or reference. Done means the reported concurrent single-file mailbox scenario no longer allows other programs' messages to disappear, with regression coverage preserved.

Written by the indexing model from the issue text.

Description

3.10 3.11 3.9 (EOL) stdlib topic-email type-bug
BPO 1599254
Nosy @loewis, @warsaw, @terryjreedy, @devdanzin, @jwilk, @bitdancer, @akheron, @jimjjewett, @iritkatriel
Files
  • mailbox-copy-back.diff: Rewrite single-file mailbox by copying
  • mailbox-test.patch: Adds a test showing problem
  • length-checking.diff: Add length-checking to single-file mailboxes
  • mailbox-update-toc.diff: Update _toc on locking
  • mailbox-test-lock.diff: Lock/unlock around message count in test case
  • mailbox-docs.diff: Doc patch
  • mailbox-update-toc-fixed.diff: Return correct key from add()
  • mailbox-copy-back-53287.diff: Update to be against current version
  • mailbox-copy-back-new.diff: Rewrite single-file mailbox by copying
  • mailbox-fcntl-warn.diff: Warn when flush() may release lock
  • mailbox-pending-lock.diff: Small diff
  • mailbox-unified-patch.diff: Unified patch that fixes everything.
  • mailbox-unified2-test.diff: New version (test part)
  • mailbox-unified2-module.diff: New version (module part, semi-broken)
  • mailbox-update-toc-new.diff: Preserve message keys when rereading
  • mailbox-update-toc-again.diff: New version of _update_toc()
  • test_mailbox-reread.diff: Tests for concurrency/rereading _toc
  • mailbox-babyl-fix.diff: In Babyl class, write preamble before adding messages to an empty file
  • mailbox-copy-back-2.7.diff
  • mailbox-all-tests-2.7.diff
  • mailbox-tests-2.7-part1-for-copy-back.diff
  • mailbox-tests-2.7-part2.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 2006-11-19.16:03:08.000>
    labels = ['type-bug', 'library', '3.9', '3.10', '3.11']
    title = "mailbox: other programs' messages can vanish without trace"
    updated_at = <Date 2021-12-12.16:08:57.605>
    user = 'https://bugs.python.org/baikie'
    

    bugs.python.org fields:

    activity = <Date 2021-12-12.16:08:57.605>
    actor = 'iritkatriel'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Library (Lib)']
    creation = <Date 2006-11-19.16:03:08.000>
    creator = 'baikie'
    dependencies = []
    files = ['2219', '2220', '2221', '2222', '2223', '2224', '2225', '2226', '2227', '2228', '2229', '2230', '2231', '2232', '2233', '2234', '2235', '2236', '34596', '34597', '34672', '34673']
    hgrepos = []
    issue_num = 1599254
    keywords = ['patch']
    message_count = 52.0
    messages = ['30590', '30591', '30592', '30593', '30594', '30595', '30596', '30597', '30598', '30599', '30600', '30601', '30602', '30603', '30604', '30605', '30606', '30607', '30608', '30609', '30610', '30611', '30612', '30613', '30614', '30615', '30616', '30617', '30618', '30619', '30620', '30621', '30622', '30623', '30624', '30625', '30626', '30627', '30628', '30629', '84585', '116185', '138216', '164004', '213979', '214007', '214043', '214648', '215207', '217378', '217713', '408393']
    nosy_count = 12.0
    nosy_names = ['loewis', 'barry', 'nnorwitz', 'terry.reedy', 'baikie', 'ajaksu2', 'peter.ll', 'jwilk', 'r.david.murray', 'petri.lehtinen', 'Jim.Jewett', 'iritkatriel']
    pr_nums = []
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue1599254'
    versions = ['Python 3.9', 'Python 3.10', 'Python 3.11']
    

    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.