Re: How to create python web framework for ERP
Use the only odoo framework.. without addons .. will be the best choice .. do not reinvent the whell if you do not need web interface, you can have a look at http://www.tryton.org/ otherwise you could have flask for the top of flexibility regards, Matteo Il 09/09/2014 12:06, Vimal Rughani ha scritto: On Tuesday, 9 September 2014 14:09:48 UTC+5:30, Stéphane Wirtel wrote: On 9 Sep 2014, at 10:25, Vimal Rughani wrote: Hi All, Greetings ! I am bit familiar with Django and Python. I want to create ERP on python. Initially I feel Django will be good option for My Own ERP, but after working bit on that I feel it doesn't fit with my requirement. So I decided to create my own python based web framework for ERP. Can you please suggest me better book / video / resources / content which help me to build proper web framework for ERP. Thanks -- https://mail.python.org/mailman/listinfo/python-list Use Odoo. -- Stéphane Wirtel - http://wirtel.be - @matrixise Thanks Stéphane, for your suggestion. I know about Odoo and Odoo is good choice for domain related to Business. I am developing solution for Education / schools / colleges. Requirements are bit complex so I want to have own framework. -- https://mail.python.org/mailman/listinfo/python-list
Re: help to code...
The error is self expleined .. print str(current_month) + '/' + str(current_day) + '/' + str(current_year) +' *'+ * this line have a + at the end,the interpreter need something to add .. so remove it and it will work regards, Matteo Il 02/05/2013 15:50, leonardo selmi ha scritto: dear python community, i wrote the following program: from datetime import datetime now = datetime.now() current_month = now.month current_day = now.day current_year = now.year current_hour = now.hour current_minute = now.minute current_second = now.second print str(current_month) + '/' + str(current_day) + '/' + str(current_year) +' '+ print str(current_hour) + str(current_minute) + str(current_second) and i got this error: Traceback (most recent call last): File runner.py, line 125, in compilecode File python, line 9 print str(current_month) + '/' + str(current_day) + '/' + str(current_year) +' '+ ^ SyntaxError: invalid syntax how can i write the last two lines correctly? thanks! -- http://mail.python.org/mailman/listinfo/python-list
Re: 2-D drawing/map with python
Il 12/03/2013 16:58, Huseyin Emre Guner ha scritto: Hello, I am newbie in Python. I would like to make a project using python. The main ideo of this project is that a user enters the x,y values to the Gui(PyQt or Gtk) and then a 2-D map is plotted due to the x,y values. First, I use Pygame commands (pygame.draw.line(window, (255, 255, 255), (10, 10), (200, 400)) However I could not establish a gui with pygame. Now I would like to use the PyQt. Could you please give me advice for this project? have a look at : http://sourceforge.net/projects/pythoncad/ it's also integrated with sympy .. regards, Matteo -- http://mail.python.org/mailman/listinfo/python-list
Re: Import Question
Il 20/02/2013 21:53, eli m ha scritto: How long does it take for the program to import something? I am asking this because i have like 7 imports at the beginning of my program and i am thinking thats the reason why it is slow to start up. Thanks in advance. It depend of your code module code.. if inside your module there is some code (no def or class) this code will be executed, and if for example you have some loop or some db query this will be executed too. regards, Matteo -- http://mail.python.org/mailman/listinfo/python-list
gc.get_objects()
Hi All, I'm facing some trouble with a win32com application, it seems, that some com object (win32com) are still in the gc.get_objetc() list, even if I set to non the objetc and I'm out of the scope of that objects. What I'm try to do is to remove this object from the list. but I do know how.. the .__del__() method dose not work on this object... there is someone that can give me some help on this ? Regards, Matteo -- http://mail.python.org/mailman/listinfo/python-list
Re: gc.get_objects()
from my gc.get_object() I extract the sub system of the object that I would like to delete: this is the object: Class name win32com.gen_py.F4503A16-F637-11D2-BD55-00500400405Bx0x1x0.ITDProperty.ITDProperty that is traked and the reference are: get_referents RefCount 5 type 'tuple' (class win32com.client.DispatchBaseClass at 0x026ACB58,) RefCount 5 type 'dict' '__int__': function __int__ at 0x03A50770, '__module__': 'win32com.gen_py.F45 RefCount 8 type 'str' ITDProperty RefCount 9 type 'function' function __getattr__ at 0x026C2630 RefCount 9 type 'function' function __setattr__ at 0x026C2670 get_referrers RefCount 15 type 'dict' 'python_version': 34014192, 'defaultUnnamedArg': PyOleEmpty object at 0x00447E RefCount 6 type 'list' class win32com.gen_py.F4503A16-F637-11D2-BD55-00500400405Bx0x1x0.ITDProperty.I RefCount 4 type 'list' (u'ItemsListCreator', u'trick', u'pVal'), (3, 49, '0', None), (16393, 10, None, RefCount 4 type 'frame' frame object at 0x029721D8 RefCount 7 type 'frame' frame object at 0x02760148 RefCount 5 type 'dict' '{39AAEA35-F71F-11D2-BD59-00500400405B}': class win32com.gen_py.F4503A16-F637- how can I understand how to clean up this situation or were are the references that I need to delete ? From the cad non python script I call an in process python com object, and before coming back to the cad application I need to clean up all com reference, because if I do not do that I corrupt the cad application . so I urgently need to clean up all reference before coming back to the cad application. any idea? regards, Matteo Il 17/09/2012 18:09, Chris Angelico ha scritto: On Tue, Sep 18, 2012 at 12:16 AM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: The __del__ method does not delete an object. Remember, objects are only deleted when there are no references to it. Otherwise you could have some code that tries to use a deleted object, and you would get a system crash or BSOD. There is a conceptually viable alternative: destroy an object immediately and force all references to it to become some sentinel value (eg None). Python currently doesn't have this, but it would be rather convenient at times. Could be part of a construct like 'with' to say make this, use it, and then dispose of it. ChrisA -- http://mail.python.org/mailman/listinfo/python-list
Re: a problem about print
in the code2 aList=[1,2,3,4,5,6,7,8,9,10] aList=str(aList) #--- here you convert the list in a string print aList print aList[2] #-- here you are printing the third caracter of the string '[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]' not the list '[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]' regards Matteo Il 04/07/2012 09:28, levi nie ha scritto: Hi,Harrison. Your method is cool. But i doubt this, if bList and aList just are attached to the same List when i write bList=aList,but why the output of the following two code are different? code1: aList=[1,2,3,4,5,6,7,8,9,10] bList=aList bList=str(bList) print aList print aList[2] code2: aList=[1,2,3,4,5,6,7,8,9,10] aList=str(aList) print aList print aList[2] i'm puzzled now. 2012/7/4 Harrison Morgan harrison.mor...@gmail.com mailto:harrison.mor...@gmail.com On Wed, Jul 4, 2012 at 12:38 AM, levi nie levinie...@gmail.com mailto:levinie...@gmail.com wrote: that's good,thanks. new problem. when i write bList=aList del bList[2] bList and aList both change,how can i make aList not changed? Lists are mutable. That means that when you do bList = aList, you're just creating another reference to aList. They both point to the same list, just using different names. You should read up a bit on immutable vs. mutable objects. Here's something that I found that might explain it a bit better. http://henry.precheur.org/python/copy_list -- http://mail.python.org/mailman/listinfo/python-list
Losing com pointer
Hi all, I need some help to a com problem.. I got this class: class foo(object): def setComObject(comObject): self.comO=comObject #This is a com object from a cad application def showForm(self) # use the self.comO to read some information from the cad application # Show the pyqt form as child of cad application # do somthing with the form # do somthing with the self.comO - Here if pass some time I'm not able to call any method to the com object a=foo() o=get istance of a cad application via com a.setComObject(o) a.showForm() # here if pass some time I'm not able to call any method to the com object but I I' re call the a.setComObject(o) #Faster and I take less the 30 seconds on the form object it works well It seems a problem of the garbage collector .. but I'm not sure how to debug it .. any help is really appreciated.. it's the last dangerous bug in our application ... Regards, Matteo -- http://mail.python.org/mailman/listinfo/python-list
Re: Insert trusted timestamp to PDF
have a look at: http://www.boscolini.eu/Boscolini/index.php?option=com_contentview=articleid=64%3Anumbering-pdf-file-in-pythoncatid=38%3AprogrammingItemid=55lang=en http://www.boscolini.eu/Boscolini/index.php?option=com_contentview=articleid=64%3Anumbering-pdf-file-in-pythoncatid=38%3AprogrammingItemid=55lang=en here I number some pdf files .. regards, Matteo Il 07/12/2011 20:41, Hegedüs, Ervin ha scritto: Hello Everyone, I'm looking for a tool, which can add a trusted timestamp to an existing PDF file (and can sign - but currently only have to add TS). Could anybody help? Thanks: a. -- http://mail.python.org/mailman/listinfo/python-list