search for: __doc__

Displaying 15 results from an estimated 15 matches for "__doc__".

2012 May 08
2
creation of storage volume fails
...eate the volume using the above storage pool object libvirt.virStoragePool.CreateXML(storagepoolobject,xmldesc,0) from python: -bash-4.1$ python >>> import libvirt >>> dir(libvirt.virStoragePool) ['UUID', 'UUIDString', 'XMLDesc', '__del__', '__doc__', '__init__', '__module__', 'autostart', 'build', 'connect', 'create', 'createXML', 'createXMLFrom', 'delete', 'destroy', 'info', 'isActive', 'isPersistent', 'listVolumes', 'name&...
2011 Sep 06
1
list of all methods winthin an S4 class
Hello,   How can I generate an overview/vector of all the methods winthin an S4 class? Similar to dir() in this Python code: >>> class SomeClass():  def some_method_1(self):   pass  def some_method_2(self):   pass   >>> dir(SomeClass) ['__doc__', '__module__', 'some_method_1', 'some_method_2'] >>>   Thanks in advance! Cheers!! Albert-Jan ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ All right, but apart from the sanitation, the medicine, education, wine, public order, irrig...
2019 Jun 28
2
Re: [PATCH libnbd v3] python: Raise a custom exception containing error string and errno.
.... > > import libnbdmod > > +# Re-export Error exception as nbd.Error, adding some methods. > +from libnbdmod import Error Implement all the cool stuff in pure Python on top of the bare-bones minimum :) Lots less hassle than writing it in C code. I like it! > + > +Error.__doc__ = ''' > +Exception thrown when the underlying libnbd call fails. > + > +This exception has two properties to query the error. Use > +the .string property to return a printable string containing > +the error message. Use the .errno property to return a > +Python errno...
2019 Jun 28
1
Re: [PATCH libnbd v3] python: Raise a custom exception containing error string and errno.
...simple as this (or with one further tweak to __str__ to at least output .errnum when .errno is None): diff --git i/generator/generator w/generator/generator index 7c2fb59..9192988 100755 --- i/generator/generator +++ w/generator/generator @@ -3944,11 +3944,14 @@ from libnbdmod import Error Error.__doc__ = ''' Exception thrown when the underlying libnbd call fails. -This exception has two properties to query the error. Use +This exception has three properties to query the error. Use the .string property to return a printable string containing -the error message. Use the .errno pro...
2019 Jun 28
3
[PATCH libnbd v3] python: Raise a custom exception containing error string and errno.
Following Eric's suggestions from v2, this adds .string, .errno and .__str__ properties. The .string property returns the error string. The .errno property returns the errno (from the errno module), or None. The __str__ property makes the exception nicely printable. Rich.
2017 Feb 26
2
samba-tool domain classicupgrade smb_krb5_context_init_basic failed (Invalid argument)
...lt;file at remote 0x7ffff7fc91e0>, outf=<file at remote 0x7ffff7fc9150>) at remote 0x7fffdd988990>, 'cmd_sambatool': <type at remote 0x73f9c0>, '__package__': None, 'sys': <module at remote 0x7ffff7faebb0>, '__name__': '__main__', '__doc__': None}, locals=locals at entry={'subcommand': 'domain', 'signal': <module at remote 0x7ffff7fe2a60>, 'args': ['classicupgrade', '--verbose', '--debuglevel=0', '--dbdir', '/var/lib/samba/bentley', '--use-xattr...
2017 Feb 16
2
samba-tool domain classicupgrade smb_krb5_context_init_basic failed (Invalid argument)
On Fri, 2017-02-17 at 07:48 +1100, Tom Robinson via samba wrote: > Anyone? Can you please post a gdb backtrace --full? -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 862 bytes Desc: This is a digitally signed message part URL:
2011 Jan 03
1
availability of snapshots functionality via Python bindings
...stems ii python-libvirt 0.4.6-10+lenny1 libvirt Python bindings I don't see anything like snapshots available via libvirt.virDomain: >>> dir(dom0) ['ID', 'OSType', 'UUID', 'UUIDString', 'XMLDesc', '__del__', '__doc__', '__init__', '__module__', '_conn', '_o', 'attachDevice', 'autostart', 'blockPeek', 'blockStats', 'connect', 'coreDump', 'create', 'destroy', 'detachDevice', 'info', 'interfaceSt...
2008 Aug 16
1
python how do i stem words in python?
...a lot! >>> stemmer = xapian.Stem('english') >>> stemmer. stemmer.__call__ stemmer.__reduce_ex__ stemmer.__class__ stemmer.__repr__ stemmer.__delattr__ stemmer.__setattr__ stemmer.__dict__ stemmer.__str__ stemmer.__doc__ stemmer.__swig_destroy__ stemmer.__getattribute__ stemmer.__weakref__ stemmer.__hash__ stemmer.get_available_languages stemmer.__init__ stemmer.get_description stemmer.__module__ stemmer.this stemmer.__new__ ste...
2011 Feb 14
1
Use libvirt-python to attach cdrom
Hi all, I want to attach cdrom by libvirt.py .But can't find a func in libvirt.py can finish this work. Who can help me ? Regard -- Seven Ling E-mail: jiejie.ling at qq.com
2015 Aug 20
1
Fwd: ABRT Daemon/sosreport disaster
...portError: No module named argparse : :Local variables in innermost frame: :__builtins__: <module '__builtin__' (built-in)> :__file__: '/usr/libexec/abrt-action-generate-machine-id' :__package__: None :sys: <module 'sys' (built-in)> :__name__: '__main__' :__doc__: 'This module provides algorithms for generating Machine IDs.\n' -- Robert Inder, 0131 229 1052 / 07808 492 213 Interactive Information Ltd, 3, Lauriston Gardens, Edinburgh EH3 9HH Registered in Scotland, Company no. SC 150689...
2006 Oct 24
1
python-interactive for CentOS/EL 4
Hi all, Could anyone point me in the right direction for a package that provides the 'interactive' module for Python? I need to do some SSH stuff in Python so I grabbed python-paramiko from RPMForge (as always, thanks Dag & co.). Paramiko appears to be dependent on python-crypto but the RPM doesn't require it.. [wmcdonald at willspc ssh]$ ./demo.py Traceback (most recent call
2019 Jun 28
0
Re: [PATCH libnbd v3] python: Raise a custom exception containing error string and errno.
...gt; > +# Re-export Error exception as nbd.Error, adding some methods. > > +from libnbdmod import Error > > Implement all the cool stuff in pure Python on top of the bare-bones > minimum :) Lots less hassle than writing it in C code. I like it! > > > + > > +Error.__doc__ = ''' > > +Exception thrown when the underlying libnbd call fails. > > + > > +This exception has two properties to query the error. Use > > +the .string property to return a printable string containing > > +the error message. Use the .errno property to re...
2019 Jun 28
0
[PATCH libnbd v3] python: Raise a custom exception containing error string and errno.
...quot; py_ret = NULL;\n"; pr " goto out;\n"; pr " }\n"; @@ -3917,6 +3938,36 @@ Read the libnbd(3) man page to find out how to use the API. import libnbdmod +# Re-export Error exception as nbd.Error, adding some methods. +from libnbdmod import Error + +Error.__doc__ = ''' +Exception thrown when the underlying libnbd call fails. + +This exception has two properties to query the error. Use +the .string property to return a printable string containing +the error message. Use the .errno property to return a +Python errno (which may be None in some ca...
2015 Oct 09
3
Python version for scripts in LLVM?
...============================ --- create_ladder_graph.py (revision 249819) +++ create_ladder_graph.py (working copy) @@ -10,6 +10,7 @@ really behaving linearly. """ +from __future__ import print_function import argparse def main(): parser = argparse.ArgumentParser(description=__doc__) @@ -17,27 +18,27 @@ help="Number of ladder rungs. Must be a multiple of 2") args = parser.parse_args() if (args.rungs % 2) != 0: - print "Rungs must be a multiple of 2" + print("Rungs must be a multiple of 2") return - print &q...