| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | | |
|
| | |
| | |
| | |
| | | |
This seems to be the style settled on in most of the templates.
|
|\ \ \
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Specify dummy app's db migrate path in plugin's test_helper.rb
Conflicts:
railties/CHANGELOG.md
|
| | | | |
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If code is not eager loaded constants are loaded on demand. Constant
autoloading is not thread-safe, so if eager loading is not enabled
multi-threading should not be allowed.
This showed up in certain Capybara scenarios: Most Capybara drivers
other than Rack::Test need a web server. In particular, drivers for
JavaScript support. Capybara launches WEBrick in its own thread for
those but that per se is fine, because the spec thread and the server
thread are coordinated.
Problem comes if the page being served in the spec makes Ajax calls.
Those may hit WEBrick in parallel, and since WEBrick is multi-threaded
and allow_concurrency? returns true in the test environment before
this patch, threads are spawned to serve those parallel requests. On
the other hand, since eager_load is false by default in the test
environment, constants are not preloaded.
So the suite is autoloading constants in a multi-threaded set. That's
a receipt for paracetamol. The symptom is random obscure errors whose
messages point somehow to constant autoloading.
As a consequence of this fix for allow_concurrency? WEBrick in
Capybara scenarios no longer runs in multi-threaded mode.
Fixes #15089.
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | | |
This was caused by #15327.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Previously setting simple values to the config.x object resulted in the
following:
config.x.super_debugger = true
config.x.super_debugger #=> {}
Which was against the examples showed in the changelog/release notes.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This reverts commit de4891344ccc074f6d5693f4fac6ad610584e336.
Conflicts:
railties/lib/rails/railtie/configuration.rb
It added regression. Will be back after the beta
|
|\ \ \
| | | |
| | | | |
Mention web-console in 4.2 release notes
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Mention the web-console inclusion in the default Gemfile in the Release
notes and the railties changelog. We can eventually mention it in the
upgrade guide, if needed.
[ci skip]
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
1. Hashes can be assigned
2. We don't need a special level anymore
The method chain only works in the top level.
If users need a second level they need to assign a OrderedOptions to the
key:
config.resque.server = ActiveSupport::OrderedOptions.new
config.resque.server.url = "http://localhost"
config.resque.server.port = 3000
[Rafael Mendonça França + Carlos Antonio da Silva]
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Syntax was chosen to follow the passing of multiple options to
decimal/numeric types. Curly braces, and allowing any of `,`, `.`, or
`-` to be used as a separator to avoid the need for shell quoting. (I'm
intending to expand this to all columns, but that's another PR.
The `required` option will cause 2 things to change. `required: true`
will be added to the association. `null: false` will be added to the
column in the migration.
|
|\ \ \
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Add an after_bundle callback in Rails templates
Conflicts:
railties/CHANGELOG.md
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The template runs before the generation of binstubs – this does not
allow to write one, that makes an initial commit to version control.
It is solvable by adding an after_bundle callback.
|
|/ / / |
|
|/ /
| |
| |
| | |
Give password_confirmation div the "field" class in the scaffold generator "_form" partial
|
| |
| |
| |
| |
| | |
This is a convenience for loading configuration for the current Rails
environment.
|
| |
| |
| |
| |
| | |
Also reordered some of the items to put newer ones on top (same order as
CHANGELOGs), which makes it easier to diff while we are still working on it.
|
| |
| |
| |
| | |
adapter, fixed from #16057 [ci skip]
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
It was being used by Rails for show the development logs but since Rails
4 it is not being used anymore on the framework.
This class seems to be private but it were part of the public API we are
deprecating before removing.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Also remove --skip-turbolinks.
This option is useful if users want to remove some gems like jbuilder,
turbolinks, coffee-rails, etc that don't have specific options on the
generator.
rails new my_app --skip-gems turbolinks coffee-rails
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When someone types in a generator command it currently outputs all generators. Instead we can attempt to find a subtle mis-spelling by running all generator names through a levenshtein_distance algorithm provided by rubygems.
So now a failure looks like this:
```ruby
$ rails generate migratioooons
Could not find generator 'migratioooons'. Maybe you meant 'migration' or 'integration_test' or 'generator'
Run `rails generate --help` for more options.
```
If the suggestions are bad we leave the user with the hint to run `rails generate --help` to see all commands.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit ec0a2b57f67c9153cb5f7bbe2a3f66d13fe64bdd, reversing
changes made to a8bd7b16260c217290ef8fe3a166fcceac442c62.
This reverts commit 555ec36522011862c03b483c53be32410594a51e
This reverts commit 555ec36522011862c03b483c53be32410594a51e
By default, Rails uses the `default` Rake task to run all tests.
This commit changed the environment of the default task to `development`.
This clears the development database and has other negative consequences.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Database configuration was trying to load the first path that
config.paths['config/database'] was returning even if the path didn't
exist in the filesystem.
Because Rails::Paths::Path has the possibility to return more than 1
path (as an array), database_configuration should filter down the paths
to the existing one and then load the first one.
This would make it possible to move the database.yml file and add the
new path to paths['config/database'] and still load the configurations.
|
| |
|
|
|
|
|
|
|
| |
Like rake tasks and runner blocks these blocks should also being shared
between applications since they are stored at the classes.
Fixes #14748
|
|
|
|
|
| |
sprockets-rails 2.1 needs the precompile list to be available in all
environments.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Templates could rely on irregular inflections or external libraries for
instance so we should load the application's initializers when running
the rails:template task.
The introducing commit of this feature is f7f11361 ; the initializers
have never been loaded invoking this task.
Fixes #12133.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This method return `Gem::Version.new(Rails.version)`, suggesting a more
reliable way to perform version comparison.
Example:
Rails.version #=> "4.1.2"
Rails.gem_version #=> #<Gem::Version "4.1.2">
Rails.version > "4.1.10" #=> false
Rails.gem_version > Gem::Version.new("4.1.10") #=> true
Gem::Requirement.new("~> 4.1.2") =~ Rails.gem_version #=> true
This was originally introduced as `.version` by @charliesome in #8501
but got reverted in #10002 since it was not backward compatible.
Also, updating template for `rake update_versions`.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since #11544, invoking the controller generator, any generated route is
namespaced according to the class_path method. Since a mountable plugin
is namespaced, creating a controller inside would generate a namespaced
route based on the engine's name.
The controller generator now relies on regular_class_path which does not
contain the class hierarchy but the given path.
Fixes #14079.
|
|
|
|
| |
Remove 4-1 related entries from master [ci skip]
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit e0a521cfcd13e4d1f0ae8ab96004289e1c020f71.
Conflicts:
railties/CHANGELOG.md
We expect loggers to quack like stdlib logger. If log4r needs different
level= assignment, using a Logger-quacking wrapper is the way to do it.
Fixes #14114.
|
| |
|
|\
| |
| |
| |
| |
| |
| | |
git://github.com/emilsoman/rails into emilsoman-dump-schema-after-migration-flag
Conflicts:
activerecord/CHANGELOG.md
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Add a config on Active Record named `dump_schema_after_migration`
* Schema dump doesn't happen if the config is set to false
* Set default value of the config to true
* Set config in generated production environment file to false
* Update configuration guide
* Update CHANGELOG
|
|/
|
|
| |
/cc @chancancode
|
|
|
|
|
|
|
|
|
|
| |
This Thor-action isolates the logic whether to (over-)write migration and
what is shown to the user. It's modelled after Thor's CreateFile-action.
This solves the issue that removing a non-existing migration, tried to
remove the template-path (#13588).
Related issues: #12674
|
| |
|
| |
|