Skip to content

Fix resolve() to handle direct list indexing#76

Merged
jph00 merged 2 commits intoAnswerDotAI:mainfrom
civvic:fix-resolve-indexing
Dec 30, 2025
Merged

Fix resolve() to handle direct list indexing#76
jph00 merged 2 commits intoAnswerDotAI:mainfrom
civvic:fix-resolve-indexing

Conversation

@civvic
Copy link
Copy Markdown
Contributor

@civvic civvic commented Dec 27, 2025

Fixes #75

The resolve() function failed when given symbols like mylist[2] (direct indexing without a dot). It worked for obj.attr[2] but not mylist[2].

The regex split was treating mylist[2] as a single part and trying to look it up as a key in globals. Added a check to handle direct indexing before the split.

@civvic civvic changed the title Fix resolve indeFix resolve() to handle direct list indexingxing Fix resolve() to handle direct list indexingxing Dec 27, 2025
@civvic civvic changed the title Fix resolve() to handle direct list indexingxing Fix resolve() to handle direct list indexing Dec 27, 2025
@jph00 jph00 merged commit 5fa190f into AnswerDotAI:main Dec 30, 2025
@jph00
Copy link
Copy Markdown
Contributor

jph00 commented Dec 30, 2025

Thanks! :)

@jph00 jph00 added the bug Something isn't working label Dec 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

resolve() fails on direct list indexing (e.g., mylist[2])

2 participants