You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some contacts stored in the oc_cards table of my Nextcloud instance have a URL as uid. This breaks the contacts menu and causes the following warning in nextcloud.log:
Parameter "contact" for route "contacts.contacts.direct" must match "[^/]++" ("https://Username@mycloud.example.org/remote.php/carddav/addressbooks/Username/contacts/d9efda0aea.vcf~contacts" given) to generate a corresponding URL.
Full error message (formatted and slightly anonymized)
I've been having this same problem, it's a real nuisance error message, but I don't think it has any real impact on anything - but I am certainly no expert!
Anyway, I think I've got rid of my error here by doing a bit of database admin:
I use postgres as db backend, but the basic statements should be the same.
first, find the properties that have a slash in them:
select*from oc_cards_properties where name ='UID'and value like'%/%';
this will likely show you a list of contact properties where the UID contains a slash - take note of the "cardid" for them all
Then, take a record of the contact properties of the above:
select*from oc_cards_properties where cardid in ( ## a comma separated list of the ids from the previous select statement, i.e. 10,42,43... ## );
take note of this information, as you're going to delete the contact and re-add it
delete the problem contacts
deletefrom oc_cards_properties where cardid in (## comma separated id list as above ##);# and #deletefrom oc_cards where cardid in (## comma separated id list as above ##);
That should remove the problem contacts from the database, then just simply re-add the contacts from the nextcloud contacts front end - they should get added with correct UIDs without slashes
Of course, this assumes you have access to the database, if you don't then I'm not really sure what you can do here as you can't even delete the contacts as they won't be showing in the contacts list.
Of course, this assumes you have access to the database, if you don't then I'm not really sure what you can do here as you can't even delete the contacts as they won't be showing in the contacts list.
For me, all contacts are shown correctly in the Contacts app and can be accessed. I think it is just the contacts menu (and maybe the global search) in the Nextcloud main interface that struggles with this.
Bug description
Some contacts stored in the
oc_cards
table of my Nextcloud instance have a URL as uid. This breaks the contacts menu and causes the following warning in nextcloud.log:Full error message (formatted and slightly anonymized)
The entry with
uri
"d9efda0aea.vcf" in theoc_cards
table in this example has auid
of "https://Username@mycloud.example.org/remote.php/carddav/addressbooks/Username/contacts/d9efda0aea.vcf".Steps to reproduce
Expected behavior
No errors should be produced and the contacts menu should work.
Installation method
None
Nextcloud Server version
28
Operating system
Debian/Ubuntu
PHP engine version
PHP 8.2
Web server
Nginx
Database engine version
MariaDB
Is this bug present after an update or on a fresh install?
None
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
No response
The text was updated successfully, but these errors were encountered: