Compare commits
1 Commits
slix-1.1
...
sleek-merg
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4512248901 |
@@ -8,15 +8,6 @@ Slixmpp's goals is to only rewrite the core of the library (the low level
|
|||||||
socket handling, the timers, the events dispatching) in order to remove all
|
socket handling, the timers, the events dispatching) in order to remove all
|
||||||
threads.
|
threads.
|
||||||
|
|
||||||
Building
|
|
||||||
--------
|
|
||||||
|
|
||||||
Slixmpp can make use of cython to improve performance on critical modules.
|
|
||||||
To do that, cython3 is necessary along with libidn headers. Otherwise,
|
|
||||||
no compilation is needed. Building is done by running setup.py::
|
|
||||||
|
|
||||||
python3 setup.py build_ext --inplace
|
|
||||||
|
|
||||||
Documentation and Testing
|
Documentation and Testing
|
||||||
-------------------------
|
-------------------------
|
||||||
Documentation can be found both inline in the code, and as a Sphinx project in ``/docs``.
|
Documentation can be found both inline in the code, and as a Sphinx project in ``/docs``.
|
||||||
|
|||||||
@@ -48,9 +48,9 @@ copyright = u'2011, Nathan Fritz, Lance Stout'
|
|||||||
# built documents.
|
# built documents.
|
||||||
#
|
#
|
||||||
# The short X.Y version.
|
# The short X.Y version.
|
||||||
version = '1.1'
|
version = '1.0'
|
||||||
# The full version, including alpha/beta/rc tags.
|
# The full version, including alpha/beta/rc tags.
|
||||||
release = '1.1'
|
release = '1.0'
|
||||||
|
|
||||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||||
# for a list of supported languages.
|
# for a list of supported languages.
|
||||||
|
|||||||
@@ -162,7 +162,7 @@ item itself, and the JID and node that will own the item.
|
|||||||
parameters ``ijid`` and ``node``.
|
parameters ``ijid`` and ``node``.
|
||||||
|
|
||||||
Performing Disco Queries
|
Performing Disco Queries
|
||||||
------------------------
|
-----------------------
|
||||||
The methods ``get_info()`` and ``get_items()`` are used to query remote JIDs
|
The methods ``get_info()`` and ``get_items()`` are used to query remote JIDs
|
||||||
and their nodes for disco information. Since these methods are wrappers for
|
and their nodes for disco information. Since these methods are wrappers for
|
||||||
sending Iq stanzas, they also accept all of the parameters of the ``Iq.send()``
|
sending Iq stanzas, they also accept all of the parameters of the ``Iq.send()``
|
||||||
|
|||||||
@@ -7,8 +7,7 @@
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
if hasattr(asyncio, 'sslproto'): # no ssl proto: very old asyncio = no need for this
|
asyncio.sslproto._is_sslproto_available=lambda: False
|
||||||
asyncio.sslproto._is_sslproto_available=lambda: False
|
|
||||||
import logging
|
import logging
|
||||||
logging.getLogger(__name__).addHandler(logging.NullHandler())
|
logging.getLogger(__name__).addHandler(logging.NullHandler())
|
||||||
|
|
||||||
|
|||||||
@@ -196,13 +196,13 @@ class Form(ElementBase):
|
|||||||
for var, field in fields:
|
for var, field in fields:
|
||||||
field['var'] = var
|
field['var'] = var
|
||||||
self.add_field(
|
self.add_field(
|
||||||
var=field.get('var'),
|
var = field.get('var'),
|
||||||
label=field.get('label'),
|
label = field.get('label'),
|
||||||
desc=field.get('desc'),
|
desc = field.get('desc'),
|
||||||
required=field.get('required'),
|
required = field.get('required'),
|
||||||
value=field.get('value'),
|
value = field.get('value'),
|
||||||
options=field.get('options'),
|
options = field.get('options'),
|
||||||
type=field.get('type'))
|
type = field.get('type'))
|
||||||
|
|
||||||
def set_instructions(self, instructions):
|
def set_instructions(self, instructions):
|
||||||
del self['instructions']
|
del self['instructions']
|
||||||
@@ -221,7 +221,7 @@ class Form(ElementBase):
|
|||||||
|
|
||||||
def set_reported(self, reported):
|
def set_reported(self, reported):
|
||||||
"""
|
"""
|
||||||
This either needs a dictionary of dictionaries or a dictionary of form fields.
|
This either needs a dictionary or dictionaries or a dictionary of form fields.
|
||||||
:param reported:
|
:param reported:
|
||||||
:return:
|
:return:
|
||||||
"""
|
"""
|
||||||
|
|||||||
@@ -9,5 +9,5 @@
|
|||||||
# We don't want to have to import the entire library
|
# We don't want to have to import the entire library
|
||||||
# just to get the version info for setup.py
|
# just to get the version info for setup.py
|
||||||
|
|
||||||
__version__ = '1.1'
|
__version__ = '1.0'
|
||||||
__version_info__ = (1, 1)
|
__version_info__ = (1, 0)
|
||||||
|
|||||||
@@ -240,7 +240,7 @@ def get_AAAA(host, resolver=None, use_aiodns=True, loop=None):
|
|||||||
except Exception as e:
|
except Exception as e:
|
||||||
log.debug('DNS: Exception while querying for %s AAAA records: %s', host, e)
|
log.debug('DNS: Exception while querying for %s AAAA records: %s', host, e)
|
||||||
recs = []
|
recs = []
|
||||||
return [rec.host for rec in recs]
|
return recs
|
||||||
|
|
||||||
@asyncio.coroutine
|
@asyncio.coroutine
|
||||||
def get_SRV(host, port, service, proto='tcp', resolver=None, use_aiodns=True):
|
def get_SRV(host, port, service, proto='tcp', resolver=None, use_aiodns=True):
|
||||||
|
|||||||
@@ -348,7 +348,6 @@ class XMLStream(asyncio.BaseProtocol):
|
|||||||
self.socket = self.transport.get_extra_info("socket")
|
self.socket = self.transport.get_extra_info("socket")
|
||||||
self.init_parser()
|
self.init_parser()
|
||||||
self.send_raw(self.stream_header)
|
self.send_raw(self.stream_header)
|
||||||
self.dns_answers = None
|
|
||||||
|
|
||||||
def data_received(self, data):
|
def data_received(self, data):
|
||||||
"""Called when incoming data is received on the socket.
|
"""Called when incoming data is received on the socket.
|
||||||
|
|||||||
Reference in New Issue
Block a user