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

Revert "[stable25] Fix quota type to int" #35335

Merged
merged 2 commits into from
Nov 24, 2022

Conversation

PVince81
Copy link
Member

Like #35334 for stable25.
Reverts #34019

For #34961 (comment)

@szaimen
Copy link
Contributor

szaimen commented Nov 22, 2022

@PVince81 are you sure with the exact revert? https://github.com/nextcloud/server/pull/34019/files looked a bit different...

@PVince81
Copy link
Member Author

I cherry-picked the stable24 commit

but can double check in case there's more there

@PVince81
Copy link
Member Author

@szaimen looks fine to me. please let me know if you saw something I missed

@szaimen
Copy link
Contributor

szaimen commented Nov 22, 2022

@szaimen looks fine to me. please let me know if you saw something I missed

@PVince81 the exact revert for stable25 would look like this: https://github.com/nextcloud/server/pull/35336/files

blizzz
blizzz previously requested changes Nov 22, 2022
Copy link
Member

@blizzz blizzz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@PVince81
Copy link
Member Author

right, let me redo this then. thanks

@PVince81 PVince81 force-pushed the stable25-revert-34032-fix-quota-32bit branch from e2a3f90 to 158d4a3 Compare November 22, 2022 17:03
@PVince81 PVince81 requested a review from blizzz November 22, 2022 17:05
@PVince81
Copy link
Member Author

should be better now @blizzz @szaimen

Copy link
Contributor

@szaimen szaimen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems to.be good now

@blizzz blizzz mentioned this pull request Nov 23, 2022
1 task
@blizzz
Copy link
Member

blizzz commented Nov 23, 2022

CI is red

@PVince81
Copy link
Member Author

that thing not even related to the diff:

 Error: lib/private/legacy/OC_Helper.php:511:39: InvalidScalarArgument: Argument 1 of OC_Helper::getGlobalStorageInfo expects int, false|float provided (see https://psalm.dev/012)

I'll update the baseline

@CarlSchwan
Copy link
Member

Error: lib/private/legacy/OC_Helper.php:511:39: InvalidScalarArgument: Argument 1 of OC_Helper::getGlobalStorageInfo expects int, false|float provided (see https://psalm.dev/012)

It is related private static function getGlobalStorageInfo(int $quota, IUser $user, IMountPoint $mount): array; int need be changed to float

@PVince81
Copy link
Member Author

I ran lib/composer/bin/psalm --threads=1 --update-baseline --set-baseline=build/psalm-baseline.xml but it did not update anything related to that function.

Looks like I'll need to fiddle with the baseline file manually again 😡

or do I need to run it with a specific php version ? PHP 8.1 here

@PVince81
Copy link
Member Author

Error: lib/private/legacy/OC_Helper.php:511:39: InvalidScalarArgument: Argument 1 of OC_Helper::getGlobalStorageInfo expects int, false|float provided (see https://psalm.dev/012)

It is related private static function getGlobalStorageInfo(int $quota, IUser $user, IMountPoint $mount): array; int need be changed to float

but it wasn't in the original PR ? or was there another PR also that changed it ?

I'll adjust it now just to get done with it

@szaimen
Copy link
Contributor

szaimen commented Nov 23, 2022

@PVince81 i think we should probably double check that this PR does not break 64-bit instances now...

@PVince81
Copy link
Member Author

@szaimen mind testing it ?

@szaimen
Copy link
Contributor

szaimen commented Nov 23, 2022

@szaimen mind testing it ?

Honestly I dont know what I need to test. Only changing the quota?

@PVince81
Copy link
Member Author

tested on 64-bit system by setting the quota of a user to 5 GB (which is more than the usual 4 GB or 2 GB 32-bit limit), and uploading and reporting that value in the files app worked fine

This reverts commit d61efdf.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
@PVince81 PVince81 force-pushed the stable25-revert-34032-fix-quota-32bit branch from 65b3d04 to 7bcd419 Compare November 23, 2022 19:43
@PVince81
Copy link
Member Author

rebased and DCO'd

@szaimen
Copy link
Contributor

szaimen commented Nov 23, 2022

tested on 64-bit system by setting the quota of a user to 5 GB (which is more than the usual 4 GB or 2 GB 32-bit limit), and uploading and reporting that value in the files app worked fine

All right. Fine by me then 👍

However looks like tests are failing?

@PVince81
Copy link
Member Author

drone test failures unrelated

also there's this mysterious "push" entry that appeared again. codecov fails but not the tests there

I'll restart the timed out workflow ones

@blizzz blizzz merged commit 4c99ba4 into stable25 Nov 24, 2022
@blizzz blizzz deleted the stable25-revert-34032-fix-quota-32bit branch November 24, 2022 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants