Repository navigation
Add a Python/ML code playground and an AI-coding resources hub - #58
Merged
samanyugoyal2010 merged 9 commits intoOct 11, 2026
Merged
samanyugoyal2010 merged 9 commits into
samanyugoyal2010 merged 9 commits into
Conversation
Split out of codewpurpose#57 so the redesign can be reviewed on its own. Built on main: - /playground: run real Python in the browser with Pyodide 0.27.7 in a Web Worker (lazy, nothing fetched until Run). NumPy, pandas, scikit-learn and matplotlib load on import; figures render as PNGs. Stop and a 30s limit restart runaway code; friendly tracebacks; eight starters; Share encodes the code in the URL hash only. input() takes answers up front. - Lessons: Python code blocks (.py or "Python" labels) get a Run button with an inline runner; REPL/traceback blocks and the ML scaling excerpt are excluded. - /resources/ai-coding: tool picks with official links (no prices), copyable prompts that teach rather than answer, a healthy AI workflow, safety tips and a glossary. - Both pages in the header's More menu, the footer's Learn column, the sitemap, and with their own share images. - About: Vibhav's bio reflects his role. Independent of codewpurpose#57: plain elements stand in for the redesign's motion components, and src/lib/og-image.tsx, src/lib/stats.ts and the copy-button styles are byte-identical to codewpurpose#57's, so either PR can land first. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Moves them into src/components/playground/tools.css, imported by the components that use them, so this PR and codewpurpose#57 don't both append to the end of globals.css and conflict. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
srivibhavpadakandla
requested review from
Bruhatt-Rao,
ShreyanMitra5 and
samanyugoyal2010
as code owners
October 10, 2026 22:53
|
Someone is attempting to deploy a commit to the Shreyan Mitra's projects Team on Vercel. A member of the Team first needs to authorize it. |
Contributor
There was a problem hiding this comment.
1 issue found across 31 files
Confidence score: 3/5
- If worker creation throws in
python-runtime.ts,run()leaves the runner active and never callsonEnd, so it can stay locked permanently. Catch the startup failure and finish the run as unavailable.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="src/components/playground/python-runtime.ts">
<violation number="1" location="src/components/playground/python-runtime.ts:68">
P2: If worker creation throws, `run()` leaves `active` set and never calls `onEnd`, so the runner stays permanently locked. Catch startup failures and finish the run as unavailable.</violation>
</file>
Reply with feedback, questions, or to request a fix.
View guided diff | Re-trigger cubic
Contributor
|
@srivibhavpadakandla Could you fix the merge conflicts? |
codewpurpose#57 landed, so this branch now builds on the redesign: - CodeBlock: the redesigned block plus the Run button (the expected overlap, resolved). - The playground and resources pages get their React Bits motion back (BlurText, SpotlightCard, GlareHover, Magnet, Koda's TypeLine). - tools.css is removed; main's globals.css already has those styles. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
samanyugoyal2010
approved these changes
Oct 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Split out of #57 (as requested) and branched off
main, so it can be reviewed and merged on its own.What's in it
Code playground —
/playgroundinput()takes answers up front (true pausing needs cross-origin isolation headers)Run buttons in lessons
.pyor "Python" labels) get a Run button that opens an editable inline runner under the block>>>), terminal and traceback blocks are excluded; the MLscaling.pyexcerpt is opted out because it can't run on its ownAI-coding resources —
/resources/ai-codingAlso
Relationship to #57
Split out of #57 and now updated on top of it (#57 is merged). The one expected overlap,
CodeBlock.tsx, is resolved: it's the redesigned block plus the Run button. The playground and resources pages use the redesign's motion components again, and the temporarytools.cssis gone sincemainhas those styles.Checks
npm run lint,typecheck,learn:checkandnext buildpass. Verified in the browser: starters including NumPy run, Run buttons appear on Python lesson blocks, and the resources page's copy buttons are styled.🤖 Generated with Claude Code