Commit Graph

607 Commits

Author SHA1 Message Date
Xavier Noria
d59e729fbf Depend on Zeitwerk 2.5.0.beta5 2021-09-29 09:25:40 +02:00
Xavier Noria
e44ce53f78 Depend on Zeitwerk 2.5.0.beta4 2021-09-22 08:47:21 +02:00
Rafael Mendonça França
50d60e4f7c
Allow Marcel to be released following semver 2021-09-20 17:19:57 -04:00
David Heinemeier Hansson
780753f571 Use debug 1.1+ for the debugger + log quieting 2021-09-20 15:18:30 +02:00
Rafael Mendonça França
d177551c30
Preparing for 7.0.0.alpha2 release 2021-09-15 18:22:51 -04:00
Rafael Mendonça França
9b7be48212
Preparing for 7.0.0.alpha1 release 2021-09-15 17:55:08 -04:00
Xavier Noria
7ffe204a08 Upgrade debug to 1.0.0 2021-09-08 20:33:22 +02:00
Xavier Noria
89801b2a43 Depend on ruby/debug, replacing Byebug
ruby/debug is a new debugger that is going to ship with CRuby.

It makes sense for Rails to switch to this one because that is
where the language is heading, and because Byebug is not fully
compatible with Zeitwerk. See

    https://github.com/deivid-rodriguez/byebug/issues/564

While ruby/debug has not been heavily tested with Zeitwerk,
casual usage seems to suggest it works without issues, including
explicit namespaces, which is where Byebug and Zeitwerk conflict.

