aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support
Commit message (Collapse)AuthorAgeFilesLines
* Document redis: Object optionSteven Harman2019-04-181-5/+7
| | | | | | | There are four ways to pass the redis option, but only three were documented. This is now consistent with implementation. [ci skip]
* Merge pull request #36012 from r7kamura/feature/safe-buffer-multiplicationRyuta Kamizono2019-04-191-0/+6
|\ | | | | Preserve html_safe? status on ActiveSupport::SafeBuffer#*
| * Preserve html_safe? status on ActiveSupport::SafeBuffer#*r7kamura2019-04-191-0/+6
| |
* | If exception occurs during setup, add to each test executedAric Walker2019-04-181-1/+10
|/ | | | | | Resolves https://github.com/rails/rails/issues/35835 If an exception occurs during `parallelize_setup` make sure to catch that exception and apply it to the result of each successive test run. This results in marking all of the tests as failed to bring attention to the issue & ensure it is addressed before proceeding.
* Merge pull request #35052 from schuetzm/silence-i18n-fallback-deprecationKasper Timm Hansen2019-04-171-1/+2
|\ | | | | Describe how to silence the deprecation warning about empty I18n fall…
| * Describe how to silence the deprecation warning about empty I18n fallbacksMarc Schütz2019-01-251-1/+2
| |
* | Merge pull request #35886 from okuramasafumi/add-docs-to-concernRyuta Kamizono2019-04-171-1/+24
|\ \ | | | | | | Add documentations to concern methods [ci skip]
| * | Add documentations to AS::Concern#included and #class_methodsokuramasafumi2019-04-171-0/+23
| | |
| * | Add `:nodoc` to ActiveSupport::Concern#append_featuresokuramasafumi2019-04-161-1/+1
| | |
* | | Removed unused require for active_support/deprecationPrathamesh Sonpatki2019-04-171-1/+0
| | | | | | | | | | | | - Unused since https://github.com/rails/rails/commit/a91ea1d51048342d13f
* | | Merge pull request #35984 from vishaltelangre/asn-misc-fixesJeremy Daer2019-04-162-6/+5
|\ \ \ | | | | | | | | Various fixes in ActiveSupport::Notifications::Event
| * | | Remove @duration instance variable since we're not maintaining instances ↵Vishal Telangre2019-04-161-2/+1
| | | | | | | | | | | | | | | | variables such as @cpu_time, @idle_time and @allocations; this reduces one allocation
| * | | Use monotonic time to record `started` and `finished` time values for an ↵Vishal Telangre2019-04-161-2/+2
| | | | | | | | | | | | | | | | event subscribed by a `ActiveSupport::Notifications::Fanout::Subscribers::Timed` subscriber
| * | | Fix: #cpu_time doesn't work for a ↵Vishal Telangre2019-04-161-2/+2
| | | | | | | | | | | | | | | | `ActiveSupport::Notifications::Fanout::Subscribers::Timed` subscriber
* | | | running test with_info_handler methodMauri Mustonen2019-04-161-1/+3
| | | |
* | | | Find query_source_location using lazy EnumeratorJohn Hawthorn2019-04-151-1/+5
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | This way, we only need to filter the backtrace up to the first non-noise stack frame. This also updates noise to be able to deal with being passed a lazy enum. We don't need this anywhere, but it seemed better for this to be consistent.
* | | Redis fetch without names returns {}David Verhasselt2019-04-121-0/+1
| | | | | | | | | | | | | | | | | | | | | When trying to call mget in Redis without any parameters, a Redis error is thrown. To avoid this, we circumvent Redis entirely when there are no key names given.
* | | Auto-correct `Style/RedundantBegin` cop offencesRyuta Kamizono2019-04-121-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is newly added at 7b6b10542d5dac2b50f2578143dc5d70120d1146. ``` % be rubocop -a Inspecting 2781 files ...............................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................C............................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................. Offenses: activesupport/lib/active_support/dependencies/zeitwerk_integration.rb:12:1: C: [Corrected] Layout/EmptyLinesAroundBlockBody: Extra empty line detected at block body beginning. activesupport/lib/active_support/dependencies/zeitwerk_integration.rb:12:1: C: [Corrected] Layout/TrailingWhitespace: Trailing whitespace detected. activesupport/lib/active_support/dependencies/zeitwerk_integration.rb:12:13: C: [Corrected] Style/RedundantBegin: Redundant begin block detected. begin ^^^^^ activesupport/lib/active_support/dependencies/zeitwerk_integration.rb:13:11: C: [Corrected] Layout/IndentationWidth: Use 2 (not 4) spaces for indentation. Rails.autoloaders.main.reload ^^^^ activesupport/lib/active_support/dependencies/zeitwerk_integration.rb:16:1: C: [Corrected] Layout/EmptyLinesAroundBlockBody: Extra empty line detected at block body end. activesupport/lib/active_support/dependencies/zeitwerk_integration.rb:16:1: C: [Corrected] Layout/TrailingWhitespace: Trailing whitespace detected. 2781 files inspected, 6 offenses detected, 6 offenses corrected ```
* | | improves the reloading disabled error messageXavier Noria2019-04-111-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | The original message from Zeitwerk is "can't reload, please call loader.enable_reloading before setup (Zeitwerk::Error)", which is not very informative for Rails programmers. Rails should err with a message worded in terms of its interface.
* | | depend on Zeitwerk 2.1.0Xavier Noria2019-04-092-13/+11
| | |
* | | depend on Zeitwerk 2Xavier Noria2019-04-071-3/+4
|/ /
* | Merge pull request #35691 from ↵Rafael França2019-04-041-6/+55
|\ \ | | | | | | | | | | | | sushantmittal/add_deattach_from_in_active_support_subscriber Adds 'detach_from' to 'ActiveSupport::Subscriber' to detach a subscriber from a namespace.
| * | Added 'detach_from' to 'ActiveSupport::Subscriber' to detach a subscriber ↵sushant2019-04-041-6/+55
| | | | | | | | | | | | from a namespace.
* | | Merge pull request #35771 from timoschilling/hash-speed-improvementsRafael França2019-04-022-4/+7
|\ \ \ | | | | | | | | Hash / HashWithIndifferentAccess speed improvements
| * | | Speed improvement for HashWithIndifferentAccess#values_atTimo Schilling2019-04-021-2/+2
| | | |
| * | | Speed improvement for HashWithIndifferentAccess#fetch_valuesTimo Schilling2019-04-021-1/+1
| | | |
| * | | Speed improvement for HashWithIndifferentAccess#exceptTimo Schilling2019-04-011-0/+3
| | | |
| * | | Speed improvement for Hash#exceptTimo Schilling2019-03-291-1/+1
| | | |
* | | | Tweaks CHANGELOGs and docs [ci skip]Ryuta Kamizono2019-03-311-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * add leading `#` before `=>` since hash rocket is valid Ruby code * add backticks * remove trailing spaces * and more
* | | | fixes eager loading edge case in :zeitwerk modeXavier Noria2019-03-302-7/+18
|/ / /
* | | Merge pull request #34405 from shugo/safe_buffer_backref_fixMatthew Draper2019-03-281-2/+37
|\ \ \ | | | | | | | | sub, sub!, gsub, and gsub! should set back references
| * | | Eliminate a thread local variable as suggested by nobuShugo Maeda2019-02-141-8/+1
| | | |
| * | | Remove trailing spaceShugo Maeda2018-11-081-1/+1
| | | |
| * | | Add a commented code example of what will be producedShugo Maeda2018-11-081-22/+22
| | | |
| * | | sub, sub!, gsub, and gsub! should set back referencesShugo Maeda2018-11-081-2/+44
| | | |
* | | | Fix bug in Range comparisons when comparing to excluded-end RangeOwen Stephens2019-03-281-12/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before: ```ruby (1..10).cover?(1...11) => false ``` After: ```ruby (1..10).cover?(1...11) => true ``` See https://git.io/fjTtz for the commit against Ruby core that added support for Range arguments, with similar handling of this case.
* | | | Don't encode in secure_compare for speedupBart de Water2019-03-261-1/+1
| | | | | | | | | | | | | | | | Hex encoding is base 16 which makes the original input twice as big. With this change less time need to be spent in fixed_length_secure_compare.
* | | | Use weak references in descendants trackerEdgars Beigarts2019-03-261-4/+50
| | | | | | | | | | | | | | | | It allows anonymous subclasses to be garbage collected.
* | | | Update CHANGELOG and docsAli Ibrahim2019-03-221-3/+4
| | | | | | | | | | | | | | | | with change to ActiveSupport::Notifications::Instrumenter#instrument
* | | | Update AS::Notifications::Instrumenter#instrumentAli Ibrahim2019-03-221-1/+1
| | | | | | | | | | | | | | | | | | | | * Update #instrument to make passing a block optional. This will let users leverage #instrument for messaging in addition to instrumentation.
* | | | depend on Zeitwerk 1.4.0Xavier Noria2019-03-191-1/+5
| | | |
* | | | Fix Time#advance to work with dates before 1001-03-07Andrew White2019-03-181-2/+1
| |/ / |/| | | | | | | | | | | | | | | | | | | | | | | In #10634 the behavior of Time#advance was changed to maintain a proleptic gregorian calendar for dates before calendar reform. However it didn't full address dates a long time before calendar reform and they gradually drift away from the proleptic calendar the further you go back in time. Fix this by always converting the date to gregorian before calling advance which sets the reform date to -infinity.
* | | Merge pull request #35634 from sharang-d/update-parameterize-docsRyuta Kamizono2019-03-162-6/+10
|\ \ \ | | | | | | | | Update docs for 'parameterize()' [ci skip]
| * | | Update docs for 'parameterize()' [ci skip]Sharang Dashputre2019-03-162-6/+10
| | | |
* | | | Engines are reloaded in Zeitwerk mode [closes #35618]Xavier Noria2019-03-151-2/+1
|/ / /
* | | Match evented checker behavior on dir with no extsJohn Hawthorn2019-03-151-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When FileUpdateChecker is passed a directory and given an empty array of extensions to match on, it will match any extension. Previously, EventedFileUpdateChecker would never match any files when given an empty array. This commit makes it EventedFileUpdateChecker match FileUpdateChecker, and watch all extensions when given an empty array.
* | | support slice assignment on SafeBufferRichard Monette2019-03-131-2/+6
| | |
* | | Merge tag 'v6.0.0.beta3'eileencodes2019-03-131-1/+1
|\ \ \ | | | | | | | | | | | | v6.0.0.beta3 release
| * | | Prep releaseeileencodes2019-03-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Update RAILS_VERSION * Bundle * rake update_versions * rake changelog:header
* | | | Change wording of some instances of 'opt out' [ci skip]Sharang Dashputre2019-03-123-13/+13
| | | |