Loading puzzles…
Loading puzzles…
Each puzzle is set in a real open-source repository. Read the code, find the answer, and select it in the editor.
New to reading code? Start with Learn: short lessons on values, branches, calls and tracing, then puzzles to try next.
Anyone can read the puzzles. Sign in to submit answers and keep track of what you've solved.
31 of 141 puzzles
Matching a request to the code that handles it.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Building the trailing-slash redirect path | Find | Medium | encode-starlettePython | Routing |
| HEAD falls back to GET | Find | Medium | h3js-h3TypeScript | Routing |
| The no-compose fast path | Find | Medium | honojs-honoTypeScript | RoutingMiddleware and hooks |
Code that runs before or after a handler: middleware, hooks, guards and interceptors.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| The no-compose fast path | Find | Medium | honojs-honoTypeScript | RoutingMiddleware and hooks |
| Detecting a state mutation | Find | Medium | reduxjs-redux-toolkitTypeScript | State managementMiddleware and hooks |
The path a request takes from arrival to the response sent back.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Re-raising when no handler matches | Find | Medium | pallets-flaskPython | ErrorsRequest lifecycle |
How errors are raised, classified and turned into responses.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Rejecting leftover arguments | Find | Medium | pallets-clickPython | Command-line appsErrors |
| Re-raising when no handler matches | Find | Medium | pallets-flaskPython | ErrorsRequest lifecycle |
Sending requests: redirects, adapters, transports, proxies and request bodies.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Filling in allowAbsoluteUrls | Find | Medium | axios-axiosJavaScript | Configuration and defaultsHTTP clients |
| Dropping credentials on cross-origin redirects | Find | Medium | encode-httpxPython | HTTP clientsAuth and security |
| Dropping the body on a redirect | Find | Medium |
Tracking what state code reads, and running it again when that state changes.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Diffing a derivation's dependencies | Find | Medium | mobxjs-mobxTypeScript | Reactivity |
| Runaway reaction cycle guard | Find | Medium | mobxjs-mobxTypeScript | Reactivity |
| Deferring a notified effect | Find | Medium | vuejs-coreTypeScript | Reactivity |
Turning templates and schemas into code or into another format.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Per-type coercion rules | Find | Medium | ajv-validator-ajvTypeScript | Validation and parsingCompilers and code generation |
| Source text becomes a function | Find | Medium | ajv-validator-ajvTypeScript | Compilers and code generation |
| Stripping whitespace before a tag | Find | Medium | pallets-jinja |
Checking input against a schema or type, and converting it.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Per-type coercion rules | Find | Medium | ajv-validator-ajvTypeScript | Validation and parsingCompilers and code generation |
| Skipping a hook nobody needs | Find | Medium | python-attrs-attrsPython | Validation and parsingConfiguration and defaults |
How modules and providers are registered, resolved and wired together.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| The class behind Depends | Find | Medium | fastapi-fastapiPython | Dependency injectionCode structure |
| Swapping a dependency for its override | Find | Medium | fastapi-fastapiPython | Dependency injection |
| Skipping the global module binding | Find | Medium |
Where a library lets you plug in your own code.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Default JSON provider | Find | Medium | pallets-flaskPython | Configuration and defaultsExtension points |
| The column that refreshes less often | Find | Medium | textualize-richPython | Extension points |
How options are merged, defaulted and looked up.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Filling in allowAbsoluteUrls | Find | Medium | axios-axiosJavaScript | Configuration and defaultsHTTP clients |
| Who makes the module token | Find | Medium | nestjs-nestTypeScript | Dependency injectionConfiguration and defaults |
| Default JSON provider | Find | Medium |
Stores, reducers, actions and thunks.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Detecting a state mutation | Find | Medium | reduxjs-redux-toolkitTypeScript | State managementMiddleware and hooks |
| Thunk condition returns false | Find | Medium | reduxjs-redux-toolkitTypeScript | State management |
Keeping data to use later: caches, key-value stores, eviction and expiry.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| The most specific mount wins | Find | Medium | unjs-unstorageTypeScript | RoutingCaching and storage |
Streams of values, the operators that transform them, and subscriptions.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Completing a throttle after its trailing value | Find | Medium | reactivex-rxjsTypeScript | Observables |
Sessions, credentials, and defenses against unsafe requests.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Dropping credentials on cross-origin redirects | Find | Medium | encode-httpxPython | HTTP clientsAuth and security |
How a codebase is split into modules, layers and class hierarchies.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| The class behind Depends | Find | Medium | fastapi-fastapiPython | Dependency injectionCode structure |
| Where asdict really recurses | Find | Medium | python-attrs-attrsPython | Code structure |
Parsing arguments and options, and running commands.
| Puzzle | Type | Difficulty | Repository | Topics |
|---|---|---|---|---|
| Ordering parameters for processing | Find | Medium | pallets-clickPython | Command-line apps |
| Rejecting leftover arguments | Find | Medium | pallets-clickPython | Command-line appsErrors |
| First router tried by the default app | Find | Medium | honojs-honoTypeScript | Routing |
| The most specific mount wins | Find | Medium | unjs-unstorageTypeScript | RoutingCaching and storage |
| psf-requestsPython |
| HTTP clients |
| Dropping dependencies a run did not read | Find | Medium | vuejs-coreTypeScript | Reactivity |
| Compilers and code generation |
| Tags that are never closed | Find | Medium | textualize-richPython | Compilers and code generation |
| nestjs-nestTypeScript |
| Dependency injection |
| Who makes the module token | Find | Medium | nestjs-nestTypeScript | Dependency injectionConfiguration and defaults |
| pallets-flaskPython |
| Configuration and defaultsExtension points |
| Where the built-in filters are listed | Find | Medium | pallets-jinjaPython | Configuration and defaults |
| Skipping a hook nobody needs | Find | Medium | python-attrs-attrsPython | Validation and parsingConfiguration and defaults |