Non-integer key in _getTagIds

Bug #918255 reported by Paul Everitt
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
KARL3
Fix Released
High
Chris Rossi

Bug Description

Wed Jan 18 10:31:21 2012 Exception when processing https://karl.soros.org/communities/justice-initiative-administration/files/staff/ Referer: None Traceback (most recent call last): File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/errorlog.py", line 18, in middleware return app(environ, start_response) File "/srv/osfkarl/production/39/eggs/repoze.retry-0.9.4-py2.6.egg/repoze/retry/__init__.py", line 88, in __call__ app_iter = self.application(environ, replace_start_response) File "/srv/osfkarl/production/39/eggs/repoze.zodbconn-0.11-py2.6.egg/repoze/zodbconn/connector.py", line 21, in __call__ result = self.next_app(environ, start_response) File "/srv/osfkarl/production/39/eggs/repoze.tm2-1.0a5-py2.6.egg/repoze/tm/__init__.py", line 23, in __call__ result = self.application(environ, save_status_and_headers) File "/srv/osfkarl/production/39/eggs/repoze.who-1.0.15-py2.6.egg/repoze/who/middleware.py", line 107, in __call__ app_iter = app(environ, wrapper.wrap_start_response) File "/srv/osfkarl/production/39/eggs/repoze.urchin-0.2-py2.6.egg/repoze/urchin/__init__.py", line 53, in __call__ resp = req.get_response(self.app) File "/srv/osfkarl/production/39/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py", line 1086, in get_response application, catch_exc_info=False) File "/srv/osfkarl/production/39/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py", line 1055, in call_application app_iter = application(self.environ, start_response) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py", line 176, in __call__ response = self.handle_request(request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/tweens.py", line 17, in excview_tween response = handler(request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py", line 153, in handle_request response = view_callable(context, request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py", line 186, in _secured_view return view(context, request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py", line 292, in rendered_view result = view(context, request) File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/content/views/files.py", line 172, in show_folder_view tagbox = get_tags_client_data(context, request), File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/views/tags.py", line 61, in get_tags_client_data records = tagquery.tagswithcounts, File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/models/adapters.py", line 218, in tagswithcounts tagObjects = self.tags.getTagObjects(items=(self.docid,)) File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/tagging/__init__.py", line 153, in getTagObjects ids = self._getTagIds(items, users, tags, community) File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/tagging/__init__.py", line 448, in _getTagIds res.update(bt.get(item, set())) TypeError: expected integer key

Tags: r3.81
Revision history for this message
Paul Everitt (paul-agendaless) wrote :

Made Carlos nosy on this.

This is a moderately high priority bug, as it is preventing the Justice Initiative from getting at some files. Carlos, if Shane can't work on it today, can you? Probably a higher priority than other stuff you are working on.

Revision history for this message
Shane Hathaway (shane-hathawaymix) wrote :

Unassigned myself so others can take this as soon as they are available.

Changed in karl3:
importance: Low → High
assignee: Shane Hathaway (shane-hathawaymix) → nobody
Changed in karl3:
assignee: nobody → Carlos de la Guardia (cguardia)
Changed in karl3:
status: New → In Progress
Revision history for this message
Carlos de la Guardia (cguardia) wrote :

There seems to be some problem with the catalog, as this issue is caused by a query with an existing path returning None as docid when getting the tag objects. I put in a fix for the tags, so the page should at least not crash when this happens. However, I think we must investigate the root cause as well.

Revision history for this message
Paul Everitt (paul-agendaless) wrote : Re: [Bug 918255] Non-integer key in _getTagIds
Download full text (3.9 KiB)

Carlos, if it's ok with you, I'd like to close this ticket and make a new ticket for the investigation. Since I don't know what you have in mind, I'd like you to make the new ticket, reference this ticket from it, and mark this ticket as Fix Committed.

--Paul

On Jan 20, 2012, at 7:21 PM, Carlos de la Guardia wrote:

> There seems to be some problem with the catalog, as this issue is caused
> by a query with an existing path returning None as docid when getting
> the tag objects. I put in a fix for the tags, so the page should at
> least not crash when this happens. However, I think we must investigate
> the root cause as well.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/918255
>
> Title:
> Non-integer key in _getTagIds
>
> Status in KARL3:
> In Progress
>
> Bug description:
>
> Wed Jan 18 10:31:21 2012 Exception when processing https://karl.soros.org/communities/justice-initiative-administration/files/staff/ Referer: None Traceback (most recent call last): File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/errorlog.py", line 18, in middleware return app(environ, start_response) File "/srv/osfkarl/production/39/eggs/repoze.retry-0.9.4-py2.6.egg/repoze/retry/__init__.py", line 88, in __call__ app_iter = self.application(environ, replace_start_response) File "/srv/osfkarl/production/39/eggs/repoze.zodbconn-0.11-py2.6.egg/repoze/zodbconn/connector.py", line 21, in __call__ result = self.next_app(environ, start_response) File "/srv/osfkarl/production/39/eggs/repoze.tm2-1.0a5-py2.6.egg/repoze/tm/__init__.py", line 23, in __call__ result = self.application(environ, save_status_and_headers) File "/srv/osfkarl/production/39/eggs/repoze.who-1.0.15-py2.6.egg/repoze/who/middleware.py", line 107, in __call__ app_iter = app(environ, wrapper.wrap_start_response) File "/srv/osfkarl/production/39/eggs/repoze.urchin-0.2-py2.6.egg/repoze/urchin/__init__.py", line 53, in __call__ resp = req.get_response(self.app) File "/srv/osfkarl/production/39/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py", line 1086, in get_response application, catch_exc_info=False) File "/srv/osfkarl/production/39/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py", line 1055, in call_application app_iter = application(self.environ, start_response) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py", line 176, in __call__ response = self.handle_request(request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/tweens.py", line 17, in excview_tween response = handler(request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py", line 153, in handle_request response = view_callable(context, request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py", line 186, in _secured_view return view(context, request) File "/srv/osfkarl/production/39/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py", line 292, in rendered_view result = view(context, request) File "/srv/osfkarl/production/39/eggs/karl-3.80-py2.6.egg/karl/content/views/files.py", line 172, in show_folder_view tagbox = get_tags_cl...

Read more...

Changed in karl3:
status: In Progress → Fix Committed
Revision history for this message
JimPGlenn (jpglenn09) wrote :
Download full text (3.2 KiB)

Testing on branch 1 resulted in an error when clicking on second folder named staff. The error is :

Tue Jan 31 11:06:38 2012 Exception when processing https://karlstaging.gocept.com/branch1/osf/communities/justice-initiative-administration/files/staff Referer: https://karlstaging.gocept.com/branch1/osf/communities/justice-initiative-administration/files/ Traceback (most recent call last): File "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/errorlog.py", line 18, in middleware return app(environ, start_response) File "/srv/osfkarltest/staging/branch1/eggs/repoze.retry-0.9.4-py2.6.egg/repoze/retry/__init__.py", line 88, in __call__ app_iter = self.application(environ, replace_start_response) File "/srv/osfkarltest/staging/branch1/eggs/repoze.zodbconn-0.11-py2.6.egg/repoze/zodbconn/connector.py", line 21, in __call__ result = self.next_app(environ, start_response) File "/srv/osfkarltest/staging/branch1/eggs/repoze.tm2-1.0a5-py2.6.egg/repoze/tm/__init__.py", line 23, in __call__ result = self.application(environ, save_status_and_headers) File "/srv/osfkarltest/staging/branch1/eggs/repoze.who-1.0.15-py2.6.egg/repoze/who/middleware.py", line 107, in __call__ app_iter = app(environ, wrapper.wrap_start_response) File "/srv/osfkarltest/staging/branch1/eggs/repoze.urchin-0.2-py2.6.egg/repoze/urchin/__init__.py", line 53, in __call__ resp = req.get_response(self.app) File "/srv/osfkarltest/staging/branch1/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py", line 1086, in get_response application, catch_exc_info=False) File "/srv/osfkarltest/staging/branch1/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py", line 1055, in call_application app_iter = application(self.environ, start_response) File "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py", line 176, in __call__ response = self.handle_request(request) File "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/tweens.py", line 17, in excview_tween response = handler(request) File "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py", line 153, in handle_request response = view_callable(context, request) File "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py", line 186, in _secured_view return view(context, request) File "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py", line 292, in rendered_view result = view(context, request) File "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/content/views/files.py", line 172, in show_folder_view tagbox = get_tags_client_data(context, request), File "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/views/tags.py", line 61, in get_tags_client_data records = tagquery.tagswithcounts, File "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/models/adapters.py", line 218, in tagswithcounts tagObjects = self.tags.getTagObjects(items=(self.docid,)) File "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/tagging/__init__.py", line 153, in getTagObjects ids = self._getTagIds(items, users, tags, community) File "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6...

Read more...

Revision history for this message
Paul Everitt (paul-agendaless) wrote :
Download full text (6.8 KiB)

Shane, I think this review means today isn't a good day for deployment.

On Jan 31, 2012, at 11:09 AM, JimPGlenn wrote:

> Testing on branch 1 resulted in an error when clicking on second folder
> named staff. The error is :
>
> Tue Jan 31 11:06:38 2012 Exception when processing
> https://karlstaging.gocept.com/branch1/osf/communities/justice-
> initiative-administration/files/staff Referer:
> https://karlstaging.gocept.com/branch1/osf/communities/justice-
> initiative-administration/files/ Traceback (most recent call last): File
> "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/errorlog.py",
> line 18, in middleware return app(environ, start_response) File
> "/srv/osfkarltest/staging/branch1/eggs/repoze.retry-0.9.4-py2.6.egg/repoze/retry/__init__.py",
> line 88, in __call__ app_iter = self.application(environ,
> replace_start_response) File
> "/srv/osfkarltest/staging/branch1/eggs/repoze.zodbconn-0.11-py2.6.egg/repoze/zodbconn/connector.py",
> line 21, in __call__ result = self.next_app(environ, start_response)
> File
> "/srv/osfkarltest/staging/branch1/eggs/repoze.tm2-1.0a5-py2.6.egg/repoze/tm/__init__.py",
> line 23, in __call__ result = self.application(environ,
> save_status_and_headers) File
> "/srv/osfkarltest/staging/branch1/eggs/repoze.who-1.0.15-py2.6.egg/repoze/who/middleware.py",
> line 107, in __call__ app_iter = app(environ,
> wrapper.wrap_start_response) File
> "/srv/osfkarltest/staging/branch1/eggs/repoze.urchin-0.2-py2.6.egg/repoze/urchin/__init__.py",
> line 53, in __call__ resp = req.get_response(self.app) File
> "/srv/osfkarltest/staging/branch1/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py",
> line 1086, in get_response application, catch_exc_info=False) File
> "/srv/osfkarltest/staging/branch1/eggs/WebOb-1.1.1-py2.6.egg/webob/request.py",
> line 1055, in call_application app_iter = application(self.environ,
> start_response) File
> "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py",
> line 176, in __call__ response = self.handle_request(request) File
> "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/tweens.py",
> line 17, in excview_tween response = handler(request) File
> "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/router.py",
> line 153, in handle_request response = view_callable(context, request)
> File
> "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py",
> line 186, in _secured_view return view(context, request) File
> "/srv/osfkarltest/staging/branch1/eggs/pyramid-1.2.1-py2.6.egg/pyramid/config/views.py",
> line 292, in rendered_view result = view(context, request) File
> "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/content/views/files.py",
> line 172, in show_folder_view tagbox = get_tags_client_data(context,
> request), File
> "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/views/tags.py",
> line 61, in get_tags_client_data records = tagquery.tagswithcounts, File
> "/srv/osfkarltest/staging/branch1/eggs/karl-3.80-py2.6.egg/karl/models/adapters.py",
> line 218, in tagswithcounts tagObjects =
> self.tags.getTagObjects(items=(self.docid,)) File
> "/s...

Read more...

Revision history for this message
Paul Everitt (paul-agendaless) wrote :

Oops, this was Carlos that worked on this.

Carlos, we just tested on branch1 and it didn't seem to fix it.

Changed in karl3:
milestone: m88 → none
status: Fix Committed → In Progress
milestone: none → m89
Revision history for this message
Paul Everitt (paul-agendaless) wrote :

Actually, sorry to interrupt, but Chris perhaps you could look at this in time for a production update tomorrow. Shane might not be available in time.

If so, change it to you.

Changed in karl3:
assignee: Carlos de la Guardia (cguardia) → Chris Rossi (chris-archimedeanco)
Changed in karl3:
status: In Progress → Fix Committed
JimPGlenn (jpglenn09)
tags: added: r3.81
Revision history for this message
JimPGlenn (jpglenn09) wrote :

fixed

Changed in karl3:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.