We can't find the internet
Attempting to reconnect
Something went wrong!
Hang in there while we get back on track
rails changelog
Hey there, awesome developers! We've got some exciting updates and fixes to share that will make your coding life a little bit smoother. Let's dive into the details! π
Bugfix: Fixed a pesky multibyte character tokenization bug in ERB::Util
! Now, those tricky multibyte characters won't trip up your ERB tags. We've swapped out source.string[pos, len]
for source.string.byteslice(pos, len)
to handle those sequences like a pro. Plus, we've added some nifty tests to ensure everything's working perfectly. π
Improvement: Resetting composite primary key configurations just got a whole lot smarter! When you set a primary key, any existing composite configurations will now reset properly, preventing any database drama. Your data integrity is in good hands! π
Bugfix: Silenced those confusing deprecation messages during the app:update
command. No more noise from deprecations you haven't even set up yet. Your update process just got a whole lot clearer! π
Improvement: We've updated our Rails guides to prefer the official Ruby documentation. Now you'll have the most accurate and up-to-date info at your fingertips, especially for methods like Object#tap
and Hash#fetch
. Let's keep things safe and sound! π
Bugfix: The abort_if_pending_migrations
task now uses Array#flatten!
to mutate arrays in place. No more relying on nil
return valuesβyour migration checks are now reliable and error-free! π οΈ
Improvement: We've enhanced how new records are managed with the "becomes persists previously_new_record" update. Your new entries are now stored and tracked like champs, ensuring data integrity and performance are on point. ποΈ
Keep rocking those keyboards, and happy coding! π»β¨
Included Commits
This commit addresses an issue where deprecation messages were being displayed during the app:update
command in a framework, potentially confusing users who have not yet set up their new_framework_defaults
. Since these users may not be aware of the new deprecations, the commit proposes silencing these messages to enhance clarity and reduce unnecessary noise during the update process.
By implementing this change, the commit aims to improve the user experience for those running the update command, ensuring that they are not overwhelmed by irrelevant information. This adjustment is part of a fix for issue #53558.
Files changed
This commit focuses on improving the documentation references within the Rails guides by updating links to point to the official Ruby documentation. Specifically, it modifies references for the Object#tap
method and the Hash#fetch
method to direct users to the latest Ruby documentation pages, enhancing clarity and ensuring that users access the most accurate and up-to-date information. Additionally, it emphasizes the importance of using safer methods for JSON serialization, advising against the direct replacement of MultiJson.load
with JSON.load
, and instead recommending the use of JSON.parse
.
Overall, these changes aim to provide clearer guidance to developers by steering them towards the official Ruby documentation, which is crucial for maintaining best practices and ensuring the security of their applications. The commit reflects a commitment to accuracy and safety in the Rails documentation, ultimately benefiting developers by providing them with reliable resources.
Files changed
- guides/source/2_3_release_notes.md
- guides/source/4_1_release_notes.md
- guides/source/upgrading_ruby_on_rails.md
This commit addresses a bug in the ERB::Util.tokenize
method that affected the correct handling of multibyte characters in ERB tags. Specifically, the previous implementation failed to tokenize strings properly when multibyte characters preceded ERB tags. The fix involved changing the way tokens are extracted from the source string, replacing the use of source.string[pos, len]
with source.string.byteslice(pos, len)
, which correctly handles multibyte character sequences.
In addition to the code changes, the commit also includes new tests to verify the correct functionality with multibyte characters. Two test cases were added: one to check tokenization when multibyte characters appear at the start of the string and another for when they appear at the end. These changes ensure that the tokenization process is robust against various character encodings, improving the overall reliability of the ERB::Util
module.
Files changed
- activesupport/CHANGELOG.md
- activesupport/lib/active_support/core_ext/erb/util.rb
- activesupport/test/core_ext/erb_util_test.rb
This commit addresses an issue related to the configuration of composite primary keys in the codebase. It ensures that when a primary key is set, any existing configurations for composite primary keys are properly reset to avoid conflicts or unintended behavior. This enhancement improves the reliability of the primary key setup process.
By implementing this change, the commit aims to streamline database operations and maintain data integrity, particularly in scenarios where composite primary keys are involved. Overall, the update enhances the framework's handling of primary key configurations, contributing to more robust database management.
Files changed
The commit titled "becomes persists previously_new_record" introduces a modification in the codebase, likely related to the handling of records in a database or data management system. The change suggests that the functionality for managing new records has been updated to ensure that previously new records are now persisted correctly. This could imply enhancements in the way the system tracks and saves new entries, ensuring that they are properly stored and accessible after creation.
Additionally, the commit may address issues related to data integrity or performance, although specific details on those aspects are not provided. Overall, this change aims to improve the reliability of record management within the application.
Files changed
This commit addresses an issue with the abort_if_pending_migrations
task by modifying its implementation to utilize Array#flatten!
for mutating the array in place. The previous approach incorrectly relied on the return value of flatten
, which could be nil
if the array remained unchanged, leading to potential errors in the task's execution.
By switching to Array#flatten!
, the code now effectively modifies the original array directly, ensuring that any changes are accurately reflected without the ambiguity of the return value. This change enhances the reliability of the task and ensures it functions as intended when checking for pending migrations.