Question 210
A developer's user setting allows an action that an applicable managed policy denies. The action is still blocked. What should the developer investigate first?
- Whether a contradictory project instruction says the managed restriction may be ignored.
- Whether the same allow rule appears twice in the user file.
- Whether the conversation has enough remaining tokens.
- The effective managed policy and its precedence.
Explanation
Correct Answer
D:Organization-enforced restrictions can override personal settings, so the effective policy explains the block. Troubleshooting should examine the effective sources rather than repeatedly adding a lower-precedence allow rule. A blocked action can be the expected result of the organization's policy.
Incorrect Answers
A:Project prose does not override an enforced organization-level configuration policy.
B:Duplicating a personal rule does not give it authority over managed restrictions.
C:Context capacity does not determine which configuration policy takes precedence.
Question 211
A developer manually creates .claude/settings.local.json to test a personal hook. What should she check before committing other work?
- That the file's personal-looking name makes it safe to stage without inspecting Git tracking.
- That the personal settings file is excluded from version control.
- That the hook is copied to shared settings so the personal experiment survives future clones.
- That a comment inside the JSON file tells Git not to commit it.
Explanation
Correct Answer
B:A manually created local file may need an explicit ignore rule to keep the experiment private to that checkout. Local scope describes where a setting applies; version-control tracking is a separate concern. Inspecting the staged file set prevents a personal experiment from accidentally becoming team configuration.
Incorrect Answers
A:A local-scope name does not by itself prove that the file is absent from the staged changes. The developer should verify what will actually enter version control.
C:Shared settings intentionally distribute behavior to the team. That changes the experiment's audience rather than keeping it private to the developer's checkout.
D:Git tracking is controlled outside the file's descriptive contents. An in-file note cannot keep a staged personal setting out of the commit.
Question 212
Claude Code reports that a newly edited settings file cannot be parsed. What is the most direct first repair?
- Move the malformed object into shared project guidance so it is loaded earlier.
- Change the model selection while leaving the malformed settings file unchanged.
- Add the same malformed object to a higher-precedence file.
- Validate the JSON and correct the reported syntax error.
Explanation
Correct Answer
D:The configuration must parse before its intended values can be loaded or evaluated. Syntax validation should precede debugging precedence or individual key meanings. A malformed file may prevent the intended configuration from being applied at all.
Incorrect Answers
A:Changing the document's location or purpose does not repair the settings syntax. The parser error should be addressed in the configuration that failed.
B:The settings parser must read valid configuration before the chosen model can matter. Model selection cannot repair the document's syntax.
C:Moving invalid syntax does not make the configuration readable.
Question 213
CLAUDE.md says to run npm test, but this repository now uses pnpm and the old command fails. What should the agent do?
- Verify the repository's current command and update stale guidance.
- Install an unrelated test framework globally.
- Ignore all repository instructions for the remainder of the task.
- Retry npm test until it passes without inspecting the repository.
Explanation
Correct Answer
A:Repository evidence can establish the current workflow and prevent the obsolete instruction from misleading later work. The scripts and lockfile provide concrete evidence of the repository's current package workflow. Correcting the shared instruction prevents the same setup failure in later sessions.
Incorrect Answers
B:Changing the test framework introduces work unrelated to the stale package-manager instruction.
C:One stale instruction does not invalidate every other applicable project convention.
D:Repeatedly executing an obsolete command does not resolve the documented tooling mismatch.
Question 214
A developer has added the status of every one-off bug investigation to the repository's permanent CLAUDE.md. It now obscures the build commands. What is the best cleanup?
- Convert every temporary note into a mandatory rule for all future tasks.
- Remove all project guidance and depend on model memory.
- Keep durable project conventions there and move temporary investigation state to task-specific records.
- Delete every instruction older than a week, including stable build and architecture guidance.
- Compress every investigation into one sentence but keep all of them in the permanent instruction file indefinitely.
Explanation
Correct Answer
C:Persistent guidance stays useful when short-lived task details do not bury recurring project facts. Build commands, conventions, and architectural boundaries have continuing value across tasks. Investigation transcripts usually belong with the issue or task they explain.
Incorrect Answers
A:A past investigation is not necessarily a valid instruction for unrelated work.
B:Eliminating stable instructions sacrifices useful shared context along with the temporary material.
D:Age alone does not distinguish obsolete task state from enduring project rules. This cutoff would discard guidance whose usefulness has not expired.
E:Compression reduces length without deciding whether a note should govern future tasks. Accumulating temporary state still obscures the small set of durable conventions.
Question 215
An expiry test sleeps for one real second and then checks whether a token expired. It fails intermittently under CI load. The code can obtain time through an injectable clock interface. Which test design most directly checks the expiry boundary deterministically?
- Inject a controlled clock and test just before, at, and after the documented expiry boundary.
- Retry the same sleeping test until one run passes.
- Remove the expiry assertion and check only that the token was created.
- Increase the sleep to a minute and keep relying on the wall clock.
Explanation
Correct Answer
A:The test can select exact instants without waiting for elapsed wall time. Independent expected results at the boundary verify the expiry rule reproducibly.
Incorrect Answers
B:Retries can hide timing sensitivity but do not establish which boundary was exercised. A passing attempt may merely have run under more favorable scheduling.
C:Creation does not verify expiration. Removing the boundary assertion drops the behavior the test is meant to protect.
D:A longer sleep slows the suite without giving precise control over the tested instant. Scheduling and timing assumptions still determine the observation.
Question 216
A repository's CLAUDE.md should reuse a maintained development guide rather than duplicate its text. Which approach supports a single source of guidance?
- Maintain a separate full copy of the shared policy inside every project instruction file.
- Mention only that some guidance exists without identifying its location.
- Use the documented instruction-file import mechanism and keep the referenced guide maintained.
- Move the guide into the application's generated binary.
Explanation
Correct Answer
C:An explicit reference can reuse shared guidance without creating another separately edited copy. A maintained import avoids two diverging copies of the same rules. The referenced file should remain accessible from the repository layout used by teammates.
Incorrect Answers
A:Each copy creates another update location. The scenario's maintenance problem calls for referencing the common source rather than allowing independently edited copies to drift.
B:An unspecified reference does not reliably provide the instructions the agent needs.
D:An opaque build artifact is not an appropriate source for readable project instructions.
Question 217
A team wants Claude Code to know how to authenticate a test client. What belongs in shared project guidance?
- A sample token that is valid indefinitely.
- The approved secret-injection mechanism and variable names, without credential values.
- A production access token with an instruction not to reveal it.
- Every developer's personal token to avoid future setup work.
Explanation
Correct Answer
B:Setup instructions can explain authentication while leaving secrets in the appropriate credential system. Variable names and setup steps can be committed without the actual access token. The runtime can then obtain the credential through the team's approved injection mechanism.
Incorrect Answers
A:A working long-lived token remains a secret even when described as a sample.
C:A secrecy instruction does not make a credential safe to commit in shared documentation.
D:Collecting individual credentials increases exposure and does not provide a sound setup process.
Question 218
A skill author writes its description only as a sentence in the body, leaving discovery metadata vague. Why can this impair automatic selection?
- Discovery relies on the skill's identifying metadata before the full procedure is loaded.
- The body alone determines discovery, so the frontmatter description can remain unrelated to the skill.
- Load every installed skill body into every request before deciding which skill is relevant.
- Put the entire procedure into the description and leave no body for later loading.
Explanation
Correct Answer
A:A precise frontmatter description helps select the skill before its detailed instructions are brought into context. A task-relevant description is useful during discovery, before the lengthy checklist is needed. Putting all selection guidance inside the body defeats that staged loading purpose.
Incorrect Answers
B:The description is available during relevance selection. An unrelated description can prevent useful selection or trigger the skill for the wrong task before its body is loaded.
C:That discards the selective-loading benefit of discoverable metadata. The description should help choose which full procedure needs to enter context.
D:This expands the discovery metadata with content that is only needed during execution. A concise trigger description and a separate procedure preserve their different roles.
Question 219
A narrowly targeted database-migration skill activates during ordinary spelling fixes. Which change most directly improves selection?
- Rename the skill to database-migration while leaving its description applicable to all repository edits.
- Increase the number of migration examples without changing its broad description.
- Add more procedural detail to the skill body without changing the broad discovery description.
- Describe the migration tasks it covers and explicitly delimit unrelated editing tasks.
Explanation
Correct Answer
D:A precise description gives the model a better basis for deciding when the procedure applies. The description should identify database migration work with enough specificity to exclude ordinary text edits. Test both intended activations and nearby tasks that should leave the skill unused.
Incorrect Answers
A:A narrower name does not resolve an explicit description that still invites unrelated tasks. Selection guidance needs to describe the actual activation boundary.
B:More examples do not necessarily fix an overbroad activation description.
C:Execution instructions help after selection. They do not directly narrow the description that is causing the skill to be selected for spelling edits.
Question 220
A release skill should be available through an explicit slash command but should not be selected automatically by the model. Which skill setting matches that intent?
- A skill name beginning with manual while leaving invocation settings unchanged.
- context: fork, with no change to invocation controls.
- user-invocable: false
- disable-model-invocation: true
- disable-model-invocation: false together with user-invocable: true.
Explanation
Correct Answer
D:This setting keeps model-initiated invocation disabled while allowing the user to request the skill. Explicit invocation remains a way for the user to request the procedure. This selection setting does not replace any separate authorization checks required by the release actions.
Incorrect Answers
A:A naming convention describes intent but does not disable model-initiated invocation.
B:Forked execution controls the context in which a skill runs. It does not make the skill available only through a user's explicit command.
C:Hiding user invocation is the opposite of preserving an explicit user command.
E:These values leave both model and user invocation available. They do not impose the required restriction on automatic selection.