Commit graph

492 commits

Author SHA1 Message Date
Alexandre Aubin
65fe685a90 Get rid of this 'help' madness and more generally this three-tuppled containing various tuples and weird stuff ... use a simple dict everywhere instead 2019-08-20 05:43:17 +02:00
Alexandre Aubin
cad2cd8006 Get rid of the _format_conf madness. Instead, have clear functions to define if authentication is required, trigger the auth process if so 2019-08-20 05:43:09 +02:00
Alexandre Aubin
968667d9ed Try to improve the semantic of where/when the auth happens... 2019-08-20 03:32:52 +02:00
Alexandre Aubin
8d77fdb9a4 Cleaned unused stuff or overly complicated for no reason 2019-08-20 03:31:37 +02:00
Alexandre Aubin
83d9e772e7 Nowadays we don't have .errno anymore ? 2019-08-20 00:45:05 +02:00
Alexandre Aubin
3878ffdc04
Merge pull request #213 from YunoHost/detailed_error_messages_for_assert
[mod] add detail error messages on asserts
2019-08-18 14:12:56 +02:00
Alexandre Aubin
b393d55ebd Gotta catch them all... 2019-08-05 18:01:05 +02:00
Alexandre Aubin
2e2e627894 [yolo] Add a write_to_yaml utility similar to write_to_json 2019-08-05 17:59:10 +02:00
Luke Murphy
d52a574f77 Test documentation under Tox 2019-08-04 19:46:20 +02:00
Laurent Peuch
f49c004a59 [mod] add detail error messages on asserts 2019-08-04 18:48:16 +02:00
Alexandre Aubin
758778a04b Typo 2019-08-03 21:24:48 +02:00
Luke Murphy
659e20d5f5
Import DATA_DIR correctly
Fix for f6bfabc7aa.
2019-08-01 16:51:04 +02:00
Alexandre Aubin
f6bfabc7aa
Merge pull request #207 from decentral1se/refactor-global-loading
Refactor global loading
2019-08-01 12:20:38 +02:00
Luke Murphy
dfd0868510
Use flake8 under Tox and fix complaints 2019-07-29 13:26:16 +02:00
Laurent Peuch
1f10529209 [fix] syntax error, again -_-' 2019-07-29 03:56:10 +02:00
Laurent Peuch
599bec33b8 [fix] bad key, we aren't in self.local situation 2019-07-29 02:44:04 +02:00
Luke Murphy
14a3d63453
Test the cache file opening and creation 2019-07-28 22:04:07 +02:00
Luke Murphy
e027a188a9
Refactor exposing of global configuration
We do this to make it easier to control this value during testing. We
should not import these values at package setup time. Nor should we
import them at package load time.

This change introduces a new API for the Moulinette package. The
moulinette.env accessor. This is a breaking change. However, I've
searched around and can't seem to find any usage that relies directly on
these properties being available.

I've tried to maintain API backwards compatibility in all cases
otherwise.
2019-07-28 22:04:07 +02:00
Laurent Peuch
737f2dd967 [fix] missing argument for translation string formatting 2019-07-28 21:38:19 +02:00
Laurent Peuch
2403ee1b7d [mod] during tests failed to translate string is an error 2019-07-28 21:29:50 +02:00
Laurent Peuch
fdf9a719f1 [mod] way better failed translation error messages 2019-07-28 21:27:41 +02:00
Laurent Peuch
a8966b8643 [mod] add more message to inform users that some stuff are a warning 2019-07-28 21:14:24 +02:00
Bram
76c8620861
Merge pull request #205 from YunoHost/warning_long_lock
Warn the user about long locks for a way better UX
2019-07-28 18:56:43 +02:00
Bram
a22208ce40
[fix] typo, created a tuple instead of a string 2019-07-28 15:28:17 +02:00
Bram
bce7aee510
Merge pull request #208 from YunoHost/better_debug_gpg
Better debug information related to gpg for storing session
2019-07-28 06:02:50 +02:00
Bram
b7d415dc2c
[ux] make warning clearer because users often report it 2019-07-26 18:29:19 +02:00
Laurent Peuch
ca49ffefc1 [ux] also inform the user once we've stopped waiting for the lock 2019-07-25 04:15:52 +02:00
Laurent Peuch
79347af868 [mod/ux] display the real error when failed to retrieve session 2019-07-23 04:00:37 +02:00
Alexandre Aubin
3c9230ee9f
Merge pull request #204 from YunoHost/toml-utils
add utils.filesystem.read_toml and depends on toml in moulinette
2019-07-21 13:34:28 +02:00
Laurent Peuch
9c6c92b2c1 [mod] death to silent unverbose errors èwé 2019-07-20 16:03:30 +02:00
Bram
d72340f536
[mod] typo in comment
Co-Authored-By: decentral1se <lukewm@riseup.net>
2019-07-20 14:44:23 +02:00
Laurent Peuch
44878d7148 [ux] add a warning mecanism to inform the user about the current lock 2019-07-20 05:53:00 +02:00
Laurent Peuch
02c320f553 [mod] add debug log telling we are trying to aquired the log 2019-07-20 05:52:08 +02:00
Luke Murphy
ee1c67811b
Migrate utility tests to Pytest top level folder 2019-07-14 11:58:57 +02:00
Luke Murphy
5744dbd6fa
Use correct key for this locale lookup 2019-07-14 11:58:57 +02:00
Luke Murphy
14c4fafd39
Localise import to avoid setuptools install error 2019-07-14 01:31:38 +02:00
Luke Murphy
b78a7ca584
Make globals overridable 2019-07-14 01:31:37 +02:00
Laurent Peuch
7b65a3b6c2 [enh] add read_toml util 2019-07-07 05:48:10 +02:00
Josué Tille
e91ab96cb7
Fix pep 2019-05-28 22:13:26 +02:00
Josué Tille
a951b6f9a2
Add the possibility to filter the returned entry 2019-05-26 00:45:44 +02:00
Josué Tille
eeadb2ce17
Create a LDIF parser 2019-05-25 23:50:59 +02:00
Alexandre Aubin
ff6343c53a Merge branch 'stretch-unstable' into sasl_authentication 2019-05-02 15:20:33 +02:00
Alexandre Aubin
0e16546af9 [fix] Microdecision : do not miserably crash if the lock does not exist when attempting to release it 2019-04-08 18:15:00 +02:00
Alexandre Aubin
0a300e50d7 [microdecision] Fix case where stdinfo is not provided 2019-03-22 01:03:33 +01:00
Alexandre Aubin
1e90dd4bb1
Make sure gpg actually does something (#182) 2018-12-18 16:17:17 +01:00
Alexandre Aubin
1ce8ea9ffc
Merge branch 'stretch-unstable' into autopep8 2018-12-15 15:13:25 +01:00
Alexandre Aubin
e6c41b100b
Merge pull request #180 from irina11y/enh-moulinette-error
[enh] Simplify moulinette errors
2018-12-15 15:08:58 +01:00
Alexandre Aubin
5ec49c1b80 StandardError -> Exception (for python3 compat') 2018-12-14 16:24:04 +00:00
Alexandre Aubin
8e91c0d0d3 Get rid of error_to_response and trigger 400 error for all MoulinetteErrors instead 2018-12-14 16:21:48 +00:00
Alexandre Aubin
fddf64a20d __raw_msg__ -> raw_msg 2018-12-14 14:20:37 +00:00