Merge pull request #17255 from printercu/cors_exception_wrapper

ActionController::InvalidCrossOriginRequest fails with 422 instead of 500
Merge pull request #17313 from accessd/fix-url-generation-error-message

Fix url generation error message
Clarify comments in sanitize_helper.rb

Arguments passed to methods like `sanitized_allowed_tags=` should be Enumerable, so the examples have been wrapped in square brackets to suggest this explicitly.
Merge pull request #17390 from MCGallaspy/issue-17386

Clarify comments in sanitize_helper.rb [ci skip]
Merge pull request #17064 from frenkel/fix_select_tag_include_blank

Use include_blank value as option label
Properly quote numerics when casting string columns

Returning the wrong type can cause the wrong index to be used on some
adapters, or even an error. We use `.try` rather than checking for
`nil`, since the tests on 4.1 imply that objects that do not respond to
`type` can be passed as the column for `quote`.

Closes #17345
FileHandler should not be called for files outside the root

FileHandler#matches? should return false for files that are outside the
"root" path.

Conflicts:
	actionpack/lib/action_dispatch/middleware/static.rb
bumping version to 4.1.7
Update documentation of touch method

- Note that after_commit and after_rollback callbacks are also run.
- This documentation update is present in master but not in rails-4-1 branch.
- Closes #17438
[ci skip]
Merge pull request #17439 from prathamesh-sonpatki/rails-4-1

Update documentation of touch method
Merge branch '4.1.7' into 4-1-stable

* 4.1.7:
  bumping version to 4.1.7
  FileHandler should not be called for files outside the root
Do not package the guides output

Fixes #17455
Merge branch 'tags-public-send'

Fixes #14180
Fixes #17461
Merge pull request #17305 from ziggythehamster/activerecord-connectionhandling-RAILS_ENV-without-rails

If Rails is not defined, check ENV["RAILS_ENV"] and ENV["RACK_ENV"] in ActiveRecord::ConnectionHandling
Conflicts:
	activerecord/test/cases/connection_adapters/merge_and_resolve_default_url_config_test.rb
Merge pull request #17360 from bronzle/includes_and_unscoped

copy reflection_scopes’s unscoped value when building scope for preloading

Conflicts:
	activerecord/CHANGELOG.md
Merge pull request #17518 from prathamesh-sonpatki/fix-activesupport

Fix broken string_ext_test due to change in timezone
Merge pull request #17552 from jipe/master

Guides: Corrected name for assigns key [ci skip]
Merge pull request #11694 from Empact/association-bind-values-not-updated-on-save

Fix that a collection proxy could be cached before the save of the owner, resulting in an invalid proxy lacking the owner’s id

Conflicts:
	activerecord/CHANGELOG.md

Conflicts:
	activerecord/CHANGELOG.md
Merge branch 'rm-fix-secret-token-fallback'

Conflicts:
	railties/CHANGELOG.md
Make FlashHash#key? work with symbol and string

Closes #17586