![]() LCK files? I can't promise I will have any solutions but it may help to have another set of eyes on this. Is it possible for you to point me in the right direction to the code responsible for the. I don't know if there is some way you can check for open handles to the file immediately prior to deletion for debugging purposes, but I would definitely recommend verifying this if you can. LCK file before trying to delete it? Otherwise the Mac will almost certainly not allow it to be deleted. You said you are using a Windows XP machine for the CIFS share - what Service Pack is installed? Although from your post it sounds like the Mac problem is evident with a Samba server as well.Īre any of the machines on an Active Directory network or just standalone systems?Ĭan you post an example of your mount options for the Mac (with user/pass masked of course)?Īre you absolutely, 100% _SURE_ that GnuCash has completely released all file handles to the. And yes, when comparing Windows to Samba shares there are a LOT of differences, Samba tends to be much more forgiving, while Windows shares put things on lock-down. I have done a fair amount of work with Samba/CIFS integration and I can say for sure that the Mac smbfs implementation is flaky at best. Override message, use GC, and then close. Open GC on a Samba-mounted (via smbmount) directory.ģ. LNK there or not.Ĭopying the data file to a local directory opens and closes with no error messages or files left over.ġ. It will leave the file there on a clean close, and will display the above-noted message whether there is a. LNK file in this directory when told to go ahead and open the existing file. GnuCash could not obtain the lock for /home/des/H Drive/Dougan Consulting Group/Banking/FY 2006 (GnuCash 2 version). Each time I open the program, I get this message: I recently upgraded to 2.0.1 (my own build) on my SuSE 10.0 desktop. Print >sys.stderr, "Syntax %s src target" % (sys.I have been storing my GnuCash files on a Samba share since I began using it in 1.8.x. Target_uri = ("xml://%s" % os.path.abspath(target_uri) if "://" not in target_uri else target_uri) Src_uri = ("xml://%s" % os.path.abspath(src_uri) if "://" not in src_uri else src_uri) New_session = gnucash.Session(target_uri, is_new=True) """Converts gnucash databases at the given uris from src to target""" gnucashconvert filename.gnucash sqlite3:////home/username/export.sqlite): #!/usr/bin/env pythonĭef convert_gnucash(src_uri, target_uri): If you still want to use the XML files, you can use the following script to convert from XML to a database, and then write your reports on that (e.g. Print(df.loc = "Asset",Īs Chop Suey said, GnuCash 2.4 has its own database format. # print for account "Asset" some information on the splits # extract all split information to a pandas DataFrame Recent versions also allows to extract the split information directly to pandas DataFrames for easy plotting/analysis with from piecash import open_book Or to iterate over all the splits in the "Asset" account: # open the bookĪsset = mybook.accounts(fullname="Asset") With open_book("some_book.gnucash", open_if_lock=True) as mybook: With it you can easily access all the information contained in a book.įor instance, to iterate over all accounts in the book: from piecash import open_book I published piecash, a python interface to SQL saved GnuCash books that uses SQLAlchemy as basis ( ). You guys might have better suggestions in addition to those mentioned. Some workaround, like exporting to a certain file format for which there is a more mature Python library that can read it.More recently updated documentation aside from this one from the GnuCash wiki.As far as I know about GnuCash and Python, I think someone probably knows solutions of the following types: I hope someone can point me to a good start on this. My main objective is to read (no plans to write yet) my GnuCash files so that I can create my own visual dynamic reports using matplotlib and wxpython. ![]() Though I can operate the Linux command line, I am running GnuCash on Windows XP. The instructions are tailored for the Linux environment, and a rather old GnuCash version (2.0.x). I have read about this python-gnucash which provides Python bindings to the GnuCash library, but it takes a lot of work at the moment (e.g. I'm looking for information on how to read GnuCash files using python.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |