Notice: While JavaScript is not essential for this website, your interaction with the content will be limited. Please turn JavaScript on for the full experience.
...merge(O,O) which gives O. Therefore L[B] = B D E O Using the same procedure one finds: L[C] = C + merge(DO,FO,DF) = C + D + merge(O,FO,F) = C + D + F + merge(O,O) = C D F O Now we can compute: L[A] = A + merge(BDEO,CDFO,BC) = A + B + merge(DEO,CDFO,C) = A + B + C + merge(DEO,DFO) = A + B + C + D + merge(EO,FO) = A + B + C + D + E + merge(O,FO) = A + B + C + D + E + F + merge(O,O) = A B C D E F O In this example, the linearization is order...
...merge v1 and cherry-pick all non-merge commits from the old master); or merge the new v1 and loose the beauty of linear history. Null-merges Git has a builtin merge strategy for what Python core developers call "null-merge": $ git merge -s ours v1 # null-merge v1 into master Branching models Git doesn't assume any particular development model regarding branching and merging. Some projects prefer to graduate patches from the oldest branch to the newest, some prefer to cherry-pick commits b...
...algorithm 1.3.14.3.2.12). This URL must not be mirrored, and clients must fetch the official serverkey from PyPI directly, or use the copy that came with the PyPI client software. Mirrors should still download the key, to detect a key rollover. For each package, a mirrored signature is provided at /serversig/<package>. This is the DSA signature of the parallel URL /simple/<package>, in DER form, using SHA-1 with DSA (i.e. as a RFC 3279 Dsa-Sig-Value, created by algorithm 1.2.840.1004...
...merged back into the main Python distribution and takes the place of the old IDLE release. What's New? See the highlights of this release. Andrew Kuchling's What's New in Python 2.3 describes the most visible changes since Python 2.2 in more detail. A detailed list of the changes is in the release notes, or the Misc/NEWS file in the source distribution. For the full list of changes, you can poke around in CVS. The PSF's press release announcing 2.3. Documentation...
...algorithm enables the user to select a hash algorithm in the configure step. hash function selection The value of the macro Py_HASH_ALGORITHM defines which hash algorithm is used internally. It may be set to any of the three values Py_HASH_SIPHASH24, Py_HASH_FNV or Py_HASH_EXTERNAL. If Py_HASH_ALGORITHM is not defined at all, then the best available algorithm is selected. On platforms which don't require aligned memory access (HAVE_ALIGNED_REQUIRED not defined) and an unsigned 64 bit integer t...
Version: None
Released: July 29, 2003
patch release release which supersedes earlier releases of 2.3.</i> </blockquote> <blockquote> <b>Important:</b> This release is vulnerable to the problem described in <a href="/news/security/PSF-2006-001/">security advisory PSF-2006-001</a> "Buffer overrun in repr() of unicode strings in wide unicode builds (UCS-4)". This fix is included in <a href="../2.4.4/">Python 2.4.4</a> and <a href="../2.5/">Python 2.5</a>. If …
View Release Notes
...algorithm¶ The source code for the md5 module contains the following notice: Copyright (C) 1999, 2002 Aladdin Enterprises. All rights reserved. This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to...
...algorithm that's currently implemented, but its description of the algorithm is pretty hard to grasp - I had originally documented a different, naive, algorithm and didn't even realize that it didn't always compute the same MRO until Tim Peters found a counterexample. More recently, Samuele Pedroni has found a counterexample showing that the naive algorithm fails to maintain monotonicity, so I won't even describe it any more. Samuele has convinced me to use a newer MRO algorithm named ...
...algorithm. In particular, parser.largs and parser.rargs are guaranteed to be available to callbacks [11]. This makes it extremely difficult to improve the parsing algorithm as was necessary in argparse for proper handling of positional arguments and variable length arguments. For example, nargs='+' in argparse is matched using regular expressions and thus has no notion of things like parser.largs. The optparse extension APIs are extremely complex. For example, just to use a simple custom string...
...merged in sys.path order. This would allow home-directory or other alternate-location installs to work, and ease the process of a distutils install command writing the file." Nice feature: it does mean that package manager tools can take into account Python packages that a user has privately installed. AMK wonders: what does setup.py do if it's told to install packages to a directory not on sys.path? Does it write an install-db directory to the directory it's told to write to, or does it do no...
...algorithm presented so far. Instead of allowing you to import a "pure virtual" package (like zc), we allow only importing of the contents of virtual packages. That is, a statement like import zc should raise ImportError if there is no zc.py or zc/__init__.py on sys.path. But, doing import zc.buildout should still succeed, as long as there's a zc/buildout.py or zc/buildout/__init__.py on sys.path. In other words, we don't allow pure virtual packages to be imported directly, only modules and sel...
...merged with it (they have their own cause, context and traceback). Instead, they are combined into a new ExceptionGroup (or BaseExceptionGroup), which also contains the reraised/unhandled subgroup described above. In the following example, the ValueErrors were raised so they are in their own ExceptionGroup, while the OSErrors were reraised so they were merged with the unhandled TypeErrors. >>> try: ... raise ExceptionGroup( ... "eg", ... [ ... ValueError...
...merge conflicts after the initial structural changes were put in place to start the refactoring process. Unlike some other previous major changes, such as the switch to an AST-based compiler in Python 2.5, or the switch to the importlib implementation of the import system in Python 3.3, there is no clear way to structure a draft implementation that won't be prone to the kinds of merge conflicts that afflicted the original attempt. Accordingly, the implementation strategy was revised to instead f...
...algorithm that's currently implemented, but its description of the algorithm is pretty hard to grasp - I didn't even realize that the algorithm above doesn't always compute the same MRO until Tim Peters found a counterexample. Fortunately, counterexamples can only occur when there are order disagreements in the inheritance graph. The book outlaws classes containing such order disagreements, if the order disagreement is "serious". An order disagreement between two classes is serious wh...
...algorithms that worked fine for small inputs but took O(n**2) time for large inputs due to the underlying O(n) behavior of array-based lists. The deque type, introduced in Python 2.4, solved the most common problem of needing a fast FIFO queue. However, the deque type doesn't help if we need to repeatedly insert or delete elements from the middle of a long list. A wide variety of data structure provide good asymptotic performance for insertions and deletions, but they either have O(n) performan...
...algorithmic complexity point of view, with allowances only needing to be made for the initial implicit O(n) cache refresh that runs the first time an operation that relies on the cache being up to date is executed. the claim that a cache-free implementation would be simpler is highly suspect, as PEP 667 includes only a pure Python sketch of a subset of a mutable mapping implementation, rather than a full-fledged C implementation of a new mapping type integrated with the underlying data storage f...
...merge_by_default from overloading import Around, Before, After, Method, MethodList class Discount(MethodList): """Apply return values as discounts""" def __call__(self, *args, **kw): retval = self.tail(*args, **kw) for sig, body in self.sorted(): retval -= retval * body(*args, **kw) return retval # merge discounts by priority merge_by_default(Discount) # discounts have precedence over before/after/primary methods always_overrides(Discount, Before) ...