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

TEMP branch - I will close this branch 2 #608

Closed
wants to merge 11 commits into from

Conversation

rameziophobia
Copy link
Contributor

@rameziophobia rameziophobia commented Dec 16, 2024

This change is Reviewable

Summary by CodeRabbit

Release Notes

  • New Features

    • Introduced new HTML error pages for 400, 404, 406, 422, and 500 errors, enhancing user experience with modern designs.
    • Added a new script for RuboCop execution with explicit configuration.
  • Bug Fixes

    • Enhanced comment handling in the comments controller to refresh the comment list upon resetting inputs.
  • Configuration Updates

    • Upgraded Rails and associated gems to their latest versions, including PostgreSQL adapter.
    • Updated development and production environment configurations for improved performance and error handling.
  • Tests

    • Refactored RSpec tests for improved readability and consistency in syntax.

it's recommended to upgrade to the next major version instead of jumping directly to v8.0
…lly refreshing the page.

Fixes spec/stimulus/turbo_spec.rb:42 failing in CI.
The Turbo spec was failing because new comments weren't appearing immediately after submission.
Added page reload after successful comment creation to ensure comment appears without manual refresh.
…mezone rather than offset of the receiver in Rails 8.1."

Configure Rails to use full timezone preservation instead of offset, adopting the upcoming Rails 8.1 default behavior early.
This also fixes the CI Lint test failed first time
Copy link

coderabbitai bot commented Dec 16, 2024

Caution

Review failed

The pull request is closed.

Walkthrough

This pull request introduces a comprehensive upgrade to a Rails application, transitioning from Rails 7.1 to Rails 8.0. The changes span multiple configuration files, system scripts, and test specifications. Key modifications include switching the database from SQLite to PostgreSQL, updating gem versions, enhancing development and production environment configurations, and modernizing error pages and system scripts. The upgrade involves adjusting various framework defaults, improving logging, security settings, and overall application structure.

Changes

File/Directory Change Summary
Gemfile Upgraded Rails from 7.1 to 8.0, updated Redis, RuboCop, and RuboCop-RSpec versions
config/database.yml Migrated from SQLite to PostgreSQL
config/application.rb Updated Rails version to 8.0, added new autoload configurations
config/environments/* Enhanced development, test, and production environment settings
bin/* Simplified and updated various system scripts
public/* Redesigned error pages (400, 404, 422, 500) with modern styling
spec/* Updated test specifications to use modern RSpec syntax

Poem

🐰 Hop, skip, and a Rails upgrade leap!
From version seven to eight, we creep
PostgreSQL dancing, configs so bright
Error pages gleaming with pixel delight
A bunny's code journey, smooth and fleet! 🚀

Tip

CodeRabbit's docstrings feature is now available as part of our Early Access Program! Simply use the command @coderabbitai generate docstrings to have CodeRabbit automatically generate docstrings for your pull request.


📜 Recent review details

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

📥 Commits

Reviewing files that changed from the base of the PR and between 3e1f722 and a76a1fe.

⛔ Files ignored due to path filters (3)
  • Gemfile.lock is excluded by !**/*.lock
  • public/icon.png is excluded by !**/*.png
  • public/icon.svg is excluded by !**/*.svg
📒 Files selected for processing (38)
  • Gemfile (3 hunks)
  • app/controllers/pages_controller.rb (1 hunks)
  • bin/dev (1 hunks)
  • bin/rails (1 hunks)
  • bin/rubocop (1 hunks)
  • bin/setup (1 hunks)
  • bin/thrust (1 hunks)
  • client/app/controllers/comments_controller.js (1 hunks)
  • config/application.rb (1 hunks)
  • config/database.yml (0 hunks)
  • config/environments/development.rb (1 hunks)
  • config/environments/production.rb (1 hunks)
  • config/environments/test.rb (1 hunks)
  • config/initializers/application_controller_renderer.rb (1 hunks)
  • config/initializers/assets.rb (0 hunks)
  • config/initializers/content_security_policy.rb (2 hunks)
  • config/initializers/cors.rb (1 hunks)
  • config/initializers/filter_parameter_logging.rb (1 hunks)
  • config/initializers/inflections.rb (1 hunks)
  • config/initializers/mime_types.rb (1 hunks)
  • config/initializers/new_framework_defaults_7_0.rb (1 hunks)
  • config/initializers/new_framework_defaults_7_2.rb (1 hunks)
  • config/initializers/new_framework_defaults_8_0.rb (1 hunks)
  • config/initializers/permissions_policy.rb (1 hunks)
  • config/puma.rb (1 hunks)
  • db/schema.rb (1 hunks)
  • lib/tasks/ci.rake (3 hunks)
  • public/400.html (1 hunks)
  • public/404.html (1 hunks)
  • public/406-unsupported-browser.html (1 hunks)
  • public/422.html (1 hunks)
  • public/500.html (1 hunks)
  • public/robots.txt (1 hunks)
  • spec/rails_helper.rb (1 hunks)
  • spec/rescript/rescript_spec.rb (1 hunks)
  • spec/stimulus/turbo_spec.rb (1 hunks)
  • spec/system/destroy_comment_spec.rb (1 hunks)
  • spec/system/edit_comment_spec.rb (2 hunks)

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

Hi 👋 To deploy a review app, please comment /deploy-review-app

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.

2 participants