Repository navigation
VerifyChecksum: Ignore files which are in filecache but not in the storage - #31430
Conversation
|
Shouldn't this require a normal |
8ba6784 to
9540d6d
Compare
Codecov Report
@@ Coverage Diff @@
## master #31430 +/- ##
============================================
+ Coverage 64.01% 64.03% +0.02%
- Complexity 18564 18575 +11
============================================
Files 1171 1171
Lines 69851 69864 +13
Branches 1267 1267
============================================
+ Hits 44714 44737 +23
+ Misses 24767 24757 -10
Partials 370 370
Continue to review full report at Codecov.
|
9540d6d to
4599753
Compare
4599753 to
7ee4b16
Compare
7ee4b16 to
504eec9
Compare
PVince81
left a comment
There was a problem hiding this comment.
one major issue with instance of check and a few minor ones
| $owner = $node->getOwner()->getUID(); | ||
| $storage = $node->getStorage(); | ||
|
|
||
| if ($storage instanceof ISharedStorage || $storage instanceof FailedStorage) { |
There was a problem hiding this comment.
$storage->instanceOfStorage(ISharedStorage::class) because of storage wrappers... please closely follow how the Util\Scanner does it
| } | ||
|
|
||
| if (!self::fileExistsOnDisk($node)) { | ||
| $output->writeln("Skipping $owner/$path => File is in file-cache but doesn`t exist on storage/disk", OutputInterface::VERBOSITY_VERBOSE); |
There was a problem hiding this comment.
use apostrophe and not backtick for "doesn't"
make sure to replace every other occurrence if any
an alternative is to use "does not"
| * @return bool | ||
| */ | ||
| private static function fileExistsOnDisk(Node $node) { | ||
| $statResult = $node->stat(); |
There was a problem hiding this comment.
I see we don't have a method ->exists() on the node, ok.
Now I wonder what happens if the file happens to not be readable due to messed up permissions. Maybe also check $node->isReadable() ?
504eec9 to
a3b0a8d
Compare
|
@IljaN please adjust tests for code coverage. The new conditions aren't called by tests. If needed you can check the unit tests for the Util/Scanner |
|
I've added tests for the test coverage. Note that for the |
484183a to
400c690
Compare
|
now it's only codecov again. I can't open the report though... |
400c690 to
5ba0055
Compare
|
🤞 🤞 |
5ba0055 to
c4c6435
Compare
not sure if this is up to date though |
|
@ownclouders rebase |
|
Hey! I'm GitMate.io! This pull request is being rebased automatically. Please DO NOT push while rebase is in progress or your changes would be lost permanently |
2db1762 to
f6027a5
Compare
|
Automated rebase with GitMate.io was successful! 🎉 |
|
Oracle failure: |
|
@ownclouders rebase |
|
Hey! I'm GitMate.io! This pull request is being rebased automatically. Please DO NOT push while rebase is in progress or your changes would be lost permanently |
f6027a5 to
4a6f584
Compare
|
Automated rebase with GitMate.io was successful! 🎉 |
|
Looks like #32248 fixed this 🎉 |
- Show user to which the scanned file belongs
4a6f584 to
4f9fefe
Compare
|
Backport #32360 |
|
Backport in #32360 has been merged. |
Description
The verifier currently produces false-positives for files which are in filecache but not on the storage.
Related Issue
https://github.com/owncloud/enterprise/issues/2518
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist: