Skip to content

Commit 8fe5ca9

Browse files
authored
Disallow a difficulty level of 0 (#290)
* Disallow a difficulty level of 0 * Mention hard difficulty levels explicitly
1 parent aeaa8a5 commit 8fe5ca9

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

building/configlet/lint.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ The `config.json` file should have the following checks:
144144
- The `"exercises.practice[].uuid"` value must be a unique version 4 UUID string⁵
145145
- The `"exercises.practice[].uuid"` value for each exercise must never change
146146
- The `"exercises.practice[].difficulty"` key is required
147-
- The `"exercises.practice[].difficulty"` value must be an integer >= 0 and <= 10
147+
- The `"exercises.practice[].difficulty"` value must be an integer >= 1 and <= 10
148148
- The `"exercises.practice[].practices"` key is required
149149
- The `"exercises.practice[].practices"` value must be a non-empty array of strings if `"exercises.practice[].status"` is not equal to `deprecated`
150150
- The `"exercises.practice[].practices"` value must be an empty array if `"exercises.practice[].status"` is equal to `deprecated`

building/tracks/config-json.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,10 +147,10 @@ Each concept exercise is an entry in the `exercises.practice` array. The followi
147147
- `name`: the exercise's name. Its length must be <= 255.
148148
- `practices`: an array of concept slugs that the exercise is helping students practice
149149
- `prerequisites`: an array of concept slugs that must be unlocked before a student can start the exercise
150-
- `difficulty`: a number indicating the difficulty of the exercise. The number must be in the range of 0 (easiest) to 10 (hardest). The website interprets the difficulty as follows:
150+
- `difficulty`: a number indicating the difficulty of the exercise. The number must be in the range of 1 (easiest) to 10 (hardest). The website interprets the difficulty as follows:
151151
- 1,2,3: easy
152152
- 4,5,6,7: medium
153-
- else: hard
153+
- 8,9,10: hard
154154
- `status` (optional): the exercise's status, which is either `"wip"`, `"beta"`, `"active"` or `"deprecated"`; defaults to `"active"` if not specified
155155
- `wip`: A work-in-progress exercise not ready for public consumption. Exercises with this tag will not be shown to students on the UI or be used for unlocking logic. They may appear for maintainers.
156156
- `beta`: This signifies active exercises that are new and which we would like feedback on. We show a beta label on the site for these exercise, with a Call To Action of "Please give us feedback"

0 commit comments

Comments
 (0)