[python-list] python application file format

Discussion in 'Python' started by Benjamin Jessup, Sep 26, 2012.

  1. 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!
    Benjamin Jessup, Sep 26, 2012
    #1
    1. Advertising

  2. On Wednesday, 26 September 2012 18:29:14 UTC+5:30, Benjamin Jessup wrote:
    > 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!


    JSON is generally used for configuration.
    Ramchandra Apte, Sep 26, 2012
    #2
    1. Advertising

  3. On Wednesday, 26 September 2012 18:29:14 UTC+5:30, Benjamin Jessup wrote:
    > 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!


    JSON is generally used for configuration.
    Ramchandra Apte, Sep 26, 2012
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    5
    Views:
    715
    Magnus Lycka
    Oct 27, 2006
  2. Replies:
    1
    Views:
    803
    mlimber
    Sep 11, 2006
  3. Randy Kramer
    Replies:
    2
    Views:
    392
    Randy Kramer
    Jan 12, 2007
  4. Prasad, Ramit
    Replies:
    2
    Views:
    240
    Ramchandra Apte
    Sep 29, 2012
  5. Wesley
    Replies:
    1
    Views:
    122
    Wesley
    Apr 15, 2014
Loading...

Share This Page