SuiteCRM-Core icon indicating copy to clipboard operation
SuiteCRM-Core copied to clipboard

Feedback on 8.9.0 beta (schema differences, outdated packages, documentation)

Open restena-sw opened this issue 10 months ago • 2 comments

Issue

I have updated from 8.6.2 to 8.9.0-beta in our test env. It generally worked, but some comments that I hope may be interesting.

  1. After updating schema, there is a "fight" between schema:upgrade and the Quick Repair and Rebuild. After running schema:upgrade, the Repair and Rebuild suggests:
/* Table : users */
/*COLUMNS*/
/*MISMATCH WITH DATABASE - backup_codes -  ROW [name] => 'backup_codes'  [type] => 'longtext'  */
/* VARDEF - backup_codes -  ROW[name] => 'backup_codes'  [type] => 'text'  [dbType] => 'text'  [len] => ''  [required] => ''  */
/* INDEXES */
ALTER TABLE users   modify COLUMN `backup_codes` text  NULL ;

But if I do that, a subsequent run of schema:upgrade tells me:

doctrine:schema:update --dump-sql --complete
ALTER TABLE users CHANGE backup_codes backup_codes JSON DEFAULT NULL COMMENT '(DC2Type:json)';

And if I do that - back to the Repair and Rebuild suggested change, looping.

2.1) I fixed that my-side with a composer update and re-zipping the update file. All worked perfectly fine like that, but would it not be an idea to ship with the most recent currently available dependencies?

3.1) Due to the combination of MariaDB version and the code, I had a really hard time making schema:upgrade happy. Our MariaDB is a) 10.11 but b) was 10.5 or so by the time we first installed SuiteCRM. It now returns the collation as "utf8mb3_general_ci" after the schema:upgrade scripts sets it to "utf8_general_ci" (the two are the same, but the server's output always includes the mb3 part). The only place with issues is the "users" table, for whatever reason. It is only cosmetic, but any subsequent run of schema:upgrade will complain that there is one difference that needs be applied. And it then allegedly successfully applied. But next time actually shows up again. I found that fixing the source (Users.php to set utf8mb3_general_ci) alone didn't fix it. I also had to set some variables in .env.local:

DB_COLLATION="utf8mb3_general_ci"
DB_CHARSET="utf8mb3"

That, and replacing the collation info in source with

sed -i s/utf8_general_ci/utf8mb3_general_ci/g core/modules/Users/Entity/User.php

together did the trick. It might be worth talking about the interplay of MariaDB versions, installs that predate the default mb4 schema, and these ENV variables.

3.2) The compatibility matrix for 8.9 does not exist yet in the pre-release documentation.

Possible Fix

  1. will probably need a fix in the code, syncing a column definition in two places.

2.1) ship with a contemporary composer.lock file after "composer update"

3.1) as discussed in the report above. Or maybe I found a hacky workaround and the solution is different? Maybe there could even be an upgrade guide on how to move to utf8mb4 for older installs?

3.2) just needs to be done.

Steps to Reproduce the Issue

As per above.

Context

No response

Version

8.9.0-beta

What browser are you currently using?

Chrome

Browser Version

No response

Environment Information

PHP 8.3

Operating System and Version

Debian 12

restena-sw avatar Jun 17 '25 14:06 restena-sw

Thank you for sharing your feedback on the beta release, please note this is not a production release and not intended to be fully up to date in all areas, instead provided to help us test and get feedback on new features.

Generally, most of the issues you have reported are not entirely specific to the Beta and we generally asked that 1 issue is reported per report unless specifically related.

If you want to provide general feedback for the beta release we have set up this forum post --> https://community.suitecrm.com/t/suitecrm-8-9-beta-released/99540 which would be more suitable for the format of providing multiple types items of feedback and ideal for discussion around beta release

Additionally, please bear in mind our security policy when reporting issues, it is not appropriate to directly reports security issues here or in a public place.

mattlorimer avatar Jun 18 '25 14:06 mattlorimer

I experienced same issue with 8.9.0, https://github.com/SuiteCRM/SuiteCRM-Core/issues/788

The columns were not created during the update. With SAML enabled it caused an infinite loop.

vladaman avatar Oct 28 '25 20:10 vladaman