Commit graph libervia-backend/sat/plugins/plugin_xep_0050.py
Author SHA1 Message Date
Goffi
6a6f15707a massive refactoring to switch from camelCase to snake_case:
historically, Libervia (SàT before) was using camelCase as allowed by PEP8 when using a
pre-PEP8 code, to use the same coding style as in Twisted.

However, snake_case is more readable and it's better to follow PEP8 best practices, so it
has been decided to move on full snake_case. Because Libervia has a huge codebase, this
ended with a ugly mix of camelCase and snake_case.

To fix that, this patch does a big refactoring by renaming every function and method
(including bridge) that are not coming from Twisted or Wokkel, to use fully snake_case.

This is a massive change, and may result in some bugs.
2023-04-08 13:54:42 +02:00
Goffi
2389f235f1 plugin XEP-0050: use coroutine + minor code readability improvments:
rel 372
2022-09-21 22:33:59 +02:00
Goffi
3da29896df plugin XEP-0050: show notes when there is a data form on completed command:
Notes are now added on completed command, as text widgets.
2021-05-05 15:37:33 +02:00
Goffi
63875ae4f1 component file sharing (plugin management): new command to get available quota/used space. 2021-05-05 15:37:33 +02:00
Goffi
dc86957043 date update 2021-03-19 15:45:14 +01:00
Goffi
03cffe789c core: minor typos, docstring/comments update 2020-09-20 14:05:40 +02:00
Goffi
ef23eca7cd plugin XEP-0050: typo 2020-08-01 15:58:20 +02:00
Goffi
762f96acb2 plugin XEP-0050: some modernisation + adHocSequence:
improved code by reordering imports, adding some type hints, using standard dict instead
of OrderedDict, etc.

New sequence method/adHocSequence bridge method allow to easily send a sequence of data to
a well known ad-hoc node.
2020-06-19 15:35:45 +02:00
Goffi
e1a44cf4e4 fixed shebangs 2020-01-29 10:07:00 +01:00
Goffi
a39349fe64 dates update 2020-01-29 09:50:54 +01:00
Goffi
fbfe96c505 Python 3 port:
/!\ this is a huge commit
/!\ starting from this commit, SàT is needs Python 3.6+
/!\ SàT maybe be instable or some feature may not work anymore, this will improve with time

This patch port backend, bridge and frontends to Python 3.

Roughly this has been done this way:

- 2to3 tools has been applied (with python 3.7)
- all references to python2 have been replaced with python3 (notably shebangs)
- fixed files not handled by 2to3 (notably the shell script)
- several manual fixes
- fixed issues reported by Python 3 that where not handled in Python 2
- replaced "async" with "async_" when needed (it's a reserved word from Python 3.7)
- replaced zope's "implements" with @implementer decorator
- temporary hack to handle data pickled in database, as str or bytes may be returned,
  to be checked later
- fixed hash comparison for password
- removed some code which is not needed anymore with Python 3
- deactivated some code which needs to be checked (notably certificate validation)
- tested with jp, fixed reported issues until some basic commands worked
- ported Primitivus (after porting dependencies like urwid satext)
- more manual fixes
2019-08-13 19:08:41 +02:00
Goffi
007575d62b plugin XEP-0050: make plugin usable with components + new adHocError method to easily raise error when needed 2019-04-26 11:57:26 +02:00
Goffi
8e338bf913 date update 2019-01-12 12:25:31 +01:00
Goffi
ae90df1a4a plugin XEP-0050, adhoc D-Bus: Ad-Hoc improvment + remote media control:
- "commands" namespace is now registered
- added "do" and "getCommandElt" methods to XEP-0050 to run ad-hoc commands from backend
- commands for a profile are now stored in client._XEP_0050_commands
- Ad-Hoc D-Bus plugin can now be run without lxml or dbus (degraded)
- use MPRIS to control media players
- new adHocRemotesGet bridge method retrieve media players announced in all devices of the profile
2018-08-31 15:47:00 +02:00
Goffi
744cb0c503 code style reformatting using black 2018-06-27 20:14:46 +02:00
Goffi
da147c5cc7 plugin XEP-0050: filter form received from form-processing entity, to only keep "form" and "result" types 2018-05-11 18:20:39 +02:00
Goffi
80ef13612b core, setup: huge cleaning:
- moved directories from src and frontends/src to sat and sat_frontends, which is the recommanded naming convention
- move twisted directory to root
- removed all hacks from setup.py, and added missing dependencies, it is now clean
- use https URL for website in setup.py
- removed "Environment :: X11 Applications :: GTK", as wix is deprecated and removed
- renamed sat.sh to sat and fixed its installation
- added python_requires to specify Python version needed
- replaced glib2reactor which use deprecated code by gtk3reactor

sat can now be installed directly from virtualenv without using --system-site-packages anymore \o/
2018-04-02 19:44:50 +02:00
Renamed from src/plugins/plugin_xep_0050.py (Browse further)