schwab-py 1.6.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
schwab/__init__.py ADDED
@@ -0,0 +1,40 @@
1
+ import warnings as _warnings
2
+
3
+ from . import auth
4
+ from . import client
5
+ #from . import contrib
6
+ from . import debug
7
+ from . import orders
8
+ from . import streaming
9
+ from . import utils
10
+
11
+ from .version import version as __version__
12
+
13
+ LOG_REDACTOR = debug.LogRedactor()
14
+
15
+
16
+ class V2DeprecationWarning(FutureWarning):
17
+ '''Emitted on import while schwab-py is on the 1.x line, announcing
18
+ the upcoming 2.0 series and its library interface changes.
19
+
20
+ The warning is attributed to ``schwab/__init__.py`` rather than the
21
+ importing module so that it fires once per process and so module
22
+ filters work: to suppress it, either set
23
+
24
+ ``PYTHONWARNINGS="ignore::FutureWarning:schwab"``
25
+
26
+ before starting your program, or call
27
+ ``warnings.filterwarnings('ignore', category=FutureWarning,
28
+ module='schwab')`` in code before importing schwab.
29
+ '''
30
+
31
+
32
+ # This warning belongs to the 1.x line: remove it when the version is
33
+ # bumped to 2.0.0a1.
34
+ _warnings.warn(
35
+ 'schwab-py 2.0 is coming with new features and improvements '
36
+ '(see https://schwab-py.readthedocs.io/en/latest/v2.html for '
37
+ 'the transition plan and migration notes). The release will '
38
+ 'also include library interface changes: to stay on the 1.x '
39
+ 'line, pin "schwab-py<2.0" in your package manager.',
40
+ V2DeprecationWarning)