-
-
Notifications
You must be signed in to change notification settings - Fork 315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rails 5 support #1125
Rails 5 support #1125
Conversation
lib/alchemy/touching.rb
Outdated
@@ -2,7 +2,7 @@ module Alchemy | |||
module Touching | |||
# Touches the timestamps and userstamps | |||
# | |||
def touch | |||
def touch(*names, time: nil) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unused method argument - names. If it's necessary, use _ or names as an argument name to indicate that it won't be used. You can also write as touch() if you want the method to accept any arguments but don't care about them.
Unused method argument - time. You can also write as touch(_) if you want the method to accept any arguments but don't care about them.
efab654
to
08ceef8
Compare
6b46ea2
to
fecfb61
Compare
Any estimates on when Rails 5 will be fully supported? |
@hyiltiz unfortunately not yet. Working on it. Any help is appreciated. |
db4a0e4
to
2d17e9a
Compare
let(:legacy_url4) do | ||
Alchemy::LegacyPageUrl.create( | ||
urlname: 'index.php?option=com_content&view=article&id=48&Itemid=69', | ||
page: second_page) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Closing method call brace must be on the line after the last argument when opening brace is on a separate line from the first argument.
f2409aa
to
92e314f
Compare
I pulled down this branch and ran the test suite locally, and came up with 0 failures (yay!). If the mysql failures in travis were fixed, would this branch be considered for merge prior to 4.0? I'm not planning to use mysql, but if I can help with making it work I don't mind doing so. |
I was able to replicate the failures with mysql, and they all seem to tie to expected changes to timestamp fields. After some research, I found a patch to rails to enable subsecond resolution for MySQL timestamps so I'm not sure why it does not seem to happen here. The good news is that all 17 failures I saw seem to center around this problem, so one fix will probably green them all. |
As expected, something is truncating the fractional seconds:
|
According to The MySQL docs the default precision for datetime fields is 0. I'm happy to create migrations that explicitly set the precision on all timestamp fields to 6. That should match with what postgresql already does, while bringing mysql up to speed. |
Verified: adding full precision to a test column made the tests related to that column pass. I'll build a migration for all of them and submit it. |
Thanks. This is really helpful. I think using a higher precision on timestamps just for MySQL is not what we want to maintain. Instead we should try to fix the specs.
I want to have feature parity between current (yet unreleased) 3.6 and 4.0 (Rails 5 compatible version of Alchemy. Therefore we need to release a 3.6 first. This version needs to include deprecation warnings for stuff we need to change for Rails 5. There is still lot to do. Unfortunately, my time for working on Alchemy is very limited. So, this will take some time. Thanks for looking into the MySQL stuff. |
@phoet did you supply the DB=mysql env var when running the tests? I was able to produce the fails on a fresh install (and a fresh fork) by adding that config tweak. |
Wow, it's just brilliant how small this PRs, and 70% of the changes are to the Actually, am I missing something or there isn't a single line of non-test code change in there, which is not Rails 5 specific? Then what deprecations warning do you want to put in place Thomas? Maybe for some old PRs, which have made a deprecation without documenting it? |
Sorry, just wanted to ask if I can help out with writing out those deprecation warnings, or would it be too much to explain? |
Great that Rails 5 support is almost ready! I'm looking forward to using Alchemy as the content management part of a real estate website builder I'm working on. Thanks for all the great work. |
Hey there @tvdeyen, from what I can read, the roadmap to Rails 5 support is:
Would that summarise what is needed? If so, I can get a developer perhaps from my company to help push this through. Please let me know. |
@mikel yes, this is how I plan to do this. Thanks for your offer, this is very much appreciated, but you can't actually gems, so I have to do this. But due to lack of time I can't really make this soonish. I don't want to rush this either, as releasing open source software has to be done carefully, for that I need some time to concentrate on. This is not very satisfy for you, I see that. You could help us by testing the |
Rails 5 only supports 2.2.2+, so we.
It is not needed any more with sprockets-rails 3.1
Rails 5 has dropped support for `assign` and `assert_template` methods.
Rails 5 now wants the database environment set.
With Rails 5 the supported Ruby version was raised to 2.2.2 Adjust the travis configuration to build with Ruby 2.2.6, 2.3.3 and 2.4.0
@mamhoff just released 3.6, so this is now finally ready to be merged 🎊 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me! Thanks to everyone involved!
Wooow, so sooon? Wow, I really didn't expect it for another few months after your message. Thanks so much all!! I am really excited about the updated UI in #1261 , so now that this one is merged, I will see to help out there! Thanks again all! |
Haha, yeah. I wanted to have this finally done myself. Very annoying to have al this TODOs laying around. |
Absolutely, know the feeling. Thanks again! |
Rails 5 support
As with mayor Rails updates before, we plan to support Rails 5 with the next mayor version of Alchemy (4.0).
This PR is an ongoing process to make the necessary changes.