Commit Graph

250 Commits

Author SHA1 Message Date
Vinay Sajip c7403355df Added section on passing contextual information to logging and documentation for the LoggerAdapter class. 2008-01-18 15:54:14 +00:00
Andrew M. Kuchling 6d22c3961d Typo fix 2008-01-18 02:42:52 +00:00
Raymond Hettinger 64cd1e2d91 Fix markup 2008-01-17 23:56:56 +00:00
Raymond Hettinger 497fdbf767 Fix-up Timer() example. 2008-01-17 23:32:01 +00:00
Raymond Hettinger d0ab014b5e Add advice on choosing between scheduler and threading.Timer(). 2008-01-17 22:27:49 +00:00
Raymond Hettinger 44bd6c0a4f Issue #1861: Add read-only attribute listing upcoming events in the order they will be run. 2008-01-17 19:31:38 +00:00
Gregory P. Smith bde4ae4bde Fixes (accepts patch) issue1339 - http://bugs.python.org/issue1339
- Factor out the duplication of EHLO/HELO in login() and sendmail() to
  a new function, ehlo_or_helo_if_needed().
- Use ehlo_or_helo_if_needed() in starttls()
- Check for the starttls exception in starttls() in the same way as
  login() checks for the auth extension.
Contributed by Bill Fenner.
2008-01-17 08:35:49 +00:00
Raymond Hettinger d59f457279 Note versionadded. 2008-01-17 08:07:05 +00:00
Raymond Hettinger 473170908e Make starmap() match its pure python definition and accept any itertable input (not just tuples). 2008-01-17 03:02:14 +00:00
Raymond Hettinger 171f3916c5 Minor wordsmithing. 2008-01-16 23:38:16 +00:00
Georg Brandl 5c8b2abf71 Fix MSDN library URL. (#1854) 2008-01-16 16:56:29 +00:00
Andrew M. Kuchling 95f17bbfc0 Markup fix 2008-01-16 13:01:51 +00:00
Raymond Hettinger e805782b53 Fix-up half-written paragraph in the docs 2008-01-15 21:22:47 +00:00
Raymond Hettinger f59e962b49 Refactor if/elif chain for clarity and speed. Remove dependency on subclasses having to implement _empty and _full. 2008-01-15 20:52:42 +00:00
Jeffrey Yasskin d7b00334f3 Add rational.Rational as an implementation of numbers.Rational with infinite
precision. This has been discussed at http://bugs.python.org/issue1682. It's
useful primarily for teaching, but it also demonstrates how to implement a
member of the numeric tower, including fallbacks for mixed-mode arithmetic.

I expect to write a couple more patches in this area:
 * Rational.from_decimal()
 * Rational.trim/approximate() (maybe with different names)
 * Maybe remove the parentheses from Rational.__str__()
 * Maybe rename one of the Rational classes
 * Maybe make Rational('3/2') work.
2008-01-15 07:46:24 +00:00
Raymond Hettinger 907cda6ebb Small grammar nit 2008-01-15 05:46:43 +00:00
Skip Montanaro f233b0c454 Better (?) text describing the lack of guarantees provided by qsize(),
empty() and full().
2008-01-15 03:40:20 +00:00
Andrew M. Kuchling f15ff46be5 Markup fix 2008-01-15 01:29:44 +00:00
Andrew M. Kuchling 7ce9b18460 Typo fixes 2008-01-15 01:29:16 +00:00
Christian Heimes c94e2b5c12 Now that I've learnt about structseq objects I felt like converting sys.float_info to a structseq. It's
readonly and help(sys.float_info) explains the attributes nicely.
2008-01-14 04:13:37 +00:00
Christian Heimes f31b69f9db Applied patch #1816: sys.flags patch 2008-01-14 03:42:48 +00:00
Georg Brandl 9f1e2ecb48 Clarify the effect of text mode. 2008-01-13 09:36:18 +00:00
Georg Brandl fca4e1ffa1 Fix editing glitch. 2008-01-12 16:11:09 +00:00
Georg Brandl 57fe0f2902 Move OSError docs to exceptions doc, remove obsolete descriptions
from os docs, rework posix docs.
2008-01-12 10:53:29 +00:00
Mark Dickinson 59bc20bb27 Issue 1780: Allow leading and trailing whitespace in Decimal constructor,
when constructing from a string. Disallow trailing newlines in
Context.create_decimal.
2008-01-12 01:56:00 +00:00
Raymond Hettinger bed4dd459d Update the opcode docs for STORE_MAP and BUILD_MAP 2008-01-11 23:25:18 +00:00
Andrew M. Kuchling de68037202 Bug #1790: update link; remove outdated paragraph 2008-01-11 19:33:24 +00:00
Georg Brandl e3c3db59b5 Documentation for r5990[3567]. 2008-01-11 09:55:53 +00:00
Raymond Hettinger d1ef85420f Run doctests on the collections module 2008-01-11 00:23:13 +00:00
Raymond Hettinger 15b5e55b48 Neaten-up the named tuple docs 2008-01-10 23:00:01 +00:00
Amaury Forgeot d'Arc d08a8ebf2a Closing issue1761.
Surprising behaviour of the "$" regexp: it matches the
end of the string, AND just before the newline at the end
of the string::

    re.sub('$', '#', 'foo\n') == 'foo#\n#'

Python is consistent with Perl and the pcre library, so
we just document it.
Guido prefers "\Z" to match only the end of the string.
2008-01-10 21:59:42 +00:00
Raymond Hettinger e850c466c7 Clarify how to add a field to a named tuple. 2008-01-10 20:37:12 +00:00
Raymond Hettinger e1655088ca Examples for named tuple subclassing should include __slots__ 2008-01-10 19:15:10 +00:00
Raymond Hettinger dc1854dec4 Fix typo 2008-01-09 03:13:20 +00:00
Raymond Hettinger e11230e11b Syntax highlighting only works when >>> lines are accompanied by ... lines 2008-01-09 03:02:23 +00:00
Georg Brandl 502d6312db Fix markup errors from r59857 and clarify key.__enter__/__exit__ docs 2008-01-08 16:18:26 +00:00
Christian Heimes b39a756afd Added __enter__ and __exit__ functions to HKEY object
Added ExpandEnvironmentStrings to the _winreg module.
2008-01-08 15:46:10 +00:00
Andrew M. Kuchling e0a49b6e05 Patch 1137: allow assigning to .buffer_size attribute of PyExpat.parser objects 2008-01-08 14:30:55 +00:00
Raymond Hettinger ac5742e0fe Docs on named tuple's naming conventions and limits of subclassing 2008-01-08 02:24:15 +00:00
Raymond Hettinger f6b769b464 Documentation nits. 2008-01-07 21:33:51 +00:00
Raymond Hettinger f5e8af1bb7 Use get() instead of pop() for the optimized version of _replace(). 2008-01-07 20:56:05 +00:00
Raymond Hettinger fb3ced663d Minor markup fix 2008-01-07 20:17:35 +00:00
Raymond Hettinger 9a359210aa Cleanup named tuple subclassing example. 2008-01-07 20:07:38 +00:00
Vinay Sajip aa0665ba17 Added section about adding contextual information to log output. 2008-01-07 19:40:10 +00:00
Georg Brandl 61d2886491 Fix two further doc build warnings. 2008-01-07 18:57:03 +00:00
Georg Brandl 62416bcf5a #467924, patch by Alan McIntyre: Add ZipFile.extract and ZipFile.extractall. 2008-01-07 18:47:44 +00:00
Georg Brandl 62647653eb Restructure urllib doc structure. 2008-01-07 18:23:27 +00:00
Georg Brandl 2da0fceba7 Patch #602345 by Neal Norwitz and me: add -B option and PYTHONDONTWRITEBYTECODE envvar to skip writing bytecode. 2008-01-07 17:09:35 +00:00
Georg Brandl b3255ed8c9 Restore "somenamedtuple" as the "class" for named tuple attrs. 2008-01-07 16:43:47 +00:00
Mark Summerfield 86dfee5c45 Added a hyperlink from sequence types to mutable sequence types. 2008-01-07 16:42:08 +00:00