Commit Graph

3042 Commits

Author SHA1 Message Date
Stephan Erb 088916f4e7 Strip PEP info at the network level.
(Currently it is done at the UI level in many, many different places)
2009-11-14 23:07:22 +01:00
Stephan Erb 3d5e8cc427 Move common pep constructor logic to base class. 2009-11-14 22:47:21 +01:00
Stephan Erb 99e718583a Initial simplification of PEP data extraction by moving the extraction methods to the newly created PEP classess.
If-else-retract complexity is substituted by dictionaries.
2009-11-14 22:31:27 +01:00
Stephan Erb 7c6dc424af Make user_tune a instance method, not a function. 2009-11-14 20:54:42 +01:00
Stephan Erb 85b7b89b49 Create a class for each PEP XEP that we support. Dispatch an event to the Interface() handlers when we have have received a PEP event. 2009-11-14 20:48:33 +01:00
Stephan Erb 30580702d5 Create a ConnectionPEP class and directly register its callback to handle pep events. 2009-11-14 19:56:15 +01:00
Stephan Erb ac5d0f24da Fix error in the documentation of our xmpp dispatcher fork.
Raise NodeProcessed if the stanza should NOT be handled by other user handlers.
2009-11-14 19:54:33 +01:00
Stephan Erb 3696e5296d Merge local changes. 2009-11-13 08:58:00 +01:00
Stephan Erb 36fb5def4b Shrink public interface of the MetacontactManager. 2009-11-12 22:58:45 +01:00
Stephan Erb ee5eb8b546 Try to handle incomplete HTTP. See #5401. Please test.
Approach: Keep filling the receive buffer until we have found enough data to extract the first HTTP header and body
2009-11-12 21:23:10 +01:00
Stephan Erb 022003239d Merge changes from default branch into refactoring branch
Hg: changed data/pixmaps/mic_active.png
2009-11-11 23:37:46 +01:00
Stephan Erb af3af5bec8 Remove caps which have not been seen for three months from the db.
Thanks Asterix for the initial version of this patch!
2009-11-11 23:14:51 +01:00
Stephan Erb 8203211e74 Inject account object instead of account string into contact instances.
Each contact has now access to the account object instead of the account string.
2009-11-11 21:38:39 +01:00
Stephan Erb ae9376ff63 Split the 'account sensitive' parts of the Contacts class and move them to an intermediate Contacts_New class.
The Contact class remains the public interface for contact handling. This is only a single step of a longer refactoring to empower the Account class.
2009-11-10 22:56:10 +01:00
Stephan Erb b4285302db Make the GC_Contacts class 'account insensitive'. Instead, create an Account class which holds a GC_Contacts object.
The API has been preserved. For now the old Contacts() API has not been changed.
2009-11-10 21:08:25 +01:00
Stephan Erb 3ddc5ce78e Use implicit delegation with __getattr__ instead of explicit delegation via method calls 2009-11-10 19:26:17 +01:00
Stephan Erb 2c296f3fe0 Create a GC_Contacts() class and move groupchat related behavior to it.
This is similar to what has been done with the MetacontactManager
2009-11-10 19:05:47 +01:00
Stephan Erb ba9ef8301b Remove superfluous clear_contacts method 2009-11-09 23:03:16 +01:00
Stephan Erb 004619f99e Work around a reported NoneType exception. 2009-11-09 22:03:14 +01:00
Stephan Erb d5ac527f84 Filter duplicate groups centrally. 2009-11-09 21:51:43 +01:00
Stephan Erb cec93b6135 Push method to check if a specific ClientCaps supports a feature down to the caps module.
Public interfaces stay the same.
2009-11-09 21:26:56 +01:00
Yann Leboulanger 8f2120371b update correctly self_contact Contact instance and roster row when we use an anonymous account (our jid changes in this case). Fixes #5370 2009-11-07 12:37:16 +01:00
Yann Leboulanger 11f01f1c1c fix traceback when disconnecting from BOSH. 2009-11-06 17:58:39 +01:00
Yann Leboulanger 697d2a7324 fix BOSH connection with ejabberd. Fixes #5401 2009-11-06 17:58:14 +01:00
Yann Leboulanger 2061dd2118 fix receiving long messages in several parts with BOSH. see #5401 2009-11-12 22:13:11 +01:00
Yann Leboulanger ae9f7ca410 prevent a traceback when we disconnect a zeroconf socket wil a message attribute. Fixes #5049 2009-11-12 21:42:20 +01:00
Yann Leboulanger ea5429b248 fix XEP-202 implementation, child element must be <time>, not <query>. Fixes #5412 2009-11-06 08:11:07 +01:00
Stephan Erb 17af7902e4 Make it explicit whether an ordinary Contact, a Self Contact or a Not-In-Roster Contact is created. 2009-11-05 22:16:38 +01:00
Stephan Erb f297aa0a11 Make methods of MetacontactManager private if those are only used internally 2009-11-05 20:09:26 +01:00
Yann Leboulanger 4743d224fd fix sending message to several contacts (in this case we cannot get a contact instance as there are several jids in one. Fixes #5408 2009-11-05 19:44:01 +01:00
Stephan Erb 0abb1dfd20 Extract class: MetacontactManager from Contacts
For easy migration, interface is still preserved.
2009-11-05 19:43:25 +01:00
Yann Leboulanger eb32680a91 fix caps query verification. 2009-11-05 19:24:27 +01:00
Yann Leboulanger c8cc5be366 don't print libasyncns warning on stdout. Fixes #5407 2009-11-05 19:14:19 +01:00
Yann Leboulanger 32309d2a30 [marcin.bachry] disconnect once proxy has been tested. Fixes #5409 2009-11-05 19:11:31 +01:00
Stephan Erb 7829e7d40c Removed unused module 'meta.py' 2009-11-05 17:05:13 +01:00
Stephan Erb 8a127b4e4d Several small bugfixes: Add missing accout parameter to constructors. 2009-11-05 16:53:30 +01:00
Stephan Erb 89b1c6a7df Move method close to data.
gajim.contacts.contact_from_gc_contact(gc_contact) is now gc_contact.as_contact()
2009-11-05 16:25:13 +01:00
Stephan Erb 06129f45ef Let contact instances know their corresponding account.
contact.account and gc_contact.account contains the account name of the owning account. There is still code around in many placed which tries to workaround this missing information. Such code has to be migrated on per-need basis.
2009-11-05 15:57:43 +01:00
Yann Leboulanger 1a76b72b58 fix bosh url parsing (wrong regex replaced by urlparse.urlsplit() funxtion) 2009-11-05 08:50:21 +01:00
Stephan Erb c1cbc07645 Check for empty caps values and not just for None. See #5399
This prevents our caps cache from getting filled with invalid caps values. Furtheremore, NullClientCaps has been saveguarded so that it won't fail for people with already tainted caches.
2009-11-04 23:05:20 +01:00
Yann Leboulanger b2a4c92e7a better error handling 2009-11-04 22:06:45 +01:00
Yann Leboulanger 2aef55ad2a better URI splitting code. see #5400, #5401 2009-11-04 21:56:33 +01:00
Yann Leboulanger 4343d706a0 use default port for bosh proxy when none is provided. Fixes #5400, #5401 2009-11-04 21:17:57 +01:00
Yann Leboulanger cb1fcc8cf8 update ft proxies list 2009-11-01 16:50:27 +01:00
Yann Leboulanger 21ffce890c Backed out changeset f169c518cd8d
sqlite with ? doesn't work as expected
2009-11-01 12:14:42 +01:00
Yann Leboulanger b0712e1774 replace all %d / %s things in SQL queries by ? for security reasons 2009-10-31 23:57:14 +01:00
Yann Leboulanger d5351f6328 ignore unknown show types when we receive strange stanza. 2009-10-31 23:22:12 +01:00
Stephan Erb a9f5bb59d7 Merge changes from default branch into refactoring branch 2009-10-31 17:25:47 +01:00
Stephan Erb 47700e67da Rename CacheItem.update to CacheItem.set_and_store as this seems more intense giving. 2009-10-31 09:14:55 +01:00
Stephan Erb 99e8487db9 Move compute_caps_hash from helpers to caps module. 2009-10-30 23:55:03 +01:00