Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!xlned.com!feeder5.xlned.com!newsfeed.xs4all.nl!newsfeed2a.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.048 X-Spam-Evidence: '*H*': 0.90; '*S*': 0.00; 'responding': 0.07; 'ide': 0.09; 'windows': 0.15; 'here"': 0.16; 'iterating': 0.16; 'mean,': 0.16; 'subject:Not': 0.16; 'wrote:': 0.18; 'trying': 0.19; 'file,': 0.19; 'work,': 0.20; 'print': 0.22; 'header:User- Agent:1': 0.23; "aren't": 0.24; 'focusing': 0.24; 'text,': 0.24; 'paul': 0.24; 'environment': 0.24; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; "i'm": 0.30; 'lines': 0.31; '100000': 0.31; 'fault': 0.31; 'os,': 0.31; 'says': 0.33; 'running': 0.33; '(most': 0.33; 'could': 0.34; 'problem': 0.35; 'subject:with': 0.35; 'something': 0.35; 'there': 0.35; 'tight': 0.36; 'useful': 0.36; 'list.': 0.37; 'whatever': 0.38; 'to:addr:python-list': 0.38; 'recent': 0.39; 'received:71': 0.39; 'to:addr:python.org': 0.39; 'how': 0.40; 'read': 0.60; 'new': 0.61; 'received:208': 0.61; 'simply': 0.61; 'information': 0.63; 'high': 0.63; 'love': 0.65; '"not': 0.84; 'received:208.70': 0.91 Date: Wed, 18 Jun 2014 12:23:56 -0700 From: Paul McNett User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 MIME-Version: 1.0 To: python-list@python.org Subject: Re: Not Responding When Dealing with Large Data References: <00d330e3-fc8a-4b7e-b2bd-f1a48bc335c1@googlegroups.com> In-Reply-To: <00d330e3-fc8a-4b7e-b2bd-f1a48bc335c1@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: 32 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1403120639 news.xs4all.nl 2833 [2001:888:2000:d::a6]:60944 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:73377 On 6/18/14, 10:20 AM, cutey Love wrote: > I'm trying to read in 100000 lines of text, use some functions to edit them and then return a new list. How is it that you are opening the file, and iterating the contents? > The problem is my program always goes not responding when the amount of lines are a high number. What do you mean, "goes not responding"? What environment are you running in? Windows and IDLE? > I don't care how long the program takes to work, just need it to stop crashing? Note that "not responding" isn't the same as crashing. If your program crashed, it would likely print on your terminal something like: Traceback (most recent call last): ... lots of lines including useful information about the problem or Segmentation Fault If it just goes "not responding" for a while in your tight loop, it could simply mean just that: your IDE or whatever is focusing so hard on running your program that there aren't any cycles to say "still here" to the OS, so the OS has no clue what's going on and says to the user "not responding". Have you waited to see if it ever completes? Paul