Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.029 X-Spam-Evidence: '*H*': 0.94; '*S*': 0.00; 'locale': 0.09; 'messing': 0.09; 'python': 0.11; 'codecs': 0.16; 'janet': 0.16; 'prepended': 0.16; 'retrieving': 0.16; 'files.': 0.16; 'header:User-Agent:1': 0.23; 'replace': 0.24; 'java': 0.24; "i'm": 0.30; 'dept': 0.31; 'file': 0.32; 'there.': 0.32; 'another': 0.32; 'linux': 0.33; 'trouble': 0.34; 'could': 0.34; 'but': 0.35; 'there': 0.35; 'subject:?': 0.36; 'being': 0.38; 'to:addr:python-list': 0.38; 'files': 0.38; 'expect': 0.39; 'delete': 0.39; 'to:addr:python.org': 0.39; 'university': 0.39; 'received:org': 0.40; 'read': 0.60; 'new': 0.61 Date: Tue, 24 Sep 2013 10:42:22 +0100 From: "J. Bagg" Organization: Dept of Anthropology, University of Kent User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.1.16) Gecko/20101125 Thunderbird/3.0.11 MIME-Version: 1.0 To: python-list@python.org Subject: removing BOM prepended by codecs? Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Tue, 24 Sep 2013 12:16:59 +0200 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 17 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1380017820 news.xs4all.nl 15897 [2001:888:2000:d::a6]:35066 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:54685 I'm having trouble with the BOM that is now prepended to codecs files. The files have to be read by java servlets which expect a clean file without any BOM. Is there a way to stop the BOM being written? It is seriously messing up my work as the servlets do not expect it to be there. I could delete it but that means another delay in retrieving the data. My work is a bibliographic system and I'm writing a new search engine in Python to replace an ancient one in C. I'm working on Linux with a locale of en_GB.UTF8 -- Dr Janet Bagg CSAC, Dept of Anthropology, University of Kent, UK