Skip to content
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

fix order warnings #20036

Merged
merged 1 commit into from
Apr 2, 2020
Merged

fix order warnings #20036

merged 1 commit into from
Apr 2, 2020

Conversation

kbrock
Copy link
Member

@kbrock kbrock commented Apr 1, 2020

DEPRECATION WARNING: Dangerous query method (method whose arguments are
used as raw SQL) called with non-attribute argument(s): "lower(name)".
Non-attribute arguments will be disallowed in Rails 6.0.
This method should not be called with user-provided values,
such as request parameters or model attributes.
Known-safe values can be passed by wrapping them in Arel.sql().

These deprecation warnings display in rails 5.2
These fixes work in 5.1

DEPRECATION WARNING: Dangerous query method (method whose arguments are
used as raw SQL) called with non-attribute argument(s): "lower(name)".
Non-attribute arguments will be disallowed in Rails 6.0.
This method should not be called with user-provided values,
such as request parameters or model attributes.
Known-safe values can be passed by wrapping them in Arel.sql().
@miq-bot
Copy link
Member

miq-bot commented Apr 1, 2020

Checked commit kbrock@959a827 with ruby 2.5.7, rubocop 0.69.0, haml-lint 0.28.0, and yamllint
8 files checked, 1 offense detected

tools/db_printers/print_scsi.rb

@jrafanie
Copy link
Member

jrafanie commented Apr 2, 2020

@miq-bot add_label jansa/yes?

@chessbyte chessbyte mentioned this pull request Apr 2, 2020
38 tasks
@jrafanie jrafanie merged commit 7fc11c6 into ManageIQ:master Apr 2, 2020
@kbrock kbrock deleted the unsafe_queries branch April 2, 2020 20:02
simaishi pushed a commit that referenced this pull request Apr 3, 2020
fix order warnings

(cherry picked from commit 7fc11c6)
@simaishi
Copy link
Contributor

simaishi commented Apr 3, 2020

Jansa backport details:

$ git log -1
commit dc66de3810639030dc5fc9e21d83c1249076d472
Author: Joe Rafaniello <[email protected]>
Date:   Thu Apr 2 13:47:30 2020 -0400

    Merge pull request #20036 from kbrock/unsafe_queries

    fix order warnings

    (cherry picked from commit 7fc11c687b456aac779f65a50d4805db7f80216c)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants