mirror of
https://github.com/AdaCore/cpython.git
synced 2026-02-12 12:57:15 -08:00
Provisional fix for writefile() [SF bug # 541730]. The problem was that an exception can occur in the text.get() call or in the write() call, when the text buffer contains non-ASCII characters. This causes the previous contents of the file to be lost. The provisional fix is to call str(self.text.get(...)) *before* opening the file, so that if the exception occurs, we never open the file. Two orthogonal better solutions have to wait for policy decisions: 1. We could try to encode the data as Latin-1 or as UTF-8; but that would require IDLE to grow a notion of file encoding which requires more thought. 2. We could make backups before overwriting a file. This requires more thought because it needs to be fast and cross-platform and configurable. Original patches were: python/dist/src/Tools/idle/IOBinding.py:1.6
This directory contains a number of Python programs that are useful
while building or extending Python.
bgen Generate complete extension modules from a
description. Still under development!
compiler A Python source to bytecode compiler written in
Python, including an interface for manipulating
abstract syntax trees. Still under development.
faqwiz FAQ Wizard.
See http://grail.cnri.reston.va.us/cgi-bin/faqw.py
for a live example.
freeze Create a stand-alone executable from a Python program.
modulator Interactively generate boiler plate for an extension
module. Works easiest if you have Tk.
scripts A number of useful single-file programs, e.g. tabnanny.py
(by Tim Peters), which checks for inconsistent mixing
of tabs and spaces.
unicode Tools used to generate unicode database files for
Python 2.0 (by Fredrik Lundh).
versioncheck A tool to automate checking whether you have the latest
version of a package (by Jack Jansen).
webchecker A link checker for web sites.