Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.mixmin.net!feed.xsnews.nl!border-1.ams.xsnews.nl!xlned.com!feeder7.xlned.com!news2.euro.net!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.003 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'json': 0.07; 'subject:application': 0.07; 'subject:file': 0.07; 'python': 0.09; 'compact': 0.09; 'port,': 0.09; 'subject:python': 0.11; "(can't": 0.16; 'appreciated!': 0.16; 'expandable': 0.16; 'instances,': 0.16; 'module?': 0.16; 'pointers,': 0.16; 'portable,': 0.16; 'space)': 0.16; 'subject:] ': 0.19; 'all,': 0.21; 'struct': 0.22; 'header:User-Agent:1': 0.26; 'subject:list': 0.28; 'class': 0.29; 'file': 0.32; 'to:addr:python-list': 0.33; 'subject:[': 0.37; 'data': 0.37; 'object': 0.38; 'advice': 0.39; 'to:addr:python.org': 0.39; 'easily': 0.39; 'subject:-': 0.40; 'header:Received:5': 0.40; 'other.': 0.64; 'application?': 0.84; 'compact,': 0.84; 'received:98.172': 0.84 Date: Wed, 26 Sep 2012 08:49:26 -0400 From: Benjamin Jessup Organization: ABZ, Inc. User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:15.0) Gecko/20120907 Thunderbird/15.0.1 MIME-Version: 1.0 To: python-list@python.org Subject: [python-list] python application file format 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: 15 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1348664353 news.xs4all.nl 6939 [2001:888:2000:d::a6]:56180 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:30190 Hello all, What do people recommend for a file format for a python desktop application? Data is complex with 100s/1000s of class instances, which reference each other. Write the file with struct module? (Rebuild object pointers, safe, compact, portable, not expandable without reserved space) Use cPickle with a module/class whitelist? (Can't easily port, not entirely safe, compact enough, expandable) Use JSON or similar? (Rebuild object pointers, portable, expandable, size?) Any advice is greatly appreciated!