Commit Graph

48 Commits

Author SHA1 Message Date
91e548569d runtime logger handler selector 2023-05-29 03:41:11 +03:00
c73a6c7bae PEP-673 use Self as return type for classmethods (#94)
* PEP-673 use Self as return type for classmethods

* add dummy test file

* remove python3.10 compat
2023-05-04 03:28:08 +03:00
fde75a14c2 PEP-561 complaint: add py.typed marker 2023-04-17 18:56:49 +03:00
10fbc31d2a PEP-585 complaint: remove type aliases (#93) 2023-04-12 04:09:28 +03:00
fc01bf3d1c use api generated docs instead of comments (#92) 2023-04-06 00:24:39 +03:00
b09aea13af add config validator subcommand (#80)
* add config validator subcommand

* add --exit-code flag

* docs & faq update
2023-01-09 18:22:29 +03:00
e41dd09a8a force upgrade sphinx documentation 2022-12-30 22:58:13 +02:00
8e65263b90 add completion files generated by shtab 2022-12-30 21:19:23 +02:00
0f8596db1e replace alert bodals with toasts 2022-12-09 11:33:19 +02:00
fe66c6c45c implement support of unix socket for server
This feature can be used for unauthorized access to apis - e.g. for
reporting service if it is run on the same machine. Since now it becomes
recommended way for the interprocess communication, thus some options
(e.g. creating user with as-service flag) are no longer available now
2022-12-02 01:41:23 +02:00
41cc58ed31 add rebuild implementation to interface 2022-12-02 01:41:23 +02:00
9fa1fa108f add key-import button to interface 2022-12-02 01:41:23 +02:00
4462eba860 render httpunauthorized as html in plain http requests 2022-11-22 23:40:27 +02:00
14cb548c3b Extended package status page (#76)
* implement log storage at backend
* handle process id during removal. During one process we can write logs from different packages in different times (e.g. check and update later) and we would like to store all logs belong to the same process
* set package context in main functions
* implement logs support in interface
* filter out logs posting http logs
* add timestamp to log records
* hide getting logs under reporter permission

List of breaking changes:

* `ahriman.core.lazy_logging.LazyLogging` has been renamed to `ahriman.core.log.LazyLogging`
* `ahriman.core.configuration.Configuration.from_path` does not have `quiet` attribute now
* `ahriman.core.configuration.Configuration` class does not have `load_logging` method now
* `ahriman.core.status.client.Client.load` requires `report` argument now
2022-11-22 02:58:22 +03:00
43696b9920 Make optional dependencies trully optional (#67)
The issue appears when there is no boto, jinja and some other libraries
are not installed because the classes which use these libraries are
still being imported inside the package file. The fix removes those
imports from package root, because they should not be here, in fact,
content of report and upload packages must be imported only inside the
trigger class and only if they are actually required

This commit also adds setuptools as required dependency since it is used
for some parsers (previously it was provided dependency)
2022-09-11 01:44:06 +03:00
d7966e419d add shell and version parser 2022-05-27 18:34:07 +03:00
3a5268993e update readme 2022-05-22 16:00:24 +03:00
b1dfafe275 dynamic html load (#63)
* dynamic html load
* split by classes
2022-05-20 22:29:36 +03:00
2dac5a2520 Docs update (#61)
* Improve sphinx documentation

* update faq formatting

* fix setup doc

* fix docs according to the generated htmls
2022-05-06 02:54:37 +03:00
03633d47ea readthedoc integration 2022-04-18 04:39:40 +03:00
1a575d6db8 move documentation to tox 2022-04-18 01:48:36 +03:00
fb7275f9dd change telegram default index to telegram-index 2022-04-08 04:32:34 +03:00
d4eadf0013 migrate to tox
this also requires to move default configuration files to share/ahriman.
Thus the following features have been added
* default configuration is not stored in /usr/share/ahriman/settings
* package installed via PKGBUILD now copies files from /usr
* configuration class now fallbacks to default in /usr
2022-03-21 04:38:42 +03:00
6ee1c8ef5a replace pspec with spec 2022-03-20 03:08:51 +03:00
9197b416e6 use own aur wrapper (#49) 2022-02-06 03:44:57 +03:00
5f7f58041d docs update 2021-10-15 04:55:46 +03:00
d60c553ea2 add debugtoolbar support 2021-09-26 12:31:12 +03:00
56c642e2a9 add manpage 2021-09-19 13:56:11 +03:00
22272167e6 change spelling for distro name 2021-09-13 02:49:22 +03:00
168b2f6880 OAuth2 (#32)
* make auth method asyncs

* oauth2 demo support

* full coverage

* update docs
2021-09-12 21:41:38 +03:00
5bb244cbe8 add static files support and cookie expiration settings 2021-09-11 16:34:43 +03:00
f3fd0780fb documentation update 2021-09-10 03:32:45 +03:00
11c03a9041 Add ability to trigger updates from the web (#31)
* add external process spawner and update test cases

* pass no_report to handlers

* provide service api endpoints

* do not spawn process for single architecture run

* pass no report to handlers

* make _call method of handlers public and also simplify process spawn

* move update under add

* implement actions from web page

* clear logging & improve l&f
2021-09-10 00:33:35 +03:00
19ba2ba8e5 migration of jinja tempaltes to bootstrap (#30) 2021-09-05 05:27:58 +03:00
b7cff0a19d Auth support (#25)
* initial auth implementation

* add create user parser

* add tests

* update dependencies list

* add login annd logout to index also improve auth

* realworld fixes

* add method set_option to Configuration and also use it everywhere
* split CreateUser handler to additional read method
* check user duplicate on auth mapping read
* generate salt by using passlib instead of random.choice
* case-insensetive usernames
* update dependencies
* update configuration reference
* improve tests

* fix codefactor errors

* hide fields if authorization is enabled, but no auth supplied

* add settings object for auth provider

* readme update
2021-09-02 23:36:00 +03:00
c15cc4b853 disable manpages building for now since it requires installed distribution 2021-08-19 02:35:48 +03:00
8f55cc600e add manpage generator 2021-08-17 04:05:18 +03:00
62661c9fb1 add bandit integration and fix its warnings 2021-08-11 02:45:13 +03:00
aad599be67 Native s3 sync (#23)
* Native S3 sync implementation

* fix imports

* fix paths reading

* install s3 components duriing test stage
2021-08-10 23:18:56 +03:00
856a94ff00 import pgp key implementation (#17)
* import pgp key implementation

* do not ask confirmation for local sign. Also add argparser test

* superseed requests by python-aur package

* ...and drop --skippgpcheck makgepkg flag by default
2021-04-10 01:37:45 +03:00
f383b04754 try to integrate with github workflows 2021-03-28 23:13:42 +03:00
60b8477cde Add tests (#1) (#5)
* add models tests (#1)

also replace single quote to double one to confort PEP docstring
+ move _check_output to class properties to make it available for
mocking

* alpm tests implementation

* try to replace os with pathlib

* update tests for pathlib

* fix includes glob and trim version from dependencies

* build_tools package tests

* repository component tests

* add sign tests

* complete status tests

* handle exceptions in actual_version calls

* complete core tests

* move configuration to root conftest

* application tests

* complete application tests

* change copyright to more generic one

* base web tests

* complete web tests

* complete testkit

also add argument parsers test
2021-03-28 15:30:51 +03:00
356cd35c5f better templating 2021-03-13 05:12:53 +03:00
371019f899 add depdendency manager and switch to pyalpm instead of expac 2021-03-12 00:04:37 +03:00
1770793e69 improvements
* multi-sign and multi-web configuration
* change default configuration to do not use architecture
* change units to be templated
* some refactoring
2021-03-11 03:57:23 +03:00
fd2049b334 web server support 2021-03-11 01:14:09 +03:00
b3345c4184 jinja templates support 2021-03-08 15:52:02 +03:00
53d21d6496 initial import 2021-03-05 01:45:36 +03:00