Skip to content

Fix source-code example crash#3

Draft
cursor[bot] wants to merge 2 commits into
mainfrom
cursor/critical-correctness-bugs-2b38
Draft

Fix source-code example crash#3
cursor[bot] wants to merge 2 commits into
mainfrom
cursor/critical-correctness-bugs-2b38

Conversation

@cursor
Copy link
Copy Markdown

@cursor cursor Bot commented May 13, 2026

Bug and impact

Running source/load_mod_from_source_code.py crashed immediately with NameError: name 'b' is not defined, so the newly added example could not be used successfully.

Root cause

The executed source snippet assigned a=b without defining b in the execution namespace.

Fix

Changed the snippet to assign a literal value (a='b') and added a unittest regression test that runs the script end-to-end.

Validation

  • python3 source/load_mod_from_source_code.py
  • python3 -m unittest discover -s tests -v
Open in Web View Automation 

cursoragent and others added 2 commits May 13, 2026 11:04
Co-authored-by: 0-coding <0-coding@users.noreply.github.com>
Co-authored-by: 0-coding <0-coding@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant