summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSkip Montanaro <skip@pobox.com>2001-03-01 04:27:19 +0000
committerSkip Montanaro <skip@pobox.com>2001-03-01 04:27:19 +0000
commit03a6f7bf2189a735873361c42ac54879f27b601c (patch)
treef18df5f7b9e6a417fa3addfbf00c26d40577f821
parenta1e6aeb18d75442cba22c2658b3d2c708184b33c (diff)
downloadcpython-03a6f7bf2189a735873361c42ac54879f27b601c.tar.gz
final round of __all__ lists (I hope) - skipped urllib2 because Moshe may be
giving it a slight facelift
-rwxr-xr-xLib/tabnanny.py2
-rw-r--r--Lib/telnetlib.py2
-rw-r--r--Lib/tempfile.py2
-rw-r--r--Lib/test/test___all__.py16
-rw-r--r--Lib/toaiff.py2
-rw-r--r--Lib/tokenize.py6
-rw-r--r--Lib/traceback.py5
-rw-r--r--Lib/tty.py2
-rw-r--r--Lib/urllib.py4
-rw-r--r--Lib/urlparse.py2
-rwxr-xr-xLib/uu.py2
-rw-r--r--Lib/warnings.py3
-rw-r--r--Lib/wave.py2
-rw-r--r--Lib/weakref.py3
-rw-r--r--Lib/webbrowser.py2
-rw-r--r--Lib/xdrlib.py2
-rw-r--r--Lib/zipfile.py3
17 files changed, 59 insertions, 1 deletions
diff --git a/Lib/tabnanny.py b/Lib/tabnanny.py
index ea4fbc694b..c945dd5057 100755
--- a/Lib/tabnanny.py
+++ b/Lib/tabnanny.py
@@ -16,6 +16,8 @@ import string
import getopt
import tokenize
+__all__ = ["check"]
+
verbose = 0
filename_only = 0
diff --git a/Lib/telnetlib.py b/Lib/telnetlib.py
index 231618af2a..6b249e8db4 100644
--- a/Lib/telnetlib.py
+++ b/Lib/telnetlib.py
@@ -41,6 +41,8 @@ import sys
import socket
import select
+__all__ = ["Telnet"]
+
# Tunable parameters
DEBUGLEVEL = 0
diff --git a/Lib/tempfile.py b/Lib/tempfile.py
index 7d7f92415d..fe4d291b05 100644
--- a/Lib/tempfile.py
+++ b/Lib/tempfile.py
@@ -6,6 +6,8 @@
import os
+__all__ = ["mktemp", "TemporaryFile", "tempdir", "gettempprefix"]
+
# Parameters that the caller may set to override the defaults
tempdir = None
template = None
diff --git a/Lib/test/test___all__.py b/Lib/test/test___all__.py
index bcc9d4a331..2cc021b47d 100644
--- a/Lib/test/test___all__.py
+++ b/Lib/test/test___all__.py
@@ -135,3 +135,19 @@ check_all("sndhdr")
check_all("socket")
check_all("sre")
check_all("stat_cache")
+check_all("tabnanny")
+check_all("telnetlib")
+check_all("tempfile")
+check_all("toaiff")
+check_all("tokenize")
+check_all("traceback")
+check_all("tty")
+check_all("urllib")
+check_all("urlparse")
+check_all("uu")
+check_all("warnings")
+check_all("wave")
+check_all("weakref")
+check_all("webbrowser")
+check_all("xdrlib")
+check_all("zipfile")
diff --git a/Lib/toaiff.py b/Lib/toaiff.py
index 96d4642040..a2b6d6e9cb 100644
--- a/Lib/toaiff.py
+++ b/Lib/toaiff.py
@@ -13,6 +13,8 @@ import tempfile
import pipes
import sndhdr
+__all__ = ["error", "toaiff"]
+
table = {}
t = pipes.Template()
diff --git a/Lib/tokenize.py b/Lib/tokenize.py
index 9f46612cb6..789d130531 100644
--- a/Lib/tokenize.py
+++ b/Lib/tokenize.py
@@ -14,11 +14,15 @@ __version__ = "Ka-Ping Yee, 26 October 1997; patched, GvR 3/30/98"
import string, re
from token import *
+import token
+__all__ = [x for x in dir(token) if x[0] != '_'] + ["COMMENT", "tokenize", "NL"]
+del token
+
COMMENT = N_TOKENS
tok_name[COMMENT] = 'COMMENT'
NL = N_TOKENS + 1
tok_name[NL] = 'NL'
-
+N_TOKENS += 2
# Changes from 1.3:
# Ignore now accepts \f as whitespace. Operator now includes '**'.
diff --git a/Lib/traceback.py b/Lib/traceback.py
index b4fe050965..89ecb615d5 100644
--- a/Lib/traceback.py
+++ b/Lib/traceback.py
@@ -4,6 +4,11 @@ import linecache
import sys
import types
+__all__ = ['extract_stack', 'extract_tb', 'format_exception',
+ 'format_exception_only', 'format_list', 'format_stack',
+ 'format_tb', 'print_exc', 'print_exception', 'print_last',
+ 'print_stack', 'print_tb', 'tb_lineno']
+
def _print(file, str='', terminator='\n'):
file.write(str+terminator)
diff --git a/Lib/tty.py b/Lib/tty.py
index b1904fb505..a72eb67554 100644
--- a/Lib/tty.py
+++ b/Lib/tty.py
@@ -4,6 +4,8 @@
from termios import *
+__all__ = ["setraw", "setcbreak"]
+
# Indexes for termios list.
IFLAG = 0
OFLAG = 1
diff --git a/Lib/urllib.py b/Lib/urllib.py
index 00129c9a8d..2eb90f9d7f 100644
--- a/Lib/urllib.py
+++ b/Lib/urllib.py
@@ -28,6 +28,10 @@ import os
import sys
import types
+__all__ = ["urlopen", "URLopener", "FancyURLopener", "urlretrieve",
+ "urlcleanup", "quote", "quote_plus", "unquote", "unquote_plus",
+ "urlencode"]
+
__version__ = '1.15' # XXX This version is not always updated :-(
MAXFTPCACHE = 10 # Trim the ftp cache beyond this size
diff --git a/Lib/urlparse.py b/Lib/urlparse.py
index b9ecee1670..1df83d68d3 100644
--- a/Lib/urlparse.py
+++ b/Lib/urlparse.py
@@ -4,6 +4,8 @@ See RFC 1808: "Relative Uniform Resource Locators", by R. Fielding,
UC Irvine, June 1995.
"""
+__all__ = ["urlparse", "urlunparse", "urljoin"]
+
# A classification of schemes ('' means apply by default)
uses_relative = ['ftp', 'http', 'gopher', 'nntp', 'wais', 'file',
'https', 'shttp',
diff --git a/Lib/uu.py b/Lib/uu.py
index 37bdf6af56..334d436cd6 100755
--- a/Lib/uu.py
+++ b/Lib/uu.py
@@ -34,6 +34,8 @@ import binascii
import os
import sys
+__all__ = ["Error", "encode", "decode"]
+
class Error(Exception):
pass
diff --git a/Lib/warnings.py b/Lib/warnings.py
index 52aee26879..243f215065 100644
--- a/Lib/warnings.py
+++ b/Lib/warnings.py
@@ -2,6 +2,9 @@
import sys, re, types
+__all__ = ["warn", "showwarning", "formatwarning", "filterwarnings",
+ "resetwarnings"]
+
defaultaction = "default"
filters = []
onceregistry = {}
diff --git a/Lib/wave.py b/Lib/wave.py
index ad4f29aae8..b5f0e1ceb6 100644
--- a/Lib/wave.py
+++ b/Lib/wave.py
@@ -73,6 +73,8 @@ is destroyed.
import __builtin__
+__all__ = ["open", "openfp", "Error"]
+
class Error(Exception):
pass
diff --git a/Lib/weakref.py b/Lib/weakref.py
index 30574efcb5..a5a2d1d183 100644
--- a/Lib/weakref.py
+++ b/Lib/weakref.py
@@ -19,6 +19,9 @@ from _weakref import \
ProxyTypes = (ProxyType, CallableProxyType)
+__all__ = ["ref", "mapping", "proxy", "getweakrefcount", "getweakrefs",
+ "WeakKeyDictionary", "ReferenceType", "ProxyType",
+ "CallableProxyType", "ProxyTypes", "WeakValueDictionary"]
def mapping(dict=None,weakkeys=0):
if weakkeys:
diff --git a/Lib/webbrowser.py b/Lib/webbrowser.py
index 5008a0b6ae..6a60c24590 100644
--- a/Lib/webbrowser.py
+++ b/Lib/webbrowser.py
@@ -3,6 +3,8 @@
import os
import sys
+__all__ = ["Error", "open", "get", "register"]
+
class Error(Exception):
pass
diff --git a/Lib/xdrlib.py b/Lib/xdrlib.py
index 621f295772..5d012e905b 100644
--- a/Lib/xdrlib.py
+++ b/Lib/xdrlib.py
@@ -6,6 +6,8 @@ See: RFC 1014
import struct
+__all__ = ["Error", "Packer", "Unpacker", "ConversionError"]
+
# exceptions
class Error:
"""Exception class for this module. Use:
diff --git a/Lib/zipfile.py b/Lib/zipfile.py
index 5a7345ba70..39b1511667 100644
--- a/Lib/zipfile.py
+++ b/Lib/zipfile.py
@@ -10,6 +10,9 @@ try:
except:
zlib = None
+__all__ = ["BadZipfile", "error", "ZIP_STORED", "ZIP_DEFLATED", "is_zipfile",
+ "ZipInfo", "ZipFile", "PyZipFile"]
+
class BadZipfile(Exception):
pass
error = BadZipfile # The exception raised by this module