nextcloud / maps

🌍🌏🌎 The whole world fits inside your cloud!
https://apps.nextcloud.com/apps/maps
GNU Affero General Public License v3.0
503 stars 89 forks source link

[Bug]: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'adr' #1296

Open ibahnasy opened 3 months ago

ibahnasy commented 3 months ago

⚠️ This issue respects the following points: ⚠️

Bug description

This error is displayed in a popup when accessing the Maps app:

Failed to load contacts:

Nextcloud

<div id="nojavascript">
<div>
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>
</div>

Nextcloud

Internal Server Error
The server was unable to complete your request.
If this happens again, please send the technical details below to the server administrator.
More details can be found in the server log.

Technical details

Remote Address:  <ip>
Request ID: <id>

Nextcloud 

The 'adr' field is VARCHAR(22)

Steps to reproduce

  1. Open Maps app: https://example.com/apps/maps as normal user not as admin.

Expected behavior

App should load without error and function properly.

Installation method

Manual installation

Operating system

Debian/Ubuntu

PHP engine version

Other

Web server

Nginx

Database engine version

MariaDB

Is this bug present after an update or on a fresh install of the server?

None

Is this bug present after an update or on a fresh install of the app?

Fresh Nextcloud Maps install (never installed before)

Are you using the Nextcloud Server Encryption module?

Encryption is Enabled

What user-backends are you using?

Configuration report

{
    "system": {
        "loglevel": 2,
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "overwrite.cli.url": "https:\/\/example.com",
        "trusted_domains": [
            "example.com"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "29.0.3.4",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "mysql.utf8mb4": true,
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "memcache.local": "\\OC\\Memcache\\APCu",
        "memcache.distributed": "\\OC\\Memcache\\Redis",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": 0
        },
        "twofactor_enforced": "true",
        "twofactor_enforced_groups": [
            "admin",
            "Users",
            "Fresh_Registration"
        ],
        "twofactor_enforced_excluded_groups": [],
        "mail_smtpmode": "smtp",
        "mail_sendmailmode": "smtp",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpauth": 1,
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "465",
        "allow_local_remote_servers": true,
        "mail_smtpsecure": "ssl",
        "mail_smtpstreamoptions": {
            "ssl": {
                "allow_self_signed": true,
                "verify_peer": false,
                "verify_peer_name": false
            }
        },
        "maintenance_window_start": 1,
        "app_install_overwrite": [
            "xwiki"
        ],
        "maintenance": false,
        "theme": "",
        "enforce_theme": "",
        "default_phone_region": "",
        "updater.release.channel": "stable"
    }
}

List of activated Apps

Enabled:
  - bruteforcesettings: 2.9.0
  - calendar: 4.7.11
  - circles: 29.0.0-dev
  - cloud_federation_api: 1.12.0
  - collectives: 2.12.0
  - comments: 1.19.0
  - contacts: 6.0.0
  - contactsinteraction: 1.10.0
  - cospend: 1.6.1
  - dashboard: 7.9.0
  - dav: 1.30.1
  - deck: 1.13.1
  - encryption: 2.17.0
  - federatedfilesharing: 1.19.0
  - federation: 1.19.0
  - files: 2.1.0
  - files_downloadlimit: 2.0.0
  - files_pdfviewer: 2.10.0
  - files_reminders: 1.2.0
  - files_sharing: 1.21.0
  - files_trashbin: 1.19.0
  - files_versions: 1.22.0
  - firstrunwizard: 2.18.0
  - integration_jira: 1.1.0
  - logreader: 2.14.0
  - lookup_server_connector: 1.17.0
  - mail: 3.7.5
  - maps: 1.4.0
  - nextcloud_announcements: 1.18.0
  - notes: 4.10.0
  - notifications: 2.17.0
  - oauth2: 1.17.0
  - password_policy: 1.19.0
  - passwords: 2024.7.20
  - phonetrack: 0.8.1
  - photos: 2.5.0
  - privacy: 1.13.0
  - provisioning_api: 1.19.0
  - qownnotesapi: 24.4.0
  - recommendations: 2.1.0
  - registration: 2.4.0
  - related_resources: 1.4.0
  - serverinfo: 1.19.0
  - settings: 1.12.0
  - sharebymail: 1.19.0
  - spreed: 19.0.7
  - support: 1.12.0
  - survey_client: 1.17.0
  - systemtags: 1.19.0
  - tasks: 0.16.0
  - text: 3.10.1
  - theming: 2.4.0
  - theming_customcss: 1.16.0
  - twofactor_backupcodes: 1.18.0
  - twofactor_totp: 11.0.0-dev
  - updatenotification: 1.19.1
  - user_status: 1.9.0
  - viewer: 2.3.0
  - workflowengine: 2.11.0
  - xwiki: 0.1.2
Disabled:
  - activity: 2.21.1 (installed 2.20.0)
  - admin_audit: 1.19.0
  - breezedark: 28.0.0 (installed 28.0.0)
  - files_external: 1.21.0
  - registertocontact: 0.0.1 (installed 0.0.1)
  - secrets: 2.0.2 (installed 2.0.2)
  - side_menu: 3.13.1 (installed 3.13.1)
  - suspicious_login: 7.0.0 (installed 6.0.0)
  - text2image_stablediffusion: 1.0.2 (installed 1.0.2)
  - user_ldap: 1.20.0
  - weather_status: 1.9.0 (installed 1.9.0)

Nextcloud Signing status

No errors have been found.

Nextcloud Logs

[index] Error: An exception occurred while executing a query: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'adr' at row 1
    GET /apps/maps/contacts
    from <ip> by <username> at Jul 17, 2024, 12:53:38 PM

Browser Console

Request:

GET /apps/maps/contacts HTTP/2
Host: example.com
User-Agent: 
Accept: application/json, text/plain, */*
Accept-Language: en-US
Accept-Encoding: gzip, deflate, br, zstd
X-Requested-With: XMLHttpRequest
requesttoken: 
DNT: 1
Sec-GPC: 1
Connection: keep-alive
Cookie: __Host-nc_sameSiteCookielax=true; __Host-nc_sameSiteCookiestrict=true; nc_username=<username>; nc_token=<token>; nc_session_id=<session_id>; oc_sessionPassphrase=<>;
Sec-Fetch-Dest: empty
Sec-Fetch-Mode: cors
Sec-Fetch-Site: same-origin
Pragma: no-cache
Cache-Control: no-cache
TE: trailers

Response:

HTTP/2 500 
server: nginx
date: Wed, 17 Jul 2024 10:25:51 GMT
content-type: text/html; charset=UTF-8
expires: Thu, 19 Nov 1981 08:52:00 GMT
cache-control: no-store, no-cache, must-revalidate
pragma: no-cache
content-security-policy: default-src 'self'; script-src 'self' 'nonce-'; style-src 'self' 'unsafe-inline'; frame-src *; img-src * data: blob:; font-src 'self' data:; media-src *; connect-src *; object-src 'none'; base-uri 'self';
referrer-policy: no-referrer
x-content-type-options: nosniff
x-frame-options: SAMEORIGIN
x-permitted-cross-domain-policies: none
x-robots-tag: noindex, nofollow
x-xss-protection: 1; mode=block
X-Firefox-Spdy: h2


### Additional info

_No response_
ibahnasy commented 3 months ago

Any update on that issue please?