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
@matteotrubini it might be worth pointing out that the varcharmax configuration item is removed in Winter v1.2 since it was a workaround for older version of MySQL / MariaDB that are no longer supported in Winter v1.2 so this may become a non-issue.
You are right, but what's happens if someone install on / upgrades an existing DB? As varchar columns were created with that lenght, the limit still apply.
wn-translate-plugin/updates/v2.1.0/migrate_message_code.php
Line 75 in 7e9f37f
is ported from
wn-translate-plugin/models/Message.php
Line 309 in 7fa0de3
but it will trown an error in case of MySQL default config with
varcharmax = 191
(see https://github.com/wintercms/winter/blob/ec46549b21893d39c15261aa237e49c9c0680fbb/config/database.php#L70)I think we need to get limit value using the same logic used here:
https://github.com/wintercms/winter/blob/ec46549b21893d39c15261aa237e49c9c0680fbb/modules/system/ServiceProvider.php#L624-L642
of even better, we can check the current table schema with
Schema::getConnection()->getDoctrineColumn(self::TABLE_NAME, 'code')->getLength()
, but this should be tested against all supported databases to check returned values (I don't have this kind of expertise).The text was updated successfully, but these errors were encountered: