-
Notifications
You must be signed in to change notification settings - Fork 53
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
Upgrade phpunit #1754
Upgrade phpunit #1754
Conversation
Not sure about the SQL change for the party cohort group by... |
Though if we're dropping that query entirely, guess that doesn't matter so much! |
f7e4026
to
a19a204
Compare
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.
Meta-yes - the cohort query is redundant soon - but I think it makes sense.
As I understand it:
This is fixing a problem in the query where we want to ensure the cohort key is membership dates and party IN ORDER - and the extra subquery here is needed to ensure that (the order by is the wrong way to do it).
This makes sense to me - according to past me it doesn't matter for party switchers that their cohort key is the original party (because it's just trying to create a unique set), so that's fine.
I've rerun the party policy generation on this branch and on a quick check it puts out the right number of cohorts and public numbers seem to be ok. So if that was the only unclear bit (proof of the rest of it is that the tests pass?) - can be merged.
Fixup commit for getRecentDebatesWithDivisions: where changing some to mins affected the field names used later on. Translation currently fails here because of 'Maximum term length is 255 characters' in master. Can be fixed separately, but not an error here. |
classes/Divisions.php
Outdated
@@ -161,9 +161,9 @@ public function getRecentDebatesWithDivisions($number = 20, $majors = null) { | |||
$debate_gid = fix_gid_from_db($debate['debate_gid']); | |||
$anchor = ''; | |||
if ($debate['c'] == 1) { | |||
$anchor = '#g' . gid_to_anchor(fix_gid_from_db($debate['gid'])); | |||
$anchor = '#g' . gid_to_anchor(fix_gid_from_db($debate['debate_gid'])); |
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 think this needs to remain gid and the "min(h.gid)" needs an "as gid" adding, rather than switch to a different gid. I'll do it, just noting in case I'm wrong!
Empty IN, bool ints, strict group by.
Need to turn off deprecation warnings for tests to pass (e.g. some output in the middle of a string being tested on), but will need to be reactivated and issues fixed before PHP9.
9a47a84
to
2d9398c
Compare
No description provided.