- 24 3月, 2018 1 次提交
-
-
由 Andrew White 提交于
Add custom prefix to ActiveRecord::Store accessors
-
- 23 3月, 2018 6 次提交
-
-
由 Ryuta Kamizono 提交于
The multiple assignments was caused by 37a1dfad due to lost the `to_s` normalization for given names. Fixes #32323.
-
由 Tan Huynh 提交于
Add a prefix option to ActiveRecord::Store.store_accessor and ActiveRecord::Store.store. This option allows stores to have identical keys with different accessors.
-
由 Rafael França 提交于
Fix Cache `read_multi` with local_cache bug, should returns raw value, not `ActiveSupport::Cache::Entry` instance.
-
由 Rafael França 提交于
Use ASCII-8BIT paths in ActionDispatch::Static
-
由 Rafael Mendonça França 提交于
-
由 Rafael França 提交于
Ruby 2.6 will not require monkey patched `URI#unescape`
-
- 22 3月, 2018 10 次提交
-
-
由 Yasuo Honda 提交于
since revision 62897 https://github.com/ruby/ruby/commit/234a30459cdae6aa7da6e28a1082d9c11f315696
-
由 Andrew White 提交于
The rack gem returns PATH_INFO as an ASCII-8BIT encoded string but it was being converted to US-ASCII by the match? method because it was calling Rack::Utils.escape_path. To prevent incompatibile encoding warnings use ASCII-8BIT strings for the root path and let Ruby handle any filename encoding conversion. Fixes #32294, Closes #32314.
-
由 Ryuta Kamizono 提交于
[ci skip] Update Action Mailer Documentation
-
由 Kasper Timm Hansen 提交于
-
由 Ryuta Kamizono 提交于
Somehow `test_config_another_database` didn't fail on CI, but it will fail locally. https://travis-ci.org/rails/rails/jobs/356212950#L2474-L2482 ``` % bundle exec ruby -w -Itest test/generators/app_generator_test.rb -n test_config_another_database Run options: -n test_config_another_database --seed 7260 # Running: F Failure: AppGeneratorTest#test_config_another_database [test/generators/app_generator_test.rb:417]: Expected /^\s*gem\s+["']mysql2["'], '~> 0.4.4'$*/ to match "source 'https://rubygems.org'\ngit_source(:github) { |repo| \"https://github.com/\#{repo}.git\" }\n\nruby '2.5.0'\n\n# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'\ngem 'rails', '~> 6.0.0.alpha'\n# Use mysql as the database for Active Record\ngem 'mysql2', '>= 0.4.4', '< 0.6.0'\n# Use Puma as the app server\ngem 'puma', '~> 3.11'\n# Use SCSS for stylesheets\ngem 'sass-rails', '~> 5.0'\n# Use Uglifier as compressor for JavaScript assets\ngem 'uglifier', '>= 1.3.0'\n# See https://github.com/rails/execjs#readme for more supported runtimes\n# gem 'mini_racer', platforms: :ruby\n\n# Use CoffeeScript for .coffee assets and views\ngem 'coffee-rails', '~> 4.2'\n# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks\ngem 'turbolinks', '~> 5'\n# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder\ngem 'jbuilder', '~> 2.5'\n# Use Redis adapter to run Action Cable in production\n# gem 'redis', '~> 4.0'\n# Use ActiveModel has_secure_password\n# gem 'bcrypt', '~> 3.1.7'\n\n# Use ActiveStorage variant\n# gem 'mini_magick', '~> 4.8'\n\n# Use Capistrano for deployment\n# gem 'capistrano-rails', group: :development\n\n# Reduces boot times through caching; required in config/boot.rb\ngem 'bootsnap', '>= 1.1.0', require: false\n\ngroup :development, :test do\n # Call 'byebug' anywhere in the code to stop execution and get a debugger console\n gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]\nend\n\ngroup :development do\n # Access an interactive console on exception pages or by calling 'console' anywhere in the code.\n gem 'web-console', '>= 3.3.0'\n gem 'listen', '>= 3.0.5', '< 3.2'\n # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring\n gem 'spring'\n gem 'spring-watcher-listen', '~> 2.0.0'\nend\n\ngroup :test do\n # Adds support for Capybara system testing and selenium driver\n gem 'capybara', '>= 2.15', '< 4.0'\n gem 'selenium-webdriver'\n # Easy installation and use of chromedriver to run system tests with Chrome\n gem 'chromedriver-helper'\nend\n\n# Windows does not include zoneinfo files, so bundle the tzinfo-data gem\ngem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]\n". bin/rails test test/generators/app_generator_test.rb:411 Finished in 0.174681s, 5.7247 runs/s, 34.3483 assertions/s. 1 runs, 6 assertions, 1 failures, 0 errors, 0 skips ```
-
由 Ryuta Kamizono 提交于
It makes to ease to detect a future regression as long as the methods are covered by this test.
-
由 Ryuta Kamizono 提交于
Use PredicateBuilder for bind params in Relation::Batches
-
由 Ryuta Kamizono 提交于
Add cancellation info to before filter docs [ci skip]
-
由 Ryuta Kamizono 提交于
Support mysql2 0.4.x and 0.5.x
-
由 Andrew White 提交于
See flavorjones/loofah#144
-
- 21 3月, 2018 4 次提交
-
-
由 Eileen M. Uchitelle 提交于
Fix system tests transactions not closed between examples
-
由 Andrew White 提交于
The urls helpers module returned by Rails.application.routes.url_helpers isn't cached so to prevent the cost of building the module cache it locally.
-
由 Aaron Stone 提交于
-
由 Jason Lee 提交于
It should returns raw value, not instance of `ActiveSupport::Cache::Entry`.
-
- 20 3月, 2018 10 次提交
-
-
由 Rafael Mendonça França 提交于
-
由 Andrew White 提交于
Memoize the result of gsubbing @virtual_path
-
由 Dillon Welch 提交于
This gets called many times for each virtual_path, creating a new string each time that `translate` is called. We can memoize this so that it only happens once per virtual_path instead.
-
由 Andrew White 提交于
Interpolate '' instead of nil when multiple is false.
-
由 Dillon Welch 提交于
"my string #{nil}" results in an additional '' string allocation, I'm guessing because the nil has to be converted to a string. "my string #{'[]' if multiple}" results in "my string #{nil}" if multiple is false. Doing "my string #{''}" does not result in an extra string allocation. I moved the if multiple logic into a method so I only had to make the change once. ```ruby begin require "bundler/inline" rescue LoadError => e $stderr.puts "Bundler version 1.10 or later is required. Please update your Bundler" raise e end gemfile(true) do source "https://rubygems.org" gem "benchmark-ips" gem "rails" end def allocate_count GC.disable before = ObjectSpace.count_objects yield after = ObjectSpace.count_objects after.each { |k,v| after[k] = v - before[k] } after[:T_HASH] -= 1 # probe effect - we created the before hash. GC.enable result = after.reject { |k,v| v == 0 } GC.start result end @html_options = {} def master_version(multiple=nil) "hi#{"[]" if multiple}" end def fast_version(multiple=nil) str = multiple ? "[]" : '' "hi#{str}" end def test puts "master_version" puts allocate_count { 1000.times { master_version } } puts "master_version with arg" puts allocate_count { 1000.times { master_version(' there') } } puts "fast_version" puts allocate_count { 1000.times { fast_version } } puts "fast_version with arg" puts allocate_count { 1000.times { fast_version(' there') } } Benchmark.ips do |x| x.report("master_version") { master_version } x.report("master_version with arg") { master_version(' there') } x.report("fast_version") { fast_version } x.report("fast_version with arg") { fast_version(' there') } x.compare! end end test ``` results: ```ruby master_version {:FREE=>-1981, :T_STRING=>2052} master_version with arg {:FREE=>-1001, :T_STRING=>1000} fast_version {:FREE=>-1001, :T_STRING=>1000} fast_version with arg {:FREE=>-1001, :T_STRING=>1000} Warming up -------------------------------------- master_version 138.851k i/100ms master_version with arg 164.029k i/100ms fast_version 165.737k i/100ms fast_version with arg 167.016k i/100ms Calculating ------------------------------------- master_version 2.464M (±14.7%) i/s - 11.941M in 5.023307s master_version with arg 3.754M (± 8.5%) i/s - 18.699M in 5.021354s fast_version 3.449M (±11.7%) i/s - 17.071M in 5.033312s fast_version with arg 3.636M (± 6.9%) i/s - 18.205M in 5.034792s Comparison: master_version with arg: 3753896.1 i/s fast_version with arg: 3636094.5 i/s - same-ish: difference falls within error fast_version: 3448766.2 i/s - same-ish: difference falls within error master_version: 2463857.3 i/s - 1.52x slower ```
-
由 Javan Makhmali 提交于
Fix digesting templates with mixed formats
-
由 Javan Makhmali 提交于
-
由 Rafael França 提交于
ActiveJob: Remove support for Qu gem.
-
由 Alberto Almagro 提交于
Reasons are that the Qu gem wasn't compatible since Rails 5.1, gem development was stopped in 2014 and maintainers have confirmed its demise. See issue #32273
-
由 Jeremy Green 提交于
-
- 19 3月, 2018 9 次提交
-
-
由 Andrew White 提交于
-
由 Brian Knight 提交于
If an explicit AWS key pair and/or region is not provided in config/storage.yml, attempt to use environment variables, shared credentials, or IAM role credentials. Order of precedence is determined by the AWS SDK[1]. [1]: https://docs.aws.amazon.com/sdk-for-ruby/v3/developer-guide/setup-config.html
-
由 Sergey Tarasov 提交于
-
由 Eileen M. Uchitelle 提交于
Add MySQL JSON reference to ActiveRecord::Store documentation
-
由 Eileen M. Uchitelle 提交于
Move CSP info from 5.2 release notes to guide [ci skip]
-
由 Andrew White 提交于
Fix failing `QuotingTest#test_quoted_time_utc`
-
由 bogdanvlviv 提交于
This test fails in specific time. Example: If run this test on the machine with time 01:00 am UTC+2, this test will fail. Changing representing of 2000-01-01 01:00 am UTC+2 to UTC+0 change the day, month and even year in our case, so substitution `"2000-01-01 "` to `""` isn't possible. ``` Failure: ActiveRecord::ConnectionAdapters::QuotingTest#test_quoted_time_utc Expected: "1999-12-31 23:01:27" Actual: "23:01:27" ``` Related to 7c479cbf
-
由 yuuji.yaginuma 提交于
-
由 bogdanvlviv 提交于
- Add mention about "nonce". Related to https://github.com/rails/rails/pull/32222#issuecomment-372268157
-