Admire twisted's zookeeper
Twisted contains a server that can be written in Python as the tool for running daemon, which has encountered some problems in recent debugging. Although it cannot be clearly described at the moment, it is for your reference.
In a system containing gcc4.x, this twistd runs normally. However, if gcc3.x is contained (for example, gcc3.4.6), the failure of importing other modules in the same path will occur and an importerror exception will be reported. This is very common in many centos, but there is no problem in comparing the new versions of Ubuntu and debian4.0.
Of course, there is a solution to the fault of zookeeper. That is, add the on-card path to SYS. Path to force the system to find other modules in the current path.CodeAs follows:
Import sys
Curpath = OS. Path. normpath (OS. Path. Join (OS. getcwd (), OS. Path. dirname (_ file __)))
SYS. Path. append (curpath)
After the code, you can import other modules in the current path.
Meeting.