Read and tick the following checkbox after you have created the issue or place an x inside the brackets ;)
What problem did you encounter?
__Internal server error!__
InvalidArgumentException: Only strings, Literals and Parameters are allowed
Explain what you did to encounter the issue
Internal server error!
Contents of nextcloud/data/nextcloud.log
``json
{
"reqId": "mIdGWiwzntSZ9oalN4VR",
"level": 3,
"time": "2021-02-14T20:34:45+00:00",
"remoteAddr": "127.0.0.1",
"user": "anoymouserver",
"app": "index",
"method": "GET",
"url": "/apps/news/items?id=3&limit=40&oldestFirst=false&search=&showAll=true&type=1",
"message": {
"Exception": "InvalidArgumentException",
"Message": "Only strings, Literals and Parameters are allowed",
"Code": 0,
"Trace": [{
"file": "/var/www/cloud/lib/private/DB/QueryBuilder/ExpressionBuilder/ExpressionBuilder.php",
"line": 140,
"function": "quoteColumnName",
"class": "OC\\DB\\QueryBuilder\\QuoteHelper",
"type": "->",
"args": [3]
}, {
"file": "/var/www/cloud/apps/news/lib/Db/ItemMapperV2.php",
"line": 476,
"function": "eq",
"class": "OC\\DB\\QueryBuilder\\ExpressionBuilder\\ExpressionBuilder",
"type": "->",
"args": ["feeds.folder_id`", 3]
}, {
"file": "/var/www/cloud/apps/news/lib/Service/ItemServiceV2.php",
"line": 368,
"function": "findAllFolder",
"class": "OCA\News\Db\ItemMapperV2",
"type": "->",
"args": ["anoymouserver", 3, 40, 0, false, false, []]
}, {
"file": "/var/www/cloud/apps/news/lib/Controller/ItemController.php",
"line": 152,
"function": "findAllInFolderWithFilters",
"class": "OCA\News\Service\ItemServiceV2",
"type": "->",
"args": ["anoymouserver", 3, 40, 0, false, false, []]
}, {
"file": "/var/www/cloud/lib/private/AppFramework/Http/Dispatcher.php",
"line": 169,
"function": "index",
"class": "OCA\News\Controller\ItemController",
"type": "->",
"args": [1, 3, 40, 0, true, false, ""]
}, {
"file": "/var/www/cloud/lib/private/AppFramework/Http/Dispatcher.php",
"line": 100,
"function": "executeController",
"class": "OC\AppFramework\Http\Dispatcher",
"type": "->",
"args": [{
"__class__": "OCA\News\Controller\ItemController"
}, "index"]
}, {
"file": "/var/www/cloud/lib/private/AppFramework/App.php",
"line": 152,
"function": "dispatch",
"class": "OC\AppFramework\Http\Dispatcher",
"type": "->",
"args": [{
"__class__": "OCA\News\Controller\ItemController"
}, "index"]
}, {
"file": "/var/www/cloud/lib/private/Route/Router.php",
"line": 309,
"function": "main",
"class": "OC\AppFramework\App",
"type": "::",
"args": ["OCA\News\Controller\ItemController", "index", {
"__class__": "OC\AppFramework\DependencyInjection\DIContainer"
}, {
"_route": "news.item.index"
}
]
}, {
"file": "/var/www/cloud/lib/base.php",
"line": 1008,
"function": "match",
"class": "OC\Route\Router",
"type": "->",
"args": ["/apps/news/items"]
}, {
"file": "/var/www/cloud/index.php",
"line": 37,
"function": "handleRequest",
"class": "OC",
"type": "::",
"args": []
}
],
"File": "/var/www/cloud/lib/private/DB/QueryBuilder/QuoteHelper.php",
"Line": 62,
"CustomMessage": "--"
},
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:85.0) Gecko/20100101 Firefox/85.0",
"version": "20.0.7.1",
"id": "6029898465050"
}
Just noticed that the loading of further items when scrolling down doesn't work either.
The following requests are copied for the 'Unread articles' section, but the issue also occures for a single feed.
jsonc
{"newestItemId":129155,"feeds":[/* list of feeds */],"starred":543,"items":[/* list of items */]}
jsonc
{"items":[]}
Furthermore the 'All articles' section doesn't return any items at all.
jsonc
{"newestItemId":129155,"feeds":[/* list of feeds */],"starred":543}
https://cloud.example.com/apps/news/items?limit=40&offset=129116&oldestFirst=false&showAll=true&type=6
following requests (after scrolling down) return empty data:
Do you even have that many items in your DB?
Furthermore the 'All articles' section doesn't return any items at all.
https://cloud.example.com/apps/news/items?limit=40&oldestFirst=false&search=&showAll=true&type=3
I didn't realize this was a possible type. Fixed soon.
My test database currently contains 10352 items for 105 feeds (not all unread).
More than 40 unread per folder aren't unusual. The 'offset' however seems to be the lowest id of the currently displayed items (if most recent on top) and not a real offset (number of items which should be skipped)
Highest id is 129155, since there are 40 displayed, the last of them is 129116 (offset from my request url).
The 'offset' however seems to be the lowest id of the currently displayed items (if most recent on top) and not a real offset (number of items which should be skipped)
This app really seems to be written around a desire for the most complex implementations. I'll see if that is fixable.
Most helpful comment
This app really seems to be written around a desire for the most complex implementations. I'll see if that is fixable.