_threadedselect.py duplicates tons of code from selectreactor.py
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 6k
- Forks
- 1.2k
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 10
Description
| @exarkun reported | |
|---|---|
| Trac ID | trac#2325 |
| Type | defect |
| Created | 2006-12-24 00:26:11Z |
We should try to remove the code duplication between these two files so that the esoteric select(2) error handling logic doesn't have to be maintained in two places. Since it is actually possible to test selectreactor, it would also be beneficial to _threadedselect to just re-use its code, since we can't unit test _threadedselect.
Searchable metadata
trac-id__2325 2325
type__defect defect
reporter__exarkun exarkun
priority__high high
milestone__
branch__
branch_author__
status__new new
resolution__None None
component__core core
keywords__
time__1166919971000000 1166919971000000
changetime__1299985615000000 1299985615000000
version__None None
owner__TimothyFitz TimothyFitz
cc__exarkun cc__itamarst
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Compare _threadedselect.py with selectreactor.py, focusing on the duplicated select(2) error-handling logic. Start with the testable selectreactor implementation and identify how _threadedselect can reuse it. Done means the duplicated logic is removed while selectreactor remains testable and both paths retain the intended behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend, networking
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100