Byebug is terrific, thanks a lot for all these years. ❤️
2021-09-08 17:35:41 +02:00
David Heinemeier Hansson
83808166e6
Add --css app generator option (#43177)
* Add --css to preconfigure a CSS bundler/processor

* Simpler conditional

* Add CSS gems

* Test CSS options
2021-09-07 17:48:13 +02:00
David Heinemeier Hansson
7595c922a6
Use the combined jsbundling-rails gem instead of individual js bundler gems (#43172)
* Use the combined jsbundling-rails gem instead of individual js bundler gems

* Remove Webpacker remnants

* Replace webpacker with jsbundling-rails
2021-09-06 16:44:44 +02:00
David Heinemeier Hansson
82e4432058
Javascript generator option with choices (#43160)
* Switch to a single controller option for choosing JavaScript approach

* Remove remnants of webpacker specific work within Rails

* No longer used

* Missing space

* Raise if unknown option is passed

* Style

* Use latest versions

* Make channels setup generic to all node setups

* Make Action Text installer work with any node package manager

* Explaining variables are not useless

* Rubocop pleasing

* Don't rely on Rails.root

Tests don't like it!

* Rubocopping

* Assume importmap

* No longer relevant

* Another cop

* Style

* Correct installation notice

* Add dependencies for action cable when adding a channel

* Fix paths to be relative to generator

* Just go straight to yarn, forget about binstub

* Fix tests

* Fixup installer, only yarn once

* Test generically with run

* Style

* Fix reference and reversibility

* Style

* Fix test

* Test pinning dependencies

* Remove extra space

* Add more tests

* Use latest dependencies

* Relegated this to controllers

* Refactor ChannelGenerator + more tests

Use a uniform level of abstraction
2021-09-04 11:53:57 +02:00
Xavier Noria
174ee7bb60 Depends on Zeitwerk 2.5.0.beta3 2021-09-01 15:31:04 +02:00
David Heinemeier Hansson
d5b9618da1
Remove default reliance on Sass and CSS generators (#43110)
* No benefit to having actiontext css as scss

* Update test

* Update docs

* No more css assets to be generated

New world, new CSS frameworks, new needs.

* SCSS is becoming optional

* Remove Sass as a default-on setting

But continue to make it easy to add.

* Update docs

* No longer used

* Update tests

* Update docs

* Update docs

* No longer used

* No longer by default

* Fix tests

* Promote Tailwind CSS as an alternative to Sass

* Fix test and copy task

* Update railties/lib/rails/generators/rails/app/templates/Gemfile.tt

Co-authored-by: Kevin Newton <kddnewton@gmail.com>

Co-authored-by: Kevin Newton <kddnewton@gmail.com>
2021-08-26 13:40:25 +02:00
David Heinemeier Hansson
af7428c4ac
Replace webpack with importmapped Hotwire as default js (#42999)
* Turbolinks is being replaced with Hotwire

* Make --webpack opt-in

* Don't use specific webpacker installers any more in preparation for next Webpacker

* Update railties/lib/rails/app_updater.rb

Co-authored-by: Alex Ghiculescu <alex@tanda.co>

* Trailing whitespace

* Convert to Turbo data attribute for tracking

* Default is no webpack, no hotwire

* Swap out turbolinks references for hotwire

* Drop explicit return

* Only generate package.json if using webpack

* Only create package.json in webpack mode

* Only create app/javascript in webpack mode

* Generate correct style/js links based on js mode

* Fix tests from changed output format

Not sure why these are showing up in this PR, though.

* Rubocopping

* Stick with webpack for the test app for now

* Adjust tests

* Replace minitest-reporters with minitest-ci (#43016)

minitest-reporters is used to create junit xml reports on CI.

But when it loads before rails minitest plugin makes
`Rails::TestUnitReporter` not being added as a reporter.

minitest-ci is now only loaded at ci and does not interferes with
rails minitest plugins. And keeps junit reports workings

* Too heavy handed to actually run bundle

Just like we don't auto-migrate

* Pin js frameworks in importmap

Instead of having importmap preconfigure it.

* Match updated app/javascript path

* No need for the explaining comment

* Fixes test cases for replace webpack with importmapped Hotwire as default js (#42999)

* Fix rubocop issues

* Fix more railities test cases

* Fix plugin generator railties shared test cases

* Fix Action Text install generator asset pipeline spec

* They're modules, not files

* Let dev use the latest release as well

So we don't have to replace unexisting dev releases with latest release

* Make Webpack responsible for generating all the JS files it needs

Webpacker 6 has already moved from app/javascript to app/packs.

* Don't add rails/ujs by default any longer

All the ajax/form functionality has been superseded by Turbo. The rest lives in a weird inbetween land we need to address through other means.

* Use new importmap location

* Switch to using turbo-rails and stimulus-rails directly

The hotwire-rails gem does not offer enough value for its indirection

* Use latest Webpacker

* Prevent version resolution requests from getting swallowed

* Use ESM syntax for imports

* Move management of yarn, package.json, etc to Webpacker 6

* Update for Webpacker 6

* Move bin/setup addition to Webpacker as well

* Remove dead tests

* Bump to Webpacker 6.0.0.rc.2

* No longer relevant given the new default is no webpacker

* Rely on Webpacker 6

* No longer relevant

* No longer relevant

* Make cable channel generator work for both webpacker and importmap setups

* Fix tests

* For tests testing importmap way

* Use Webpacker 6 dummy

* RuboCopping

* One more bump to fix webpack-dev-server

* Another bump. Hopefully the last one!

* Also enough to not want turbo tracking on

* Fix tests

* Latest

* Fix tests

* Fix more tests

* Fix tests

Co-authored-by: Alex Ghiculescu <alex@tanda.co>
Co-authored-by: André Luis Leal Cardoso Junior <andrehjr@gmail.com>
Co-authored-by: Abhay Nikam <nikam.abhay1@gmail.com>
Co-authored-by: Guillermo Iguaran <guilleiguaran@gmail.com>
2021-08-26 10:39:36 +02:00
Petrik
0920b02c1d Upgrade azure-storage-blob to use at least 2.0.0
azure-storage-blob 1.1.0 supports ruby 1.9.3 to 2.5:
https://github.com/Azure/azure-storage-ruby/blob/v1.1.0-common/common/README.md

azure-storage-blob 2.0.0 supports ruby 2.3 to 2.7:
https://github.com/Azure/azure-storage-ruby/blob/v2.0.0-blob/common/README.md
2021-08-23 22:03:15 +02:00
Xavier Noria
c192feb3eb Update Gemfile.lock 2021-08-21 10:35:03 +02:00
Koichi ITO
65af100ddd Tweak unreachable assertion tests in the block of assert_raises
I found an unexpected use of assertion in the block of `assert_raise`
when I implemented https://github.com/rubocop/rubocop-minitest/pull/137.
It is expected to be asserted after an exception is raised in
`assert_raise` block, but in actually it is not asserted after an
exception is raised. Therefore, this PR removes or updates assertions
that have not been asserted after an exception has raised.

This PR will add `rubocop-minitest` and enable
`Minitest/UnreachableAssertion` cop to able similar auto-detection,
but will remove `rubocop-minitest` from this PR if you don't like it.
2021-08-17 20:33:08 +09:00
Ryuta Kamizono
b669e87071 Enforce standardizing nodoc comments by rubocop
Follow up to 18707ab1, b87d8e51.

rubocop 1.19.0 includes https://github.com/rubocop/rubocop/pull/9964.
2021-08-12 20:01:37 +09:00
David Heinemeier Hansson
e34300a921
Stop trying to configure listen by default on compatible platforms (#42985)
* Stop trying to configure listen by default on compatible platforms

Modern computers with SSDs don't see much/any benefit from having an evented file update watcher. Remove complexity by taking this spinning-drive concession out.

* Actually need listen for testing the opt-in

* Test no longer relevant
2021-08-11 15:18:43 +02:00
Xavier Noria
6068639775 Upgrades Zeitwerk to 2.5.0.beta 2021-08-04 09:43:06 +02:00
Jean Boussier
bbaf40bd7f Update globalid to 0.5.1 for ruby-head compatibility
https://github.com/ruby/uri/pull/26 was recently pulled
in ruby-head, and it breaks globalid < 0.5.
2021-07-27 23:23:13 +02:00
Ryuta Kamizono
d7fce6c996 Fix odd closing parenthesis by enabling the Layout/ClosingParenthesisIndentation cop 2021-07-02 18:01:50 +09:00
Hartley McGuire
bcb300dccb Replace uglifier with terser in dummy applications
Terser is more up to date with modern javascript features, and the
uglifier gem repository recommends using it for minifying ES6+.

Followup for 955041b
2021-06-28 00:48:56 -04:00
Rafael França
ee99c89f90
Merge pull request #42513 from ghiculescu/ci-ujs-tests
Output UJs test failures in CI
2021-06-23 14:56:45 -04:00
Alex Ghiculescu
2934c54dfd Output UJs test failures in CI 2021-06-17 16:51:37 -05:00
Rafael Mendonça França
882750b0be
Upgrade development gems 2021-06-17 20:27:14 +00:00
Rafael Mendonça França
115d4a3994
Simplify the implementation by only calling the checks in the right places 2021-06-17 15:09:54 +00:00
Jean Boussier
48141031a6 Add x86_64-darwin-20 platform to the Gemfile
Otherwise people developping on Big Sur will have to rebundle
2021-06-10 15:33:12 +02:00
Rafael Mendonça França
c13b28072f
Update development gems 2021-06-08 23:27:47 +00:00
John Hawthorn
14688b5578 Bump rack to remove ssl? override
Rack 2.2+ already understands "wss" as being "ssl", so bumping the
requirement lets us remove this override and call to super.
2021-06-01 11:15:14 -07:00
Ryuta Kamizono
153a78dee0 Revert "Lock benchmark-ips version "< 2.9.0""
This reverts commit b63e1477eaccfa6416db4f09bb82880ecb0797d1.
2021-05-25 06:13:09 +09:00
Ryuta Kamizono
b63e1477ea Lock benchmark-ips version "< 2.9.0"
Accidentally benchmark-ips 2.9.0 doesn't contain
"lib/benchmark/ips/noop_suite.rb".

https://buildkite.com/rails/rails/builds/77608#ba2b5c32-d02c-4dc4-9c48-f731b513f883/2031-2080
2021-05-23 06:03:04 +09:00
Petrik
b00c38cc41 Upgrade sdoc to 2.2.0
Sdoc 2.2.0 has improved accessibility and bug fixes.

Changelog:

* #161 Add 'skip to content' link and improve shortcut keys
* #170 Fix link hovers in headings
* #169 Fix clearing search results
* #167 Update Merge script to work with sdoc v2
* #160 Remove outline from reset stylesheet
* #159 Remove TAB override in panel
* #157 Move to GitHub action for tests
* #155 Fix Ctrl+C copying Jan Schär
2021-05-21 10:06:22 +02:00
bogdanvlviv
34c53bab6c
Update Gemfile.lock
Executing `bundle install` makes git-diff in the file on my VM.
It reverts changes that were made in bbbc861f717689a0a28f031fe2176d0f8a6b07c7
to the file.

Sorry for this noise. I just want to figure out whether it is something unique
with my VM's environment or those changes were made accidentally?
/cc @kamipo
2021-05-04 15:14:26 +00:00
Yasuo Honda
06d5997b78 Revert "Merge pull request #42088 from yahonda/use_beaneater10"
This reverts commit 0184a019353fa862c37ae61308e62e4e702c347f, reversing
changes made to ed8667df5cd4d4026d803b59e6a8f1af910ae3e3.
2021-04-28 11:47:51 +09:00
Yasuo Honda
b0ce854e68 Use beaneater 1.0.0 to workardound ArgumentError: wrong number of arguments error
This commit addresses Rails CI `ArgumentError: wrong number of arguments (given 2, expected 1)`
errors at https://buildkite.com/rails/rails/builds/76966#8aea460d-a196-4a38-a7dc-b41af5187d9a/1485-1518
by locking `beaneater` version to 1.0.0. Because `backburner` gem depends on `beaneater`.
and `beaneater` 1.1.0 has been released which triggers this error.

- Errors are reported at Rails CI
https://buildkite.com/rails/rails/builds/76966#8aea460d-a196-4a38-a7dc-b41af5187d9a/1485-1518

- Steps to reproduce
```
git clone https://github.com/rails/rails
cd rails
rm Gemfile.lock
bundle install
cd activejob
bundle exec rake test:integration:backburner
```

- Expected behavior
It should pass

- Actual behavior
ArgumentError: wrong number of arguments (given 2, expected 1)

This workaround can be removed newer versions of `beaneater` released
including this pull request or similar fix.
https://github.com/beanstalkd/beaneater/pull/80
2021-04-27 22:38:36 +09:00
Ryuta Kamizono
bbbc861f71 Enable Performance/MapCompact cop
Follow up to #42053.
2021-04-23 16:33:02 +09:00
Rafael Mendonça França
94b954576a
Autocorrect Rubocop roles 2021-04-13 18:32:25 +00:00
Rafael Mendonça França
9dbacf4d71
Upgrade the development Gemfile.lock 2021-04-13 18:19:29 +00:00
George Claghorn
b80a2bdeb9
Active Storage: upgrade to mini_mime 1.1.0
Fix validating uppercase variant formats. Closes #41796.
2021-04-04 22:44:02 -04:00
Petrik
85c20074f0 Upgrade sdoc to 2.1.0
Sdoc 2.1.0 works better on mobile and has improvements for SEO and
Lighthouse.

Changelog:
* #154 Make panel responsive for mobile.
* #153 Add viewport metatag to views for improved Lighthouse score.
* #150 Use semantic headers for better SEO.
2021-03-31 12:51:01 +02:00
George Claghorn
526d630793 Upgrade to Marcel 1.0.0 2021-03-26 14:21:28 -04:00
George Claghorn
62ac25a364 Replace mimemagic with mini_mime 2021-03-26 14:20:40 -04:00
Rafael Mendonça França
d5ee11933f
Make sure the version of rake used in Rails apps work
Since 68a3f679d93a22160cca9a8bd9a869b8c766f860, we are requiring rake
0.13, so we need to specify that is the version we want.
2021-03-15 20:48:38 +00:00
Kasper Timm Hansen
a822923fd5
Merge pull request #41550 from p8/sdoc-2.0.4
Update SDOC to 2.0.4
2021-02-25 18:37:04 +01:00
Petrik
0dfb6a606a Update SDOC to 2.0.4
This version has two layout fixes:
* Using HTML5 doctype accross all HTML files. @MikeRogers0
* Fix overflow CSS property of panel elements. @cveneziani
2021-02-25 17:47:30 +01:00
Ryuta Kamizono
2994c4ba00 Use released redis-namespace instead of master branch
https://rubygems.org/gems/redis-namespace/versions/1.8.1
2021-02-22 18:49:24 +09:00
Rafael Mendonça França
1b455e2e9d
Rails 6.2 is now Rails 7.0
We have big plans for the next version of Rails and that
require big versions.
2021-02-04 16:47:16 +00:00
Rafael Mendonça França
1993496d7f
Upgrade all the gems to make sure we are testing with the latest versions locally 2021-01-21 21:22:41 +00:00
eileencodes
48f3c3e201
Update platforms in Gemfile.lock
This keeps popping up after bundle on my local machine. We can
just add this to the lock file so there's no diff after bunding.
2021-01-13 15:12:23 -05:00