-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
[Bug]: occ versions:expire doesn't work on NC 26 #37527
Comments
With Nextcloud 26.0.0.11, I encounter a different error/stacktrace on
Nextcloud log also contains this line with the same timestamp as the above event: And finally, this: (anyone knows how to break long lines?)
The file in question, |
I can reproduce the issue on file upload {
"reqId": "CTudhUurLxOS27C3TxUV",
"level": 3,
"time": "2023-04-29T06:57:24+00:00",
"remoteAddr": "xxx.xxx.xxx.xxx",
"user": "xxxxxxxxxxx",
"app": "no app in context",
"method": "PUT",
"url": "/remote.php/dav/files/xxxxxxxxxx/InstantUpload/2023/04/20230409_174200.jpg",
"message": "Did expect one result but found none when executing: query \"SELECT * FROM `*PREFIX*files_versions` WHERE (`file_id` = :dcValue1) AND (`timestamp` = :dcValue2)\"; ",
"userAgent": "Mozilla/5.0 (Linux) mirall/3.8.1git (Nextcloud, arch-6.2.12-arch1-1 ClientArchitecture: x86_64 OsArchitecture: x86_64)",
"version": "26.0.1.1",
"exception": {
"Exception": "OCP\\AppFramework\\Db\\DoesNotExistException",
"Message": "Did expect one result but found none when executing: query \"SELECT * FROM `*PREFIX*files_versions` WHERE (`file_id` = :dcValue1) AND (`timestamp` = :dcValue2)\"; ",
"Code": 0,
"Trace": [
{
"file": "/var/www/html/lib/public/AppFramework/Db/QBMapper.php",
"line": 361,
"function": "findOneQuery",
"class": "OCP\\AppFramework\\Db\\QBMapper",
"type": "->",
"args": [
[
"OC\\DB\\QueryBuilder\\QueryBuilder"
]
]
},
{
"file": "/var/www/html/apps/files_versions/lib/Db/VersionsMapper.php",
"line": 78,
"function": "findEntity",
"class": "OCP\\AppFramework\\Db\\QBMapper",
"type": "->",
"args": [
[
"OC\\DB\\QueryBuilder\\QueryBuilder"
]
]
},
{
"file": "/var/www/html/apps/files_versions/lib/Listener/FileEventsListener.php",
"line": 242,
"function": "findVersionForFileId",
"class": "OCA\\Files_Versions\\Db\\VersionsMapper",
"type": "->",
"args": [
180544,
1681139688
]
},
{
"file": "/var/www/html/apps/files_versions/lib/Listener/FileEventsListener.php",
"line": 106,
"function": "post_write_hook",
"class": "OCA\\Files_Versions\\Listener\\FileEventsListener",
"type": "->",
"args": [
[
"OC\\Files\\Node\\File"
]
]
},
{
"file": "/var/www/html/lib/private/EventDispatcher/ServiceEventListener.php",
"line": 86,
"function": "handle",
"class": "OCA\\Files_Versions\\Listener\\FileEventsListener",
"type": "->",
"args": [
[
"OCP\\Files\\Events\\Node\\NodeWrittenEvent"
]
]
},
{
"file": "/var/www/html/3rdparty/symfony/event-dispatcher/EventDispatcher.php",
"line": 251,
"function": "__invoke",
"class": "OC\\EventDispatcher\\ServiceEventListener",
"type": "->",
"args": [
[
"OCP\\Files\\Events\\Node\\NodeWrittenEvent"
],
"OCP\\Files\\Events\\Node\\NodeWrittenEvent",
[
"Symfony\\Component\\EventDispatcher\\EventDispatcher"
]
]
},
{
"file": "/var/www/html/3rdparty/symfony/event-dispatcher/EventDispatcher.php",
"line": 73,
"function": "callListeners",
"class": "Symfony\\Component\\EventDispatcher\\EventDispatcher",
"type": "->",
"args": [
[
[
"Closure"
],
[
"Closure"
],
[
"Closure"
]
],
"OCP\\Files\\Events\\Node\\NodeWrittenEvent",
[
"OCP\\Files\\Events\\Node\\NodeWrittenEvent"
]
]
},
{
"file": "/var/www/html/lib/private/EventDispatcher/EventDispatcher.php",
"line": 87,
"function": "dispatch",
"class": "Symfony\\Component\\EventDispatcher\\EventDispatcher",
"type": "->",
"args": [
[
"OCP\\Files\\Events\\Node\\NodeWrittenEvent"
],
"OCP\\Files\\Events\\Node\\NodeWrittenEvent"
]
},
{
"file": "/var/www/html/lib/private/EventDispatcher/EventDispatcher.php",
"line": 99,
"function": "dispatch",
"class": "OC\\EventDispatcher\\EventDispatcher",
"type": "->",
"args": [
"OCP\\Files\\Events\\Node\\NodeWrittenEvent",
[
"OCP\\Files\\Events\\Node\\NodeWrittenEvent"
]
]
},
{
"file": "/var/www/html/lib/private/Files/Node/HookConnector.php",
"line": 118,
"function": "dispatchTyped",
"class": "OC\\EventDispatcher\\EventDispatcher",
"type": "->",
"args": [
[
"OCP\\Files\\Events\\Node\\NodeWrittenEvent"
]
]
},
{
"file": "/var/www/html/lib/private/legacy/OC_Hook.php",
"line": 105,
"function": "postWrite",
"class": "OC\\Files\\Node\\HookConnector",
"type": "->",
"args": [
[
"/InstantUpload/2023/04/20230409_174200.jpg"
]
]
},
{
"file": "/var/www/html/apps/dav/lib/Connector/Sabre/File.php",
"line": 471,
"function": "emit",
"class": "OC_Hook",
"type": "::",
"args": [
"OC_Filesystem",
"post_write",
[
"/InstantUpload/2023/04/20230409_174200.jpg"
]
]
},
{
"file": "/var/www/html/apps/dav/lib/Connector/Sabre/File.php",
"line": 398,
"function": "emitPostHooks",
"class": "OCA\\DAV\\Connector\\Sabre\\File",
"type": "->",
"args": [
true
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 1137,
"function": "put",
"class": "OCA\\DAV\\Connector\\Sabre\\File",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/CorePlugin.php",
"line": 492,
"function": "updateFile",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/3rdparty/sabre/event/lib/WildcardEmitterTrait.php",
"line": 89,
"function": "httpPut",
"class": "Sabre\\DAV\\CorePlugin",
"type": "->",
"args": [
[
"Sabre\\HTTP\\Request"
],
[
"Sabre\\HTTP\\Response"
]
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 472,
"function": "emit",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
"method:PUT",
[
[
"Sabre\\HTTP\\Request"
],
[
"Sabre\\HTTP\\Response"
]
]
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 253,
"function": "invokeMethod",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
[
"Sabre\\HTTP\\Request"
],
[
"Sabre\\HTTP\\Response"
]
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 321,
"function": "start",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/apps/dav/lib/Server.php",
"line": 366,
"function": "exec",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/apps/dav/appinfo/v2/remote.php",
"line": 35,
"function": "exec",
"class": "OCA\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/remote.php",
"line": 172,
"args": [
"/var/www/html/apps/dav/appinfo/v2/remote.php"
],
"function": "require_once"
}
],
"File": "/var/www/html/lib/public/AppFramework/Db/QBMapper.php",
"Line": 284,
"CustomMessage": "--"
}
} |
Cc @artonge |
I'm seeing it by cron-Job run
Running Nextcloud 26.0.1.1 on PostgreSQL with PHP 8.1 |
Closing, as I was not able to reproduce. Feel free to reopen if the issue is still occurring. |
Bug description
It was supposed to be fixed with this PR but it's still happening on a newly updated NC 26 instance.
Cron doesn't behave as it should.
cc @artonge
Steps to reproduce
occ versions:expire -vvv
Expected behavior
Everything should work.
Installation method
Community Manual installation with Archive
Nextcloud Server version
26
Operating system
Debian/Ubuntu
PHP engine version
PHP 8.1
Web server
Apache (supported)
Database engine version
PostgreSQL
Is this bug present after an update or on a fresh install?
Updated to a major version (ex. 22.2.3 to 23.0.1)
Are you using the Nextcloud Server Encryption module?
Encryption is Disabled
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
Nextcloud Logs
Additional info
When running
occ versions:expire -vvv
The text was updated successfully, but these errors were encountered: