Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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 6.0 #20778
Rails 6.0 #20778
Changes from all commits
4db0d66
2536663
d4e2d96
6131f65
d8114bf
5c470b4
0e5c884
5ad61de
5041940
fd52447
8736542
00effb1
6a6b933
99d567d
4252427
1f48247
01598c2
182afee
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
I'm kind of surprised we have sequences at all for groups. Do we know what the use case is for this?
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.
Don't know, but I think this was added by @djberg96 so possibly he can comment? At least the specs were authored by him (pretty sure).
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.
@NickLaMuro Not that I recall. Do you have a commit? I couldn't find one in the log with my name for this file.
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.
@djberg96 woops, I think I mis-associated you with this commit:
41067b9
#18279
And I think @kbrock was actually the one involved:
1eb754c
#5164
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.
Yea, we use sequence for policies, widgets, actions, and groups.
the value didn't seem to matter for groups, just so that it is unique within the user's groups or the region maybe? I think this is where the scope comes into play. And where rails will audibly complain
Also, I'd like to say that we want to remove nil values from the sequence so ordering would be easier and more consistent.
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.
also, this
maximum
is executing an extra sql query on create. sure would like to get rid of thatThere 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.
I guess I'm less interested in how sequences work as opposed to what feature does sequences provide to the end user? (I don't understand it for polcies and actions either, unless that the order or execution in a policy run, but why? Nor for widgets, unless that's a position on a dashboard, but then wouldn't that be defined in the dashboard?)
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.
I really like how you broke up the other one into
<<~EXPECTED
...does it make sense to do that here too?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.
Was trying to avoid making too many changes, and that one specifically was hard to grok in the errors from rspec, so doing that allowed me to see it easier.
That said, not opposed to the idea, was just avoiding making too many large changes when I could to reduce the number of "variables" changed in a single PR.
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.
Up to you...I have no real preference in this PR.
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.
I will wait then, but leave this comment as unresolved as a secondary reminder that I do want to do it as a follow up.