Skip to content

Prevent non-finite hues for long color identifiers - #664

Open
partyplatter08-lab wants to merge 1 commit into
tscircuit:mainfrom
partyplatter08-lab:partyplatter08-lab/bounty-651
Open

Prevent non-finite hues for long color identifiers#664
partyplatter08-lab wants to merge 1 commit into
tscircuit:mainfrom
partyplatter08-lab:partyplatter08-lab/bounty-651

Conversation

@partyplatter08-lab

Copy link
Copy Markdown

Summary

  • preserve existing getColorFromString results for ordinary identifiers
  • switch to modulo-360 accumulation before the hash can overflow, keeping arbitrary-length identifiers finite and deterministic
  • verify the reported long-string case and ensure long suffixes still affect the generated color

Testing

  • bun test
  • bun run build
  • bun run format:check
  • bunx tsc --noEmit

Closes #651

/claim #651

@vercel

vercel Bot commented Jul 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
schematic-trace-solver Ready Ready Preview, Comment Jul 15, 2026 2:10am

Request Review

@partyplatter08-lab

Copy link
Copy Markdown
Author

Friendly ping — this PR remains open and CI-clean on our side (tracked bounty ~$50).

Happy to address any review comments or adjust scope if something no longer fits the issue.
No rush; just keeping the thread current.

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.

getColorFromString returns hsl(NaN, ...) for very long strings

1 participant