Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert Terminal Instructions experiment for Shell stage 1 and 2 #2540

Merged
merged 2 commits into from
Jan 16, 2025

Conversation

andy1li
Copy link
Member

@andy1li andy1li commented Jan 16, 2025

Checklist:

  • I've thoroughly self-reviewed my changes
  • I've added tests for my changes, unless they affect admin-only areas (or are otherwise not worth testing)
  • I've verified any visual changes using Percy (add a commit with [percy] in the message to trigger)

Summary by CodeRabbit

  • Removed Features

    • Removed terminal instructions and interactive elements from course stage tutorial cards
    • Eliminated feature flag for terminal instructions in stages 1 and 2
    • Simplified course stage instructions for handling invalid commands
  • Documentation

    • Updated instructional text to be more concise and direct
  • Refactor

    • Simplified user interface by removing conditional rendering of terminal instructions
    • Removed complex logic related to terminal instruction visibility

@andy1li andy1li self-assigned this Jan 16, 2025
Copy link
Contributor

coderabbitai bot commented Jan 16, 2025

Walkthrough

This pull request removes terminal-specific instructions and related feature flag logic across multiple files in the course stage components. The changes simplify the user interface by eliminating conditional rendering of terminal instructions, removing computed properties related to terminal interactions, and updating the short instructions markdown for course stages. The modifications appear to be part of a broader simplification of the terminal instruction feature.

Changes

File Change Summary
app/components/course-page/course-stage-step/first-stage-tutorial-card.hbs Removed conditional block for terminal instructions, replaced with a simple paragraph about code comments
app/components/course-page/course-stage-step/first-stage-tutorial-card.ts Deleted shouldShowTerminalInstructions and shouldShowTerminalInstructionsPinging computed properties
app/components/course-page/course-stage-step/second-stage-tutorial-card.hbs Removed conditional terminal instructions block, simplified to direct markdown rendering
app/components/course-page/course-stage-step/second-stage-tutorial-card.ts Removed similar computed properties for terminal instructions
app/models/course-stage.ts Updated shortInstructionsMarkdown getter with simplified text about handling invalid commands
app/services/feature-flags.js Removed canSeeTerminalInstructionsForStage1And2 getter method

Possibly related PRs

Poem

🐰 A Rabbit's Ode to Simplified Code

Terminal whispers, now hushed and clear,
Complexity fades, instructions sincere
No more pinging, no conditional dance
Just pure guidance in a single glance
Code simplified, with rabbit's delight! 🚀

Finishing Touches

  • 📝 Generate Docstrings (Beta)

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

Test Results

  1 files  ±0    1 suites  ±0   7m 22s ⏱️ + 1m 20s
595 tests ±0  554 ✅ ±0  41 💤 ±0  0 ❌ ±0 
610 runs  ±0  569 ✅ ±0  41 💤 ±0  0 ❌ ±0 

Results for commit ce2ce67. ± Comparison against base commit 11ac5f4.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
app/models/course-stage.ts (1)

147-147: Consider enhancing instruction clarity.

While the simplified instructions are good, we could make them even clearer by specifying that students need to match the exact error message format.

Consider updating the instructions to:

-In this stage, you'll handle invalid commands in your shell. For now, treat all commands as invalid.
+In this stage, you'll handle invalid commands in your shell. For now, treat all commands as invalid and ensure you match the exact error message format shown below:
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 11ac5f4 and ce2ce67.

📒 Files selected for processing (6)
  • app/components/course-page/course-stage-step/first-stage-tutorial-card.hbs (1 hunks)
  • app/components/course-page/course-stage-step/first-stage-tutorial-card.ts (0 hunks)
  • app/components/course-page/course-stage-step/second-stage-tutorial-card.hbs (1 hunks)
  • app/components/course-page/course-stage-step/second-stage-tutorial-card.ts (0 hunks)
  • app/models/course-stage.ts (1 hunks)
  • app/services/feature-flags.js (0 hunks)
💤 Files with no reviewable changes (3)
  • app/components/course-page/course-stage-step/first-stage-tutorial-card.ts
  • app/services/feature-flags.js
  • app/components/course-page/course-stage-step/second-stage-tutorial-card.ts
🔇 Additional comments (2)
app/components/course-page/course-stage-step/second-stage-tutorial-card.hbs (1)

5-7: Clean implementation of simplified instructions rendering!

The changes effectively streamline the UI by removing the experimental terminal instructions while maintaining the core functionality. The simplified markup properly handles both shell and non-shell course instructions.

app/components/course-page/course-stage-step/first-stage-tutorial-card.hbs (1)

4-7: LGTM! Instructions are now clearer and more straightforward.

The simplified instructions provide a clearer direction to users without the experimental terminal-specific content, which aligns well with the PR's revert objective.

Let's verify that all related terminal instruction code has been properly removed:

@andy1li andy1li merged commit 1e83a81 into main Jan 16, 2025
7 checks passed
@andy1li andy1li deleted the revert-2521-experiment branch January 16, 2025 12:59
Copy link

codecov bot commented Jan 16, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

✅ All tests successful. No failed tests found.

Additional details and impacted files

📢 Thoughts on this report? Let us know!

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