Commit Graph

69831 Commits

Author SHA1 Message Date
Kevin Deisz
7c9751d7fe
Permit list usage cleanup and clearer documentation 2018-08-27 09:51:46 -04:00
Kevin Deisz
0efecd913c
Convert remaining usage of whitelist and blacklist 2018-08-24 16:16:41 -04:00
Kevin Deisz
cac2bb7f44
Deprecate usage of ActionView::Template::Handlers::ERB::escape_whitelist 2018-08-24 16:13:57 -04:00
Kevin Deisz
1b98de8030
Convert over the rest of the blacklist references 2018-08-24 16:11:29 -04:00
Kevin Deisz
c14859513a
Convert over the rest of the whitelist references 2018-08-24 16:10:17 -04:00
George Claghorn
e2d8a2ccfd
Merge pull request #33714 from cbothner/azure-service-swallowing-all-errors
Handle only specifically relevant Azure HTTPErrors ActiveStorage::Service::AzureStorageService#upload and #delete
2018-08-24 06:02:57 -04:00
Cameron Bothner
aae56c3529 Handle only specifically relevant Azure HTTPErrors
The Azure gem uses `Azure::Core::Http::HTTPError` for everything:
checksum mismatch, missing object, network unavailable, and many more.
(https://www.rubydoc.info/github/yaxia/azure-storage-ruby/Azure/Core/Http/HTTPError).
Rescuing that class obscures all sorts of  configuration errors. We
should check the type of error in those rescue  blocks, and reraise when
needed.
2018-08-23 23:36:43 -04:00
George Claghorn
3868648cae Revert "Merge pull request #33667 from cbothner/azure-service-swallowing-all-errors"
This reverts commit b204d167c5cfebd59f771d406178e371811ac43a, reversing
changes made to de6a200f82a3de399fa685d583503bc88dbc5e9f.
2018-08-23 19:07:29 -04:00
George Claghorn
b204d167c5
Merge pull request #33667 from cbothner/azure-service-swallowing-all-errors
Handle only specifically relevant Azure HTTPErrors in ActiveStorage::Service::AzureStorageService
2018-08-23 18:42:20 -04:00
Cameron Bothner
6acf2fa363 Handle only specifically relevant Azure HTTPErrors
The Azure gem uses `Azure::Core::Http::HTTPError` for everything:
checksum mismatch, missing object, network unavailable, and many more.
(https://www.rubydoc.info/github/yaxia/azure-storage-ruby/Azure/Core/Http/HTTPError).
Rescuing that class obscures all sorts of  configuration errors. We
should check the type of error in those rescue  blocks, and reraise when
needed.
2018-08-23 17:54:35 -04:00
Aaron Patterson
de6a200f82
Merge pull request #33681 from minaslater/replace-white-and-blacklist
[ci skip] change all instances of blacklist and whitelist to denylist…
2018-08-23 13:20:22 -07:00
Matthew Draper
1f05cc58d5
Merge pull request #31696 from BrentWheeldon/bmw-connection-pool-load-deadlock
Prevent deadlocks when waiting for connection from pool.
2018-08-24 01:42:22 +09:30
George Claghorn
a0b57bbb21
Merge pull request #33703 from bogdanvlviv/follow-up-33659
Follow up #33659
2018-08-23 09:34:27 -04:00
Ryuta Kamizono
4b4207af2f Fix typo s/Topic/Tag/
`Topic` isn't loaded in this test file.
2018-08-23 21:24:35 +09:00
Matthew Draper
8f92a72cb3
Merge pull request #33704 from matthewd/helper-path-with-size
Use string lengths instead of regexp to extract path
2018-08-23 20:56:57 +09:30
Matthew Draper
eb68fec314 Use string lengths instead of regexp to extract path
The regexp was introduced in 186ac4cdaa911a9af659a29f2179a19b99dea13b,
and looks cosmetic. While they should be functionally identical in
theory, in practice, case insensitive (but preserving) filesystems can
give results that are differently-cased from the pattern we supplied.

I don't know how to force the filesystem to do the surprising thing,
even when running in an environment that _could_, so no new test.
2018-08-23 20:01:30 +09:30
Matthew Draper
123fe0c9ac
Merge pull request #32647 from eugeneius/lazy_transactions
Omit BEGIN/COMMIT statements for empty transactions
2018-08-23 19:40:04 +09:30
bogdanvlviv
86e7de7968
DRY in assert_broadcasts
Test `assert_no_broadcasts` failure
2018-08-23 12:39:03 +03:00
bogdanvlviv
d2ccf0c6f7
Simplify configuring of ActionCable.server.config.logger for actioncable tests
See `git grep "= Logger.new(nil)"`
2018-08-23 12:36:19 +03:00
bogdanvlviv
1055d14127
Set the test adapter for the test environment by default in config/cable.yml 2018-08-23 12:33:02 +03:00
bogdanvlviv
0e42d3db59
Clarify api docs of ActionCable::SubscriptionAdapter::Test
Remove extra `:nodoc:` comment since private methods doesn't require that.
2018-08-23 12:30:16 +03:00
Kasper Timm Hansen
2a321bff40
Merge pull request #33696 from bogdanvlviv/follow-up-44007c070
Use `say`/`error` instead of `puts`/`$stderr.puts`
2018-08-23 11:02:15 +02:00
George Claghorn
dc001dbd58
Merge pull request #33666 from cbothner/fail-gracefully-from-activestorage-file-not-found
Fail more gracefully from ActiveStorage missing file exceptions
2018-08-22 22:56:10 -04:00
Mina Slater
f1d647aeff [ci skip] corrects more grammar awkwardness, replacing denylist with restricted list and consistently use permitted 2018-08-22 21:52:17 -05:00
Nick Schwaderer
cdee52079c Include form_with in form_helpers rails guide (#33523)
* Include form_with in form_helpers rails guide

* Include form_tag and form_for footnote

* Id and class attributes are not wrapped anymore

* Include note that all form_with forms are remote:true by default

* Underline most common use case of form_with is with arguments

* Form_with no longer accepts multiple hashes in form helper calls

* Review final sections

* Revert extra documentation

* Remove unnecessary link
2018-08-22 17:42:28 -07:00
Rafael França
022a47ce15
Merge pull request #33698 from bogdanvlviv/follow-up-33693
Remove extra execution of `uniq!` on action_methods
2018-08-22 17:06:13 -05:00
Rafael França
c97faea18c
Merge pull request #33695 from peterzhu2118/master
Update ParameterFilter to yield original parameters
2018-08-22 16:08:50 -05:00
bogdanvlviv
4800a613c0
Remove extra execution of uniq! on action_methods
Execution of `to_set` below should remove duplicated elements.

Follow up #33693
2018-08-22 23:48:00 +03:00
Richard Schneeman
17978719e4
Merge pull request #33693 from schneems/schneems/action_methods
Two fewer array allocations on action_methods
2018-08-22 13:16:08 -07:00
Rafael França
9963c2a008
Merge pull request #33697 from bogdanvlviv/rails-command-help-show-description
Fix `rails initializers --help` and `rails dev:cache --help`
2018-08-22 15:05:56 -05:00
Peter Zhu
ce6166f307 Update ParameterFilter to yield original parameters 2018-08-22 15:54:26 -04:00
bogdanvlviv
cffb9bc1f6
Use say/error instead of puts/$stderr.puts
Follow up 44007c07098a3c633180881cae9285da4622e63f
2018-08-22 22:39:03 +03:00
bogdanvlviv
7bd29b506c
Fix rails initializers --help and rails dev:cache --help
- `rails initializers --help` should show description set by `desc`
  See railties/lib/rails/command/base.rb:27

- Fix `rails dev:cache --help`

 ```
 Traceback (most recent call last):
         10: from bin/rails:4:in `<main>'
          9: from bin/rails:4:in `require'
          8: from /work/rails/railties/lib/rails/commands.rb:18:in `<top (required)>'
          7: from /work/rails/railties/lib/rails/command.rb:46:in `invoke'
          6: from /work/rails/railties/lib/rails/command/base.rb:65:in `perform'
          5: from /home/vagrant/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/thor-0.20.0/lib/thor.rb:387:in `dispatch'
          4: from /home/vagrant/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/thor-0.20.0/lib/thor/invocation.rb:126:in `invoke_command'
          3: from /home/vagrant/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/thor-0.20.0/lib/thor/command.rb:27:in `run'
          2: from /work/rails/railties/lib/rails/command/base.rb:150:in `help'
          1: from /home/vagrant/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/thor-0.20.0/lib/thor.rb:170:in `command_help'
 /home/vagrant/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/thor-0.20.0/lib/thor/base.rb:497:in `handle_no_command_error': Could not find command "dev". (Thor::UndefinedCommandError)
  ```

Context https://github.com/rails/rails/pull/33694#issuecomment-415127304

Would be great to set a description to other commands.
2018-08-22 22:36:25 +03:00
Rafael França
541b78a71f
Merge pull request #33685 from krusty3002/master
Added explanation about new_framework_defaults.rb file [ci skip]
2018-08-22 13:05:51 -05:00
Rafael França
4e9ff46cea
Merge pull request #33694 from bogdanvlviv/follow-up-33631
Remove `rake initializers` from rake tasks list
2018-08-22 13:03:49 -05:00
bogdanvlviv
63b9bf7d3d
Remove rake initializers from rake tasks list
Context https://github.com/rails/rails/pull/33631#discussion_r210732565
2018-08-22 20:49:37 +03:00
Kasper Timm Hansen
9136bb77a7
Merge pull request #33162 from utilum/stop_using_mocha
Stop using Mocha
2018-08-22 18:20:25 +02:00
schneems
4efb319141 Two fewer array allocations on action_methods
Instead of creating new arrays for `uniq` and `map` we can instead modify the array in place.
2018-08-22 11:17:50 -05:00
Ryuta Kamizono
b729494454 Partly revert unused accessor
This was introduced at 24f6bf0d96b58f2b2ef6a886c93d35cf8ce4f293.
2018-08-23 00:40:32 +09:00
Matthew Draper
24f6bf0d96
Merge pull request #33691 from tgxworld/add_config_to_disable_advisory_locks
Add database configuration to disable advisory locks.
2018-08-23 01:04:14 +09:30
Matthew Draper
047a893da7 Merge pull request #33547 from Ana06/patch-1
Use public_send in value_for_collection
2018-08-23 00:08:35 +09:30
Mina Slater
0292a37533 [ci skip] revert terminology related to syntax 2018-08-22 09:28:38 -05:00
Eileen M. Uchitelle
9eee4c1ed9
Merge pull request #33659 from palkan/feature/action-cable-testing
[WIP] Action cable testing
2018-08-22 10:27:20 -04:00
Guo Xiang Tan
20bb397e00 Add database configuration to disable advisory locks.
https://github.com/rails/rails/issues/31190
2018-08-22 22:06:08 +08:00
Mina Slater
58b78376e8 [ci skip] fixes a few more grammar issues, changing a to an before the word allowlist 2018-08-22 07:51:39 -05:00
Mina Slater
7bdf43daac [ci skip] fixes awkward grammar 2018-08-22 07:39:26 -05:00
utilum
96ac7e4cde Remove duplicate test
This patch corrects a duplicate method name introduced in #33635.

Also fixes typo in method names.
2018-08-22 01:41:09 -07:00
Claas Zurawski
d587cf2325 Fixed file name [ci skip] 2018-08-22 10:15:49 +02:00
Claas Zurawski
4858310e36 Added explanation about new_framework_defaults.rb file [ci skip] 2018-08-22 10:04:28 +02:00
Rafael França
1994e89021
Merge pull request #33682 from mroutis/brewfile-add-imagemagick
[ci skip] Add ImageMagick to Brewfile
2018-08-21 23:11:28 -05:00