Closed Bug 1423708 Opened 7 years ago Closed 7 years ago

[traceback] DataError: value too long for type character varying(50)

Categories

(Socorro :: Symbols, task)

task
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: willkg, Assigned: peterbe)

References

Details

Attachments

(1 file)

I added https://symbols.mozilla.org as the third url for Socorro -stage mdsw and then saw a few of these go by:

https://sentry.prod.mozaws.net/operations/symbols-prod/issues/777859/

"""
DataError: value too long for type character varying(50)

  File "django/core/handlers/exception.py", line 41, in inner
    response = get_response(request)
  File "django/core/handlers/base.py", line 249, in _legacy_get_response
    response = self._get_response(request)
  File "django/core/handlers/base.py", line 187, in _get_response
    response = self.process_exception_by_middleware(e, request)
  File "django/core/handlers/base.py", line 185, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "newrelic/hooks/framework_django.py", line 527, in wrapper
    return wrapped(*args, **kwargs)
  File "markus/main.py", line 357, in _timer_decorator
    return fun(*args, **kwargs)
  File "tecken/base/decorators.py", line 79, in wrapper
    return view_func(request, *args, **kwargs)
  File "tecken/base/decorators.py", line 114, in inner
    return func(request, *args, **kwargs)
  File "tecken/base/decorators.py", line 144, in inner
    response = func(*args, **kwargs)
  File "tecken/download/views.py", line 155, in download_symbol
    code_id=request.GET.get('code_id'),
  File "cache_memoize/__init__.py", line 103, in inner
    result = func(*args, **kwargs)
  File "python3.6/contextlib.py", line 52, in inner
    return func(*args, **kwds)
  File "tecken/download/views.py", line 236, in log_symbol_get_404
    code_id=code_id,
  File "markus/main.py", line 357, in _timer_decorator
    return fun(*args, **kwargs)
  File "tecken/download/utils.py", line 68, in store_missing_symbol
    hash_
  File "raven/contrib/django/client.py", line 123, in execute
    return real_execute(self, sql, params)
  File "django/db/backends/utils.py", line 65, in execute
    return self.cursor.execute(sql, params)
  File "django/db/utils.py", line 94, in __exit__
    six.reraise(dj_exc_type, dj_exc_value, traceback)
  File "django/utils/six.py", line 685, in reraise
    raise value.with_traceback(tb)
  File "django/db/backends/utils.py", line 65, in execute
    return self.cursor.execute(sql, params)
  File "newrelic/hooks/database_psycopg2.py", line 35, in execute
    **kwargs)
  File "newrelic/hooks/database_dbapi2.py", line 25, in execute
    *args, **kwargs)
"""

This is one of the urls that kicked it up:

https://symbols.mozilla.org/data@app@org.mozilla.firefox-2@base.apk@classes.dex/6C837FD7F775BD33E93AF8AA47CF29320/data@app@org.mozilla.firefox-2@base.apk@classes.dex.sym?code_file=data%40app%40org.mozilla.firefox-2%40base.apk%40classes.dex&code_id=d77f836c75f733bde93af8aa47cf2932
Assignee: nobody → peterbe
See the PR ^.

I've changed the max_length for storing the code_file and code_id to be 150 characters instead of the previous 50. 
Also, if a missing symbol GET comes in with a code_file (or code_id) *longer* than 150, it gets dropped and ignored. 

Can you think of any reason worth storing missing symbols if the code_file (or code_id) is longer than 150 characters?
Flags: needinfo?(ted)
No. They're not likely to be useful. The maximum useful code_id is probably ~20 characters, and the maximum useful code_file is probably in that ballpark as well. We do get weirdo things like the example in comment 0, but that's not actually a useful thing (it's nothing we would ever have symbols for).
Flags: needinfo?(ted)
Commits pushed to master at https://github.com/mozilla-services/tecken

https://github.com/mozilla-services/tecken/commit/2389fa725807c2371c8da4085e91788a93334a20
fixes bug 1423708 - recording of long filenames break for missing symbols

https://github.com/mozilla-services/tecken/commit/8eb9143276fbdc422ed27e1990a19cf1d9bcdb76
Merge pull request #603 from peterbe/bug-1423708-recording-of-long-filenames-break-for-missing-symbols

fixes bug 1423708 - recording of long filenames break for missing symbols
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Let's keep this open till it lands on Prod since the bugzilla dependency linkage affects a different team's bug.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Fixed in prod now.
Status: REOPENED → RESOLVED
Closed: 7 years ago7 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: