opensafely-core / opensafely-core/opencodelists

Refactor coding system and mapping Downloader classes

Open
#2,244 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

deck-scrubbing
Dominant language
Python
Stars
60
Forks
16
Avg merge
4d 12h
Merged PRs (30d)
17

Description

Following this comment on a PR review.

The bnf to dmd mapping downloader was based on the TrudDownloader class used by the dm+d and SNOMED CT coding systems for reasons of expediency and the ease of integrating it into the scheduled download scripts used by the latter.

It was pointed out in the review that this reimplementation and the original class could be refactored to change methods that are currently instance methods to static methods and remove some duplicated code.

These both could be further refactored into a common ancestor to further reduce duplication.

Contributor guide

No contributing guide indexed for this repository

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.

Research direction

Start by locating the TrudDownloader class, the bnf-to-dmd mapping downloader, and the scheduled download scripts for dm+d and SNOMED CT. Compare their duplicated methods and identify which instance methods can become static; done means the downloaders share a common ancestor with the duplication removed and the scheduled scripts still work.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.