[2.1] expected string or bytes-like object
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Fix Released
|
Critical
|
Blake Rouse |
Bug Description
When accessing MAAS UI:
I see:
Error ocurred
expected string or bytes-like object
With these errors in the log:
2016-09-24 18:39:55 [-] Error on request (24) discovery.list: expected string or bytes-like object
Traceback (most recent call last):
File "/usr/lib/
File "/usr/lib/
return target()
File "/usr/lib/
task()
File "/usr/lib/
task()
--- <exception caught here> ---
File "/usr/lib/
result = inContext.theWork()
File "/usr/lib/
File "/usr/lib/
return self.currentCon
File "/usr/lib/
return func(*args,**kw)
File "/usr/lib/
return func(*args, **kwargs)
File "/usr/lib/
return func_outside_
File "/usr/lib/
return func(*args, **kwargs)
File "/usr/lib/
return func(*args, **kwds)
File "/usr/lib/
File "/usr/lib/
return self._filter_
File "/usr/lib/
File "/usr/lib/
clause, require_inner = self._add_
File "/usr/lib/
File "/usr/lib/
File "/usr/lib/
return final_lookup(lhs, rhs)
File "/usr/lib/
File "/usr/lib/
return self.lhs.
File "/usr/lib/
return super(DateField, self).get_
File "/usr/lib/
return self.get_
File "/usr/lib/
value = super(DateTimeF
File "/usr/lib/
return self.to_
File "/usr/lib/
parsed = parse_datetime(
File "/usr/lib/
match = datetime_
Related branches
- Gavin Panella (community): Approve
-
Diff: 92 lines (+68/-0)1 file modifiedsrc/maasserver/monkey.py (+68/-0)
- MAAS Maintainers: Pending requested
-
Diff: 45 lines (+23/-1)1 file modifiedsrc/maasserver/websockets/handlers/discovery.py (+23/-1)
- Gavin Panella (community): Approve
-
Diff: 112 lines (+36/-6)4 files modifiedsrc/maasserver/static/js/angular/factories/discoveries.js (+1/-0)
src/maasserver/websockets/base.py (+6/-0)
src/maasserver/websockets/handlers/discovery.py (+3/-3)
src/maasserver/websockets/handlers/tests/test_discovery.py (+26/-3)
- Mike Pontillo (community): Abstain
- Andres Rodriguez (community): Approve
-
Diff: 296 lines (+87/-40)7 files modifiedsrc/maasserver/static/js/angular/controllers/tests/test_dashboard.js (+4/-4)
src/maasserver/static/js/angular/factories/discoveries.js (+2/-1)
src/maasserver/static/js/angular/factories/tests/test_discoveries.js (+2/-1)
src/maasserver/static/partials/dashboard.html (+7/-7)
src/maasserver/testing/sampledata.py (+21/-18)
src/maasserver/websockets/handlers/discovery.py (+25/-8)
src/maasserver/websockets/handlers/tests/test_discovery.py (+26/-1)
Changed in maas: | |
milestone: | none → 2.1.0 |
importance: | Undecided → Critical |
Changed in maas: | |
status: | New → Triaged |
tags: | added: oil |
Changed in maas: | |
assignee: | Mike Pontillo (mpontillo) → Blake Rouse (blake-rouse) |
status: | Triaged → In Progress |
Changed in maas: | |
status: | In Progress → Fix Committed |
Changed in maas: | |
status: | Fix Committed → Fix Released |
If this happens again, we'll need the contents of the discovery view. (You can get that with "sudo maas-region dbshell" and then "select * from maasserver_ discovery; ".)
It seems like the only time this should ever happen is if the database returns an invalid (or NULL?) value for one of the datetime fields in the view. But those should never be missing, so it's hard to say why this would be happening.