File: error.py

package info (click to toggle)
python-twitter 3.3-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 13,044 kB
  • sloc: python: 6,244; makefile: 213
file content (20 lines) | stat: -rw-r--r-- 511 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/usr/bin/env python


class TwitterError(Exception):
    """Base class for Twitter errors"""

    @property
    def message(self):
        '''Returns the first argument used to construct this error.'''
        return self.args[0]


class PythonTwitterDeprecationWarning(DeprecationWarning):
    """Base class for python-twitter deprecation warnings"""
    pass


class PythonTwitterDeprecationWarning330(PythonTwitterDeprecationWarning):
    """Warning for features to be removed in version 3.3.0"""
    pass