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

Add frozen string literal magic comment (potential breaking change) #933

Merged
merged 1 commit into from
Aug 26, 2024

Conversation

tagliala
Copy link
Contributor

@tagliala tagliala commented Aug 26, 2024

This cop was disabled probably by mistake, since it is present in both
Arbre and Active Admin gems

The only production code affected is:

  • app/controllers/inherited_resources/base.rb
  • lib/inherited_resources/version.rb

Change to version.rb is safe.

After inspecting the source code of InheritedResources module, the
change seems safe, but it can represent a breaking change in third-party application.

Since we are bumping the major version number, it would be fine to break
if documented.

Fixed with rubocop -A

Also adds Style/Encoding cop for parity with Arbre

@tagliala tagliala force-pushed the chore/frozen-string-literals branch 4 times, most recently from bfc7227 to 7fccb80 Compare August 26, 2024 16:52
This cop was disabled probably by mistake, since it is present in both
Arbre and Active Admin gems

The only production code affected is:
- app/controllers/inherited_resources/base.rb
- lib/inherited_resources/version.rb

Change to `version.rb` is safe.

After inspecting the source code of `InheritedResources` module, the
change seems safe, but it can represent a breaking change in third-party application.

Since we are bumping the major version number, it would be fine to break
if documented.

Fixed with `rubocop -A`

Also adds `Style/Encoding` cop for parity with Arbre
@tagliala tagliala force-pushed the chore/frozen-string-literals branch from 7fccb80 to cb1bc19 Compare August 26, 2024 16:52
Copy link

codecov bot commented Aug 26, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.92%. Comparing base (fdc9a9c) to head (cb1bc19).
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #933   +/-   ##
=======================================
  Coverage   98.92%   98.92%           
=======================================
  Files          14       14           
  Lines         557      557           
=======================================
  Hits          551      551           
  Misses          6        6           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@tagliala tagliala changed the title Add frozen string literal magic comment Add frozen string literal magic comment (potential breaking change) Aug 26, 2024
@javierjulio javierjulio self-requested a review August 26, 2024 20:06
Copy link
Member

@javierjulio javierjulio left a comment

Choose a reason for hiding this comment

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

Thanks!

@tagliala tagliala merged commit d31573f into activeadmin:master Aug 26, 2024
21 checks passed
@tagliala tagliala deleted the chore/frozen-string-literals branch August 26, 2024 20:10
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