Uploaded image for project: 'MariaDB Connector/Python'
  1. MariaDB Connector/Python
  2. CONPY-203

Module mariadb.constants.ER for maintaining error codes

    XMLWordPrintable

Details

    • New Feature
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Fixed
    • None
    • 1.1.2
    • Generic
    • None

    Description

      Being able to handle specific errors is great with the Exception's "errno". It would be a lot neater if there were constants for this instead of numbers - to promote better readability.

      ```python
      try:
      documents = domino.get_all("Sales Order")
      except OperationalError as err:
      if err.errno == ER.LOCK_WAIT_TIMEOUT:
      ...
      logger.exception("Lock wait timeout error ocurred")
      ```

      Attachments

        Activity

          People

            georg Georg Richter
            gavin Gavin D'souza
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.