Contacts: Unable to access Contact application in nextcloud since 3.1.4 upgrade

Created on 28 Sep 2019  路  17Comments  路  Source: nextcloud/contacts

Done : Reboot vps server (Debian 9.9)
Done : activate / desactivate plugin

Same issue on 2 different server

Find this in nexcloud log

[index] Error: OCP\AppFramework\QueryException: Could not resolve OCA\Contacts\Controller\PageController! Class OCP\IInitialStateService does not exist at <>

  1. /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php line 119
    resolve("OCA\Contacts\ ... r")
  2. /var/www/nextcloud/lib/private/AppFramework/DependencyInjection/DIContainer.php line 426
    query("OCA\Contacts\ ... r")
  3. /var/www/nextcloud/lib/private/AppFramework/DependencyInjection/DIContainer.php line 397
    queryNoFallback("OCA\Contacts\ ... r")
  4. /var/www/nextcloud/lib/private/AppFramework/App.php line 105
    query("OCA\Contacts\ ... r")
  5. /var/www/nextcloud/lib/private/AppFramework/Routing/RouteActionHandler.php line 47
    main("OCA\Contacts\ ... r", "index", OC\AppFramework\ ... {}, {_route: "contacts.page.index"})
  6. <>
    __invoke({_route: "contacts.page.index"})
  7. /var/www/nextcloud/lib/private/Route/Router.php line 297
    call_user_func(OC\AppFramework\ ... {}, {_route: "contacts.page.index"})
  8. /var/www/nextcloud/lib/base.php line 987
    match("/apps/contacts/")
  9. /var/www/nextcloud/index.php line 42
    handleRequest()

GET /nextcloud/index.php/apps/contacts/

1. to develop bug high

Most helpful comment

I just applied the 3.1.6 update to my 15.0.11/3.1.3 install and all looks good now.

Thank you.

All 17 comments

Same issue here after upgrading from 3.1.3.
Contacts 3.1.4
Nextcloud 15.0.12
Debian 9.11

In clicking in nextcloud's "contacts" tab (or link), it throws an internal error webpage.
Very very annoying.. not sure there's an easy way to downgrade.

extract from Nextcloud's log :
{"reqId":"LFOFFMJav1vAy9lTepmx","level":3,"time":"2019-09-28T19:19:33+00:00","remoteAddr":"xx.xx.xx.xx","user":"hb","app":"index","method":"GET","url":"\/nextcloud\/index.php\/apps\/contacts\/","message":{"Exception":"OCP\AppFramework\QueryException","Message":"Could not resolve OCA\Contacts\Controller\PageController! Class OCP\IInitialStateService does not exist","Code":0,"Trace":[{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/private\/AppFramework\/Utility\/SimpleContainer.php","line":119,"function":"resolve","class":"OC\AppFramework\Utility\SimpleContainer","type":"->","args":["OCA\Contacts\Controller\PageController"]},{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/private\/AppFramework\/DependencyInjection\/DIContainer.php","line":426,"function":"query","class":"OC\AppFramework\Utility\SimpleContainer","type":"->","args":["OCA\Contacts\Controller\PageController"]},{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/private\/AppFramework\/DependencyInjection\/DIContainer.php","line":397,"function":"queryNoFallback","class":"OC\AppFramework\DependencyInjection\DIContainer","type":"->","args":["OCA\Contacts\Controller\PageController"]},{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/private\/AppFramework\/App.php","line":105,"function":"query","class":"OC\AppFramework\DependencyInjection\DIContainer","type":"->","args":["OCA\Contacts\Controller\PageController"]},{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/private\/AppFramework\/Routing\/RouteActionHandler.php","line":47,"function":"main","class":"OC\AppFramework\App","type":"::","args":["OCA\Contacts\Controller\PageController","index",{"__class__":"OC\AppFramework\DependencyInjection\DIContainer"},{"_route":"contacts.page.index"}]},{"function":"__invoke","class":"OC\AppFramework\Routing\RouteActionHandler","type":"->","args":[{"_route":"contacts.page.index"}]},{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/private\/Route\/Router.php","line":297,"function":"call_user_func","args":[{"__class__":"OC\AppFramework\Routing\RouteActionHandler"},{"_route":"contacts.page.index"}]},{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/base.php","line":987,"function":"match","class":"OC\Route\Router","type":"->","args":["\/apps\/contacts\/"]},{"file":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/index.php","line":42,"function":"handleRequest","class":"OC","type":"::","args":[]}],"File":"\/mnt\/data\/www.tseuli.ch\/www\/nextcloud\/lib\/private\/AppFramework\/Utility\/SimpleContainer.php","Line":104,"CustomMessage":"--"},"userAgent":"Mozilla\/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/77.0.3865.90 Safari\/537.36","version":"15.0.12.1"}

Hey!
Indeed, there seems to be an incompatibility with nextcloud 15.
Please upgrade to 16 or wait for the new fix of contacts next week!
Sorry :)

Hey!
Indeed, there seems to be an incompatibility with nextcloud 15.
Please upgrade to 16 or wait for the new fix of contacts next week!
Sorry :)

I'm glad you're seeing the same as us.
Upgrading to NC 16 isn't an option with my raspbian/debian distribution (doesn't run php 7.2 as standard), will eagerly wait for the fix. Thank you!

Same here: Nextcloud 15.0.12.
I did a downgrade to Contacts 3.1.3.

  1. Changed the installed version to 3.1.3 in the database table oc_appconfig for the appid contacts (otherwise is was updated automatically to 3.1.4).
  2. Stoped the webserver.
  3. Downloaded the app in version 3.1.3 and replaced the files under /apps/contacts.
  4. Started the webserver.
  5. Contacts is working again.

Upgrading to NC 16 isn't an option with my raspbian/debian distribution

I'm curious, why? 15 is going to be deprecated in 3 months, like 14 currently is :)
Upgrading should be frequent on nextcloud as lots of fixes are pushed in every new version :rocket:

Please upgrade to 16 or wait for the new fix of contacts next week!

I'm on Nextcloud 16 and I still can't access the Contacts app since the update :/

Same here: Nextcloud 15.0.12.
I did a downgrade to Contacts 3.1.3.

  1. Changed the installed version to 3.1.3 in the database table oc_appconfig for the appid contacts (otherwise is was updated automatically to 3.1.4).
  2. Stoped the webserver.
  3. Downloaded the app in version 3.1.3 and replaced the files under /apps/contacts.
  4. Started the webserver.
  5. Contacts is working again.

Thank you, worked well for me (the rollback). Just adding the cmd lines used for the ones who are not using mariadb everyday (myself included).

Connect to nextcloud db. (change nextcloud1 if not the name of your DB)
mysql -uroot -p nextcloud1
check your DB configuration for contacts
>select * from oc_appconfig where appid = 'contacts' ;
update the value from 3.1.4 to 3.1.3
>update oc_appconfig set configvalue = '3.1.3' where appid = 'contacts' AND configkey = 'installed_version' ;

for replacing contacts in the nextcloud/apps folder
wget https://github.com/nextcloud/contacts/releases/download/v3.1.3/contacts.tar.gz
then rename existing contacts folder
mv contacts contacts_3.1.4
then untar in apps
tar xvfz contacts.tar.gz
don't forget to change user/groups
chown -R www-data:www-data contacts

@cgail914 @Kieltux editing the database is not needed theoritecally, just replacing the files should be enough!

Please upgrade to 16 or wait for the new fix of contacts next week!

I'm on Nextcloud 16 and I still can't access the Contacts app since the update :/

Check the logs? It should be another error then, because I'm on 16.0.5 and it works here :)

I'm on Nextcloud 16 and I still can't access the Contacts app since the update :/

Check the logs? It should be another error then, because I'm on 16.0.5 and it works here :)

Well, I got this on the client side:

Uncaught Error: Could not find initial state of contacts
    at Module.m (initialstate.js:31)
    at e.loadState (index.js:10)
    at Module.<anonymous> (rfcProps.js:29)
    at i (bootstrap:63)
    at bootstrap:198
    at contacts.js?v=625d3545-10:1

and this according to Nextcloud's logging:

ResourceLocator can not find a web root (root: /var/snap/nextcloud/16232/nextcloud/extra-apps/contacts, file: index.php/css/contacts/1e49-fcfc-contacts.css?v=743417092b8f695fd7f1c09520bde4e3, webRoot: , throw: true)

Uncaught Error: Could not find initial state of contacts

AH, that is interesting.
Could you open a new issue, this is a slightly different one @sk22.
On the contacts page, right-click and click "show page source", could you screenshot the part just under the line saying
This application requires JavaScript for correct operation. Please <a href="https://www.enable-javascript.com/" target="_blank" rel="noreferrer noopener">enable JavaScript</a> and reload the page.</div>

I'm having the same issue. NC 15.0.11+postgresql+ubuntu xenial

3.1.5 have been dispatched!
Thank for your patience everyone!

I updated from 15.0.11/3.1.3 to 15.0.12/3.1.5 this evening and still seeing a blank page when loading Contacts.

Restored from backup back to 15.0.11/3.1.3.

I just applied the 3.1.6 update to my 15.0.11/3.1.3 install and all looks good now.

Thank you.

I confirme it solved the issue on my side also.
Many thanks

Mine solved! Great work!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

spoorun picture spoorun  路  5Comments

caugner picture caugner  路  3Comments

kangaroo72 picture kangaroo72  路  4Comments

spoorun picture spoorun  路  3Comments

Peque picture Peque  路  3Comments