Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
6baf24c
Added Capture to Main CodeChat
jspahn80134 Nov 9, 2025
77e52bd
Ongoing Development
jspahn80134 Dec 12, 2025
d3f6b54
Merged capture code with latest extension
jspahn80134 Dec 12, 2025
7f316c4
Modified capture test
jspahn80134 Dec 14, 2025
a70d0d7
Ongoing Development
jspahn80134 Dec 19, 2025
6b81ab3
Conflicts resolved
jspahn80134 Dec 19, 2025
ef4d6ed
Merge branch 'main' of https://github.com/jspahn80134/CodeChat_Editor
jspahn80134 Feb 6, 2026
d0607ac
Merge branch 'main' of https://github.com/jspahn80134/CodeChat_Editor
jspahn80134 Feb 13, 2026
3e02cee
Capture Changes
jspahn80134 Feb 13, 2026
8ad17f6
Capture Integration Updates
jspahn80134 Feb 14, 2026
822deba
Conflict resolution
jspahn80134 Apr 13, 2026
1edd6dd
Minor statrup fix
jspahn80134 Apr 13, 2026
fe4abbc
Code Review Workoff
jspahn80134 Apr 22, 2026
9fe5827
Merge upstream changes
jspahn80134 Apr 22, 2026
54cfac7
Fix capture lint failure
jspahn80134 Apr 22, 2026
63ca1c1
Update rustls-webpki for audit advisory
jspahn80134 Apr 22, 2026
e0f2b38
Fix VS Code extension lint
jspahn80134 Apr 22, 2026
a2c5e88
Ongoing development
jspahn80134 May 3, 2026
3db0ef3
Fix capture enum clippy warning
jspahn80134 May 3, 2026
bf6e60d
Add rich capture analysis dataset and schema
jspahn80134 May 8, 2026
c110546
Verify rich capture schema writes
jspahn80134 May 8, 2026
980b6eb
Stabilize WebDriver message timeout
jspahn80134 May 8, 2026
f6ccbca
Match WebDriver test wait to client timeout
jspahn80134 May 8, 2026
c7c885b
Serialize WebDriver integration tests
jspahn80134 May 8, 2026
6861965
Format WebDriver test lock
jspahn80134 May 8, 2026
8e7cf00
Address PR review feedback on capture extension
jspahn80134 May 11, 2026
6b1a068
Merge upstream main into PR branch
jspahn80134 May 11, 2026
f79285f
Address capture review cleanups
jspahn80134 May 13, 2026
9adb84d
Stabilize websocket test timeout
jspahn80134 May 13, 2026
f2759d2
Make capture event type an enum
jspahn80134 May 13, 2026
1364968
Clarify capture activity classification
jspahn80134 May 13, 2026
92144c2
Address capture review setup concerns
jspahn80134 May 14, 2026
585c405
Improve capture smoke diagnostics
jspahn80134 May 15, 2026
3c13067
Align capture settings state and audit events
jspahn80134 May 15, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,16 @@
#
# dist build output
target/
/server/bindings/

# Runtime capture configuration and local fallback capture logs.
/capture_config.json
/capture-events-fallback.jsonl
/capture-metrics-*.csv
/capture-analysis-*/
/server/scripts/output
/server/scripts/capture-metrics-*.csv
/server/scripts/capture-analysis-*/
server/capture_config.json

# CodeChat Editor lexer: python. See TODO.
9 changes: 9 additions & 0 deletions capture_config.example.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"host": "your-aws-rds-endpoint.amazonaws.com",
"port": 5432,
"user": "your-db-user",
"password": "your-db-password",
"dbname": "your-db-name",
"app_id": "dissertation",
"fallback_path": "capture-events-fallback.jsonl"
}
9 changes: 8 additions & 1 deletion client/src/CodeChatEditor.mts
Original file line number Diff line number Diff line change
Expand Up @@ -693,8 +693,15 @@ export const on_error = (event: Event) => {
let err_str: string;
if (event instanceof ErrorEvent) {
err_str = `${event.filename}:${event.lineno}: ${event.message}`;
if (event.error?.stack) {
err_str += `\n${event.error.stack}`;
}
} else if (event instanceof PromiseRejectionEvent) {
err_str = `${event.promise} rejected: ${event.reason}`;
const reason = event.reason;
err_str = `${event.promise} rejected: ${reason}`;
if (reason instanceof Error && reason.stack) {
err_str += `\n${reason.stack}`;
}
} else {
err_str = `Unexpected error ${typeof event}: ${event}`;
}
Expand Down
18 changes: 13 additions & 5 deletions client/src/CodeMirror-integration.mts
Original file line number Diff line number Diff line change
Expand Up @@ -294,10 +294,12 @@ export const docBlockField = StateField.define<DecorationSet>({
prev.spec.widget.delimiter,
typeof effect.value.contents === "string"
? effect.value.contents
: apply_diff_str(
prev.spec.widget.contents,
effect.value.contents,
),
: Array.isArray(effect.value.contents)
? apply_diff_str(
prev.spec.widget.contents,
effect.value.contents,
)
: prev.spec.widget.contents,
// If autosave is allowed (meaning no autosave
// is not true), then this data came from the
// user, not the IDE.
Expand Down Expand Up @@ -1210,7 +1212,13 @@ export const scroll_to_line = (
};

// Apply a `StringDiff` to the before string to produce the after string.
export const apply_diff_str = (before: string, diffs: StringDiff[]) => {
export const apply_diff_str = (
before: string,
diffs: StringDiff[] | undefined,
) => {
if (diffs === undefined) {
return before;
}
// Walk from the last diff to the first. JavaScript doesn't have reverse
// iteration AFAIK.
let after = before;
Expand Down
4 changes: 4 additions & 0 deletions client/src/shared.mts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ import { CodeMirrorDocBlockTuple } from "./rust-types/CodeMirrorDocBlockTuple.js
import { UpdateMessageContents } from "./rust-types/UpdateMessageContents.js";
import { ResultOkTypes } from "./rust-types/ResultOkTypes.js";
import { ResultErrTypes } from "./rust-types/ResultErrTypes.js";
import { CaptureEventWire } from "./rust-types/CaptureEventWire.js";
import { CaptureStatus } from "./rust-types/CaptureStatus.js";

// Manually define this, since `ts-rs` can't export `webserver.MessageResult`.
type MessageResult = { Ok: ResultOkTypes } | { Err: ResultErrTypes };
Expand All @@ -55,6 +57,8 @@ export type {
CodeMirror,
CodeMirrorDiffable,
CodeMirrorDocBlockTuple,
CaptureEventWire,
CaptureStatus,
CodeChatForWeb,
EditorMessage,
EditorMessageContents,
Expand Down
2 changes: 1 addition & 1 deletion extensions/VSCode/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ src/index.d.ts
src/index.js
src/codechat-editor-client.win32-x64-msvc.node
.windows/

*.log
# CodeChat Editor lexer: python. See TODO.
38 changes: 37 additions & 1 deletion extensions/VSCode/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,15 @@
"version": "0.1.54-beta1",
"activationEvents": [
"onCommand:extension.codeChatEditorActivate",
"onCommand:extension.codeChatEditorDeactivate"
"onCommand:extension.codeChatEditorDeactivate",
"onCommand:extension.codeChatCaptureStatus",
"onCommand:extension.codeChatInsertReflectionPrompt",
"onCommand:extension.codeChatCaptureTaskStart",
"onCommand:extension.codeChatCaptureTaskSubmit",
"onCommand:extension.codeChatCaptureDebugTaskStart",
"onCommand:extension.codeChatCaptureDebugTaskSubmit",
"onCommand:extension.codeChatCaptureHandoffStart",
"onCommand:extension.codeChatCaptureHandoffEnd"
],
"contributes": {
"configuration": {
Expand All @@ -62,6 +70,26 @@
"In the default external web browser"
],
"markdownDescription": "Select the location of the CodeChat Editor Client. After changing this value, you **must** close then restart the CodeChat Editor extension."
},
"CodeChatEditor.Capture.RecordStudyEvents": {
"type": "boolean",
"default": false,
"markdownDescription": "Record CodeChat dissertation capture events. This defaults to off. Consent is recorded through **Manage CodeChat Capture** and also defaults to off.\n\n| Consent recorded | Record study events | What happens |\n| --- | --- | --- |\n| Off | Off | Capture is off. |\n| On | Off | Consent is retained, but recording is paused. |\n| On | On | Capture records study events. |\n| Off | On | Capture waits for consent before recording. |"
},
"CodeChatEditor.Capture.ConsentEnabled": {
"type": "boolean",
"default": false,
"markdownDescription": "Record that participant consent has been given for CodeChat dissertation capture. This defaults to off and persists after setting."
},
"CodeChatEditor.Capture.ParticipantId": {
"type": "string",
"default": "",
"markdownDescription": "Pseudonymous participant identifier used as the capture user_id. If left blank, CodeChat generates a UUID when the student gives consent."
},
"CodeChatEditor.Capture.HashFilePaths": {
"type": "boolean",
"default": true,
"markdownDescription": "Hash local file paths before they are sent to capture storage."
}
}
},
Expand All @@ -73,6 +101,14 @@
{
"command": "extension.codeChatEditorDeactivate",
"title": "Disable the CodeChat Editor"
},
{
"command": "extension.codeChatCaptureStatus",
"title": "Manage CodeChat Capture"
},
{
"command": "extension.codeChatInsertReflectionPrompt",
"title": "CodeChat: Insert Reflection Prompt"
}
]
},
Expand Down
Loading
Loading