diff options
Diffstat (limited to 'bitbake/lib/toaster/orm')
-rw-r--r-- | bitbake/lib/toaster/orm/models.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/bitbake/lib/toaster/orm/models.py b/bitbake/lib/toaster/orm/models.py index 93b5df3d4e..f9c4fb0508 100644 --- a/bitbake/lib/toaster/orm/models.py +++ b/bitbake/lib/toaster/orm/models.py | |||
@@ -19,9 +19,12 @@ | |||
19 | # with this program; if not, write to the Free Software Foundation, Inc., | 19 | # with this program; if not, write to the Free Software Foundation, Inc., |
20 | # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. | 20 | # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
21 | 21 | ||
22 | from __future__ import unicode_literals | ||
23 | |||
22 | from django.db import models, IntegrityError | 24 | from django.db import models, IntegrityError |
23 | from django.db.models import F, Q, Avg, Max, Sum | 25 | from django.db.models import F, Q, Avg, Max, Sum |
24 | from django.utils import timezone | 26 | from django.utils import timezone |
27 | from django.utils.encoding import force_bytes | ||
25 | 28 | ||
26 | from django.core.urlresolvers import reverse | 29 | from django.core.urlresolvers import reverse |
27 | 30 | ||
@@ -1614,7 +1617,7 @@ class LogMessage(models.Model): | |||
1614 | lineno = models.IntegerField(null=True) | 1617 | lineno = models.IntegerField(null=True) |
1615 | 1618 | ||
1616 | def __str__(self): | 1619 | def __str__(self): |
1617 | return "%s %s %s" % (self.get_level_display(), self.message, self.build) | 1620 | return force_bytes('%s %s %s' % (self.get_level_display(), self.message, self.build)) |
1618 | 1621 | ||
1619 | def invalidate_cache(**kwargs): | 1622 | def invalidate_cache(**kwargs): |
1620 | from django.core.cache import cache | 1623 | from django.core.cache import cache |