Can't use app data after upgrade to NC 13.0.0

For a while I’ve been running a script based on pyocclient that manipulates data in the app data store to keep track of what it’s doing. Since upgrading to Nextcloud 13.0.0, it’s suddenly started failing. I’ve reduced it down to this single example Python script. You need to do pip install pyocclient to be able to run it (or however you want to install dependencies). Put in the appropriate credentials and execute it to test.

#!/usr/bin/env python3

import owncloud

DOMAIN = "https://nextcloud.../"
USER = ""
APP_NAME = 'some-test-app'

oc = owncloud.Client(DOMAIN)
oc.login(USER, PASSWORD)
attrs = oc.get_attribute(APP_NAME)

from pprint import pprint

With a Nextcloud server <= 12, this script runs fine — even if you have no data stored for APP_NAME, you’ll just get an empty list back. Just to be clear, APP_NAME is made up, it doesn’t have to correspond to any installed app to work.

Under 13, the script throws an exception ending in:

owncloud.owncloud.OCSResponseError: OCS error: 998

What’s changed that might cause this? I realise that this is an Owncloud library, not a Nextcloud library, but since Nextcloud doesn’t publish a Python library, this is all I’ve got to work with.

The error 998 says that the object was not found:

Are you sure the app is installed? Can you reproduce this test with the demo instances


In this case, it’s probably the best to report it directly to the developers on Normally owncloud and Nextcloud were close enough that this library should work on both.

It was not previously necessary to have an app installed to use app data. Are there any instructions on how to “install” an app that has no presence on the server itself?

I’ll take your advice an report it on Github though. Perhaps it was a loophole or security issue they’ve now fixed.

The pyocclient is nice for testing and automatize certain things. I hope they will fix it…

1 Like