Opened 5 days ago

Last modified 5 days ago

#32014 assigned defect

Fix fpcentral after update to buster

Reported by: boklm Owned by: boklm
Priority: Medium Milestone:
Component: Applications/Quality Assurance and Testing Version:
Severity: Normal Keywords: fpcentral, TorBrowserTeam201910, boklm201910
Cc: tbb-team Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

After upgrading the VM running https://fpcentral.tbb.torproject.org/ to buster, fpcentral now fails to run.

We can see this in the error logs:

mod_wsgi (pid=9229): Failed to exec Python script file '/srv/fpcentral.tbb.torproject.org/fpcentral/fpcentral.wsgi'.
mod_wsgi (pid=9229): Exception occurred processing WSGI script '/srv/fpcentral.tbb.torproject.org/fpcentral/fpcentral.wsgi'.
Traceback (most recent call last):
  File "/srv/fpcentral.tbb.torproject.org/fpcentral/fpcentral.wsgi", line 9, in <module>
    from run import app as application
  File "/srv/fpcentral.tbb.torproject.org/fpcentral/run.py", line 4, in <module>
    from fingerprint.tags_manager import *
  File "/srv/fpcentral.tbb.torproject.org/fpcentral/fingerprint/tags_manager.py", line 1, in <module>
    from fingerprint.tags.browser import Browser
  File "/srv/fpcentral.tbb.torproject.org/fpcentral/fingerprint/tags/browser.py", line 2, in <module>
    from ua_parser import user_agent_parser
  File "/usr/lib/python3/dist-packages/ua_parser/user_agent_parser.py", line 465, in <module>
    regexes = yaml.load(fp, Loader=SafeLoader)
  File "/usr/lib/python3/dist-packages/yaml/__init__.py", line 72, in load
    return loader.get_single_data()
  File "/usr/lib/python3/dist-packages/yaml/constructor.py", line 37, in get_single_data
    return self.construct_document(node)
  File "/usr/lib/python3/dist-packages/yaml/constructor.py", line 41, in construct_document
    data = self.construct_object(node)
  File "/usr/lib/python3/dist-packages/yaml/constructor.py", line 86, in construct_object
    data = constructor(self, node)
  File "/usr/lib/python3/dist-packages/yaml/constructor.py", line 414, in construct_undefined
    node.start_mark)
yaml.constructor.ConstructorError: could not determine a constructor for the tag None
  in "/usr/share/uap-core/regexes.yaml", line 1, column 1

Child Tickets

Change History (1)

comment:1 Changed 5 days ago by boklm

In requirements.txt we have the line ua-parser==0.7.1, which means that this version of the module is installed in the virtualenv. However the python3-ua-parser Debian package is also installed on the system, with version 0.8.0, which is what gets used.

To fix the issue we should make fpcentral compatible with ua-parser version 0.8.0.

Note: See TracTickets for help on using tickets.