♊️ GemiNews 🗞️ (dev)

Demo 1: Embeddings + Recommendation Demo 2: Bella RAGa Demo 3: NewRetriever Demo 4: Assistant function calling

🗞️Active Record Basics Guide Refresh, Encrypted Attributes Re-Optimization, and more…

🗿Semantically Similar Articles (by :title_embedding)

Active Record Basics Guide Refresh, Encrypted Attributes Re-Optimization, and more…

2024-03-15 - zzak (from Ruby on Rails)

Hi, it’s zzak. Let’s explore this week’s changes in the Rails codebase.

Hi, it’s zzak. Let’s explore this week’s changes in the Rails codebase. The Rails World CFP will close in just one week on March 21. Submit your talk in time! Active Record Basics Guide This PR refreshes the guide covering the basics of Active Record. Do not try to alias on key update when raw SQL is supplied A bug was found when updating duplicates with raw SQL. Memoize “key_provider” from “key” or deterministic “key_provider” if any Previously, this memoization was removed which lead to a performance hit for encrypted attributes. Updating Astana with a Western Kazakhstan timezone On March 1, 2024, Kazakhstan (all parts) switched to a single time zone UTC+5. Using the latest tzinfo-data that updated the Kazakhstan timezones, ActiveSupport still showed the incorrect offset because it was pointing to the Asia/Dhaka Bangladesh timezone, which will not get the same TZ offset change. Preserve encoding on “truncate_bytes” This PR addressed an issue where String#truncate_bytes can return a string with a different encoding than the one being truncated. Support custom blob key in ActiveStorage::Blob.compose Since Rails 6.1, Active Storage has allowed to provide a custom key when attaching a new file. This PR adds support when using the compose class method to customize the name of the underlying service object. Fix MySQL adapter for inserts with aliases This pull request addresses errors that occur when using MySQL 8.0.18 or lower version of MySQL 8.0. Railties configure sanitizer vendor in 7.1 defaults more robustly In order to avoid an issue where Rails::HTML::Sanitizer is not yet loaded, which resulted in the sanitizer vendor remaining as Rails::HTML4 and not be set to Rails::HTML5 as intended in Rails 7.1. You can view the whole list of changes here. We had 20 contributors to the Rails codebase this past week! Until next time! Subscribe to get these updates mailed to you.

[Technology] 🌎 https://rubyonrails.org/2024/3/15/this-week-in-rails [🧠] [v2] article_embedding_description: {:llm_project_id=>"Unavailable", :llm_dimensions=>nil, :article_size=>3625, :llm_embeddings_model_name=>"textembedding-gecko"}
[🧠] [v1/3] title_embedding_description: {:ricc_notes=>"[embed-v3] Fixed on 9oct24. Only seems incompatible at first glance with embed v1.", :llm_project_id=>"unavailable possibly not using Vertex", :llm_dimensions=>nil, :article_size=>3625, :poly_field=>"title", :llm_embeddings_model_name=>"textembedding-gecko"}
[🧠] [v1/3] summary_embedding_description: {:ricc_notes=>"[embed-v3] Fixed on 9oct24. Only seems incompatible at first glance with embed v1.", :llm_project_id=>"unavailable possibly not using Vertex", :llm_dimensions=>nil, :article_size=>3625, :poly_field=>"summary", :llm_embeddings_model_name=>"textembedding-gecko"}
[🧠] As per bug https://github.com/palladius/gemini-news-crawler/issues/4 we can state this article belongs to titile/summary version: v3 (very few articles updated on 9oct24)

🗿article.to_s

------------------------------
Title: Active Record Basics Guide Refresh, Encrypted Attributes Re-Optimization, and more…
Summary: Hi, it’s zzak. Let’s explore this week’s changes in the Rails codebase.

[content]
Hi, it’s zzak. Let’s explore this week’s changes in the Rails codebase.

The Rails World CFP will close in just one week on March 21.
Submit your talk in time!

Active Record Basics Guide
This PR refreshes the guide covering the basics of Active Record.

Do not try to alias on key update when raw SQL is supplied
A bug was found when updating duplicates with raw SQL.

Memoize “key_provider” from “key” or deterministic “key_provider” if any
Previously, this memoization was removed which lead to a performance hit for encrypted attributes.

Updating Astana with a Western Kazakhstan timezone
On March 1, 2024, Kazakhstan (all parts) switched to a single time zone UTC+5.
Using the latest tzinfo-data that updated the Kazakhstan timezones, ActiveSupport still showed the incorrect offset because it was pointing to the Asia/Dhaka Bangladesh timezone, which will not get the same TZ offset change.

Preserve encoding on “truncate_bytes”
This PR addressed an issue where String#truncate_bytes can return a string with a different encoding than the one being truncated.

Support custom blob key in ActiveStorage::Blob.compose
Since Rails 6.1, Active Storage has allowed to provide a custom key when attaching a new file.
This PR adds support when using the compose class method to customize the name of the underlying service object.

Fix MySQL adapter for inserts with aliases
This pull request addresses errors that occur when using MySQL 8.0.18 or lower version of MySQL 8.0.

Railties configure sanitizer vendor in 7.1 defaults more robustly
In order to avoid an issue where Rails::HTML::Sanitizer is not yet loaded, which resulted in the sanitizer vendor remaining as Rails::HTML4 and not be set to Rails::HTML5 as intended in Rails 7.1.

You can view the whole list of changes here.
We had 20 contributors to the Rails codebase this past week!

Until next time!

Subscribe to get these updates mailed to you.
[/content]

Author: zzak
PublishedDate: 2024-03-15
Category: Technology
NewsPaper: Ruby on Rails
Tags: news
{"id"=>4268,
"title"=>"Active Record Basics Guide Refresh, Encrypted Attributes Re-Optimization, and more…",
"summary"=>"Hi, it’s zzak. Let’s explore this week’s changes in the Rails codebase.",
"content"=>"

Hi, it’s zzak. Let’s explore this week’s changes in the Rails codebase.

\n\n

The Rails World CFP will close in just one week on March 21.
\nSubmit your talk in time!

\n\n

Active Record Basics Guide
\nThis PR refreshes the guide covering the basics of Active Record.

\n\n

Do not try to alias on key update when raw SQL is supplied
\nA bug was found when updating duplicates with raw SQL.

\n\n

Memoize “key_provider” from “key” or deterministic “key_provider” if any
\nPreviously, this memoization was removed which lead to a performance hit for encrypted attributes.

\n\n

Updating Astana with a Western Kazakhstan timezone
\nOn March 1, 2024, Kazakhstan (all parts) switched to a single time zone UTC+5.
\nUsing the latest tzinfo-data that updated the Kazakhstan timezones, ActiveSupport still showed the incorrect offset because it was pointing to the Asia/Dhaka Bangladesh timezone, which will not get the same TZ offset change.

\n\n

Preserve encoding on “truncate_bytes”
\nThis PR addressed an issue where String#truncate_bytes can return a string with a different encoding than the one being truncated.

\n\n

Support custom blob key in ActiveStorage::Blob.compose
\nSince Rails 6.1, Active Storage has allowed to provide a custom key when attaching a new file.
\nThis PR adds support when using the compose class method to customize the name of the underlying service object.

\n\n

Fix MySQL adapter for inserts with aliases
\nThis pull request addresses errors that occur when using MySQL 8.0.18 or lower version of MySQL 8.0.

\n\n

Railties configure sanitizer vendor in 7.1 defaults more robustly
\nIn order to avoid an issue where Rails::HTML::Sanitizer is not yet loaded, which resulted in the sanitizer vendor remaining as Rails::HTML4 and not be set to Rails::HTML5 as intended in Rails 7.1.

\n\n

You can view the whole list of changes here.\nWe had 20 contributors to the Rails codebase this past week!

\n\n

Until next time!

\n\n

Subscribe to get these updates mailed to you.

",
"author"=>"zzak",
"link"=>"https://rubyonrails.org/2024/3/15/this-week-in-rails",
"published_date"=>Fri, 15 Mar 2024 00:00:00.000000000 UTC +00:00,
"image_url"=>nil,
"feed_url"=>"https://rubyonrails.org/2024/3/15/this-week-in-rails",
"language"=>nil,
"active"=>true,
"ricc_source"=>"feedjira::v1",
"created_at"=>Mon, 01 Apr 2024 20:13:49.533542000 UTC +00:00,
"updated_at"=>Mon, 21 Oct 2024 18:04:04.265696000 UTC +00:00,
"newspaper"=>"Ruby on Rails",
"macro_region"=>"Technology"}
Edit this article
Back to articles