fix: remove project filter from file-context hook — cwd != stored project name
The handler was passing input.cwd (full absolute path) as the project
filter, but observations store short project names ('san-diego', not
'/Users/.../san-diego'). This caused zero results for every query.
Removing the filter entirely is better: cross-project observations
about the same file are useful for duplicate prevention.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -104,9 +104,6 @@ export const fileContextHandler: EventHandler = {
|
||||
// Query worker for observations related to this file
|
||||
try {
|
||||
const queryParams = new URLSearchParams({ path: filePath });
|
||||
if (input.cwd) {
|
||||
queryParams.set('project', input.cwd);
|
||||
}
|
||||
|
||||
const response = await workerHttpRequest(`/api/observations/by-file?${queryParams.toString()}`, {
|
||||
method: 'GET',
|
||||
|
||||
Reference in New Issue
Block a user