Path: csiph.com!usenet.pasdenom.info!news.albasani.net!rt.uk.eu.org!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!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.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'python,': 0.02; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'python': 0.11; 'suggest': 0.14; 'compilation,': 0.16; 'compiler.': 0.16; 'easier.': 0.16; 'from:addr:behnel.de': 0.16; 'from:addr:stefan_ml': 0.16; 'from:name:stefan behnel': 0.16; 'license.': 0.16; 'readable': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'warranties,': 0.16; 'subject:python': 0.16; 'exception': 0.16; 'wrote:': 0.18; 'code.': 0.18; 'stefan': 0.19; 'header:User-Agent:1': 0.23; "shouldn't": 0.24; 'text,': 0.24; 'source': 0.25; 'header:X -Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; '(which': 0.31; 'code': 0.31; 'comments': 0.31; 'comments,': 0.31; 'no,': 0.35; 'received:84': 0.35; 'really': 0.36; 'e.g.': 0.38; 'needed': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'major': 0.40; 'disclaimer:': 0.60; 'telling': 0.64; 'goal': 0.75; 'compiling': 0.84; 'received:arcor- ip.net': 0.84; 'received:pools.arcor-ip.net': 0.84 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Stefan Behnel Subject: Re: python obfuscate Date: Sun, 13 Apr 2014 06:58:12 +0200 References: <802155420418900251.086281sturla.molden-gmail.com@news.gmane.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: dslb-084-056-058-001.pools.arcor-ip.net User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 In-Reply-To: <802155420418900251.086281sturla.molden-gmail.com@news.gmane.org> 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: 25 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1397365111 news.xs4all.nl 2921 [2001:888:2000:d::a6]:42682 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:70186 Sturla Molden, 11.04.2014 11:17: > Joshua Landau wrote: > >> However, if this really is your major blocker to using Python, I >> suggest compiling with Cython. > > Cython restains all the code as text, e.g. to readable generate exceptions. No, it actually doesn't. It only keeps the code in C comments, to make reading the generated code easier. Those comments get stripped during compilation, obviously. The only thing it keeps for its exception tracebacks is the line numbers, both for the C code (which you can disable) and for the original Python code. That shouldn't be very telling if you don't have the original source code. Stefan PS: disclaimer: I never needed to obfuscate Python code with Cython, and this use case is definitely not a design goal of the compiler. No warranties, see the license.