Uploaded image for project: 'TrueNAS'
  1. TrueNAS
  2. NAS-110251

Handle case where active_media_subtype can be none

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Engineering Closed (View Workflow)
    • Priority: Low
    • Resolution: Not to be Fixed
    • Affects Version/s: None
    • Fix Version/s: N/A
    • Component/s: Middleware
    • Labels:
      None

      Description

      PR: https://github.com/truenas/middleware/pull/6782

      On freebsd, we can have `active_media_subtype` as `None`.
      ```
      Traceback (most recent call last):
      File "/usr/local/lib/python3.8/site-packages/middlewared/event.py", line 45, in process
      self.run()
      File "/usr/local/lib/python3.8/site-packages/middlewared/plugins/reporting/events.py", line 166, in run
      'speeds': self.get_interface_speeds(),
      File "/usr/local/lib/python3.8/site-packages/middlewared/plugins/reporting/events.py", line 129, in get_interface_speeds
      if m := RE_BASE.match(interface['state']['active_media_subtype']):
      TypeError: expected string or bytes-like object
      ```

        Attachments

          Attachments

            JEditor

              Activity

                People

                Assignee:
                releng Triage Team
                Reporter:
                bugclerk Bug Clerk
                Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved: