Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.freenet.ag!newsfeed.kamp.net!newsfeed.kamp.net!feeder1.cambriumusenet.nl!feed.tweaknews.nl!194.109.133.81.MISMATCH!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.054 X-Spam-Evidence: '*H*': 0.89; '*S*': 0.00; 'imported': 0.09; 'subject:into': 0.09; 'subject:script': 0.09; 'python': 0.11; 'wrote:': 0.18; 'import': 0.22; 'header:User-Agent:1': 0.23; 'subject: .': 0.24; 'script': 0.25; 'compiled': 0.26; 'gets': 0.27; 'header:In-Reply-To:1': 0.27; 'to:2**1': 0.27; 'received:google.com': 0.35; 'message-id:@gmail.com': 0.38; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'does': 0.39; 'to:addr:python.org': 0.39; 'how': 0.40; 'to:addr:gmail.com': 0.65; 'it!': 0.67; 'sam': 0.68; 'compiling': 0.84 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=W69sONRdQor+zikiLYBx2ykOgz3TYkw+sGQk6iRxFUY=; b=w7/STrKUXqgEs3XwERdFcL52G80rF+8QBD40k24c0kyxkIFaC4lcabYB5t1EonK+Ax Ph/6Auqt2vwzy0+EJSUSo5QSaLlKAp2pOVIsHaeKZTbjsAwrqOGTe0ZCxlIIbRej3Tkb 7UCwaWXbAgUMz+J/d/EwK9p1xdxNFjW9iRkkVOg4XDtqmbXXPybUyl7W9rY6BwIuF90Y UktwzFjxu+dNkO4M2Ynjd19/QxKfiobNVKaA/Ys+seH9AoWxMcKOq7fHJ+asRqj3FECo LWmYGVrUksYps07CkslM6nXWS7ugPI7N9px9ZtEmfuo690LErxoUQVVJtwjZjnGJ+H/l jrsw== X-Received: by 10.140.43.3 with SMTP id d3mr13695561qga.70.1389927396905; Thu, 16 Jan 2014 18:56:36 -0800 (PST) Date: Thu, 16 Jan 2014 21:56:02 -0500 From: bob gailer User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: Sam , python-list@python.org Subject: Re: Compiling main script into .pyc References: <61a24c80-12fd-4c7a-89ed-41e997b66545@googlegroups.com> In-Reply-To: <61a24c80-12fd-4c7a-89ed-41e997b66545@googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit 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: 5 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1389927400 news.xs4all.nl 2845 [2001:888:2000:d::a6]:59337 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:64134 On 1/16/2014 8:01 PM, Sam wrote: > One thing I observe about python byte-code compiling is that the main script does not gets compiled into .pyc. Only imported modules are compiled into .pyc. > > May I know how can I compile the main script into .pyc? Duh? Just import it!