Migrate licenses.py to spec + code generation
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Refactor
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- javascript, json, python
- Domain
- build-system, testing, tooling
Research direction
Start by comparing the migration pattern in #182 with le_utils/constants/licenses.py and resources/licenselookup.json. Create spec/constants-licenses.json, update tests/test_licenses.py, and run pytest tests/test_licenses.py -v before running make build. Done means generated Python and JavaScript outputs contain the specified constants and license data, resources/licenselookup.json is removed, and the full test suite passes.
Written by the indexing model from the issue text.
Description
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.
Overview
licenses should be generated from a spec in the format #182 introduces. It has no known wrong values, so its public Python API should not change.
Complexity: Low
Target branch: main
Context
LICENSELISTids are ints 1–9, while the constants hold license names (CC_BY = "CC BY");licenselookup.jsonkeys are the ids as strings.- Every
License.descriptionis"";licenselookup.jsonhas nodescriptionfield.
The Change
js/Licenses.jsshould export the constants as its default export and the license records as a named export.
Acceptance Criteria
-
le_utils/constants/licenses.pyandjs/Licenses.jsare generated fromspec/constants-licenses.json,licenselookup.jsonis deleted, andmake buildon a clean checkout leaves no diff. - The pinned-API test from #182 passes unchanged for
licenses.
AI usage
I made the decisions recorded on #181 and #182; Claude Code applied them to this module against the current code and drafted the issue.
- Dominant language
- Python
- Stars
- 7
- Forks
- 37
- Avg merge
- 7d 42m
- Merged PRs (30d)
- 7
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing 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.
More from learningequality/le-utils
-
Difficulty 4/5 3-5 days Newbie friendliness 20/100
learningequality/le-utils#187 ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
learningequality/le-utils#186 ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
learningequality/le-utils#185 ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
learningequality/le-utils#184 ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
learningequality/le-utils#182 ·
Maintainers usually reply within 1 day
All issues in learningequality/le-utils
Similar issues
-
json_params_matcher fails on falsy top-level JSON primitives (0, False, "")Possibly taken @mayureshsonawane17 claimed this today. OpenWaiting for: Product Owner
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 5 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
bojieli/ai-agent-book#1169 ·
Maintainers usually reply within 1 day
-
priority:low ready-for-dev
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
OpenHands/extensions#738 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
micronaut-projects/micronaut-core#13677 ·
Maintainers usually reply within 1 day