| Summary: |
mysql requires unicode and char length filtering |
| Product: |
[Build System, Metadata & Runtime] Toaster
|
Reporter: |
David Reyna <david.reyna> |
| Component: |
toaster | Assignee: |
David Reyna <david.reyna> |
| Status: |
IN PROGRESS IMPLEMENTATION
---
|
QA Contact: |
Toaster default assignee <toaster> |
| Severity: |
normal
|
|
|
| Priority: |
Medium+
|
CC: |
jessica.zhang, mingli.yu, randy.macleod, stanciux.mihail
|
| Version: |
2.5 | |
|
| Target Milestone: |
6.0 | |
|
| Hardware: |
x86 | |
|
| OS: |
Multiple | |
|
| Whiteboard: |
|
|
OS type for building Yocto:
|
---
|
Type of Regression:
|
---
|
|
Verified:
|
|
Documentation change:
|
No (bug/feature does not impact docs)
|
| Attachments: |
|
The MySQL database is more sensitive to content exceptions that Sqlite. Toaster needs additional filtering on problematic data to be correct for both database and not fail for MySql. Observed issues causing fails in MySql: (a) Unicode characters are appearing in layer descriptions ('\\xC2\\x96', "meta-crosswalk") (b) Some layer URL's exceed 200 characters (204 characters, "meta-nexell") (c) Some recipe licenses exceed 200 characters (1451 characters, "linux-firmware") NOTE: the MySQL docs imply a max character length of 256, but 204 characters fail in reality. The solution is: (a) Filter unicode, e.g. li['description'].encode('ascii','replace') (b) Add proactive filter for char fields, e.g. generally enforce char limits, truncate then append a " ..." for extra long fields (c) Promote some Char fields to un-limited Text fields