2020-07-23 17:54:47 +02:00
# HalfAPI
2024-05-28 01:31:40 +02:00
## 0.6.30
Dependencies updates
- pyYAML v6.0.1
- starlette v0.37.2
Warning : the on_startup halfAPI argument is now removed, use the lifeSpan
2023-12-12 15:03:06 +01:00
## 0.6.29
### Dependencies
Starlette version bumped to 0.33.
2023-08-01 20:50:58 +02:00
## 0.6.28
2023-08-09 14:24:32 +02:00
### Dependencies
Starlette version bumped to 0.31 (had to disable a test to make it work but
seems not important).
2023-08-02 06:32:26 +02:00
### Development dependencies
Python 3.7 is no longer supported (openapi_spec_validator is not compatible).
2023-08-01 20:50:58 +02:00
If you are a developper, you should update dev dependencies in your virtual
environment.
### OpenAPI schemas
This release improves OpenAPI specification in routes, and gives a default
"parameters" field for routes that have path parameters.
Also, if you use halfAPI for multi-domain setups, you may be annoyed by the
change in the return value of the "/" route that differs from "/domain" route.
An HalfAPI instance should return one and only one OpenAPI Schema, so you can
rely on it to connect to other software.
The version number that is contained under the "info" dictionnary is now the "version"
of the Api domain, as specified in the domain dictionnary specified at the root
of the Domain.
The title field of the "info" dictionnary is now the Domain's name.
The ACLs list is now available under the "info.x-acls" attribute of the schema.
It is still accessible from the "/halfapi/acls" route.
2023-08-08 09:09:16 +02:00
#### Schema Components
You can now specify a dict in the domain's metadata dict that follows the
"components" key of an OpenAPI schema.
Use it to define models that are used in your API. You can see an exemple of
it's use in the "tests/dummy_domain/__init__.py" file.
2023-08-01 20:50:58 +02:00
### ACLs
The use of an "HEAD" request to check an ACL is now the norm. Please change all
the occurrences of your calls on theses routes with the GET method.
2023-08-20 23:32:50 +02:00
### CLI
Domain command update :
The `--conftest` flag is now allowed when running the `domain` command, it dumps the current configuration as a TOML string.
`halfapi domain --conftest my_domain`
The `--dry-run` flag was buggy and is now fixed when using the `domai ` command with the `--run` flag.
### Configuration
The `port` option in a `domain.my_domain` section in the TOML config file is now prefered to the one in the `project` section.
The `project` section is used as a default section for the whole configuration file. - Tests still have to be written -
The standard configuration precedence is fixed, in this order from the hight to the lower :
- Argument value (i.e. : --log-level)
- Environment value (i.e. : HALFAPI_LOGLEVEL)
- Configuration value under "domain" key
- Configuration value under "project" key
- Default configuration value given in the "DEFAULT_CONF" dictionary of halfapi/conf.py
### Logs
Small cleanup of the logs levels. If you don't want the config to be dumped, just set the HALFAPI_LOGLEVEL to something different than "DEBUG".
2023-08-01 20:50:58 +02:00
2023-08-31 21:59:17 +02:00
### Fixes
- Check an ACL based on a decorator on "/halfapi/acls/MY_ACL"
2023-02-23 12:41:37 +01:00
## 0.6.27
2023-06-07 11:46:53 +02:00
### Breaking changes
2023-02-23 12:41:37 +01:00
- ACLs definition can now include a "public" parameter that defines if there should be an automatic creation of a route to check this acls
- /halfapi/acls does not return the "result", it just returns if there is a public route to check the ACL on /halfapi/acls/acl_name
2023-02-21 19:22:57 +01:00
## 0.6.26
- Adds the "base_url", "cookies" and "url" to the "halfapi" argument of route definitions
2023-02-08 12:53:32 +01:00
## 0.6.25
- Deletes the "Authorization" cookie on authentication error
2023-02-20 12:18:38 +01:00
- Do not raise an exception on signature expiration, use "Nobody" user instead
2023-02-08 12:53:32 +01:00
2023-02-03 14:22:04 +01:00
## 0.6.24
2023-02-03 12:43:30 +01:00
- Uses the "Authorization" cookie to read authentication token additionnaly to the "Authorization" header
- CLI : allows to run a single domain using the "halfapi domain --run domain_name" command
2023-01-14 12:03:40 +01:00
## 0.6.23
Dependency update version
- starlette v0.23
- orjson v3.8.5
- click v8
- pyJWT v2.6
- pyYAML v6
- toml v0.10
2022-08-18 20:24:57 +02:00
## 0.6.22
2022-08-18 20:19:36 +02:00
2022-09-05 10:20:08 +02:00
- IMPORTANT : Fix bug introduced with 0.6.20 (fix arguments handling)
2022-10-13 12:13:37 +02:00
- BREAKING : A domain should now include it's meta datas in a "domain" dictionary located in the __init__ .py file of the domain's root. Consider looking in 'tests/dummy_domain/__init__.py'
2022-08-18 20:19:36 +02:00
- Add *html* return type as default argument ret_type
- Add *txt* return type
2022-09-06 21:51:48 +02:00
- Log unhandled exceptions
2022-09-02 15:38:59 +02:00
- Log HTTPException with statuscode 500 as critical
2022-09-06 19:58:41 +02:00
- PyJWT >=2.4.0,< 2.5.0
2022-08-18 20:19:36 +02:00
2022-07-18 23:23:09 +02:00
## 0.6.21
- Store only domain's config in halfapi['config']
- Should run halfapi domain with config_file argument
- Testing : You can specify a "MODULE" attribute to point out the path to the Api's base module
2022-08-08 20:19:54 +02:00
- Testing : You can specify a "CONFIG" attribute to set the domain's testing configuration
2022-07-18 23:23:09 +02:00
- Environment : HALFAPI_DOMAIN_MODULE can be set to specify Api's base module
- Config : 'module' attribute can be set to specify Api's base module
2022-07-18 18:47:38 +02:00
## 0.6.20
- Fix arguments handling
2022-07-06 08:31:00 +02:00
## 0.6.19
- Allow file sending in multipart request (#32)
- Add python-multipart dependency
2022-06-23 15:48:58 +02:00
## 0.6.18
- Fix config coming from .halfapi/config when using HALFAPI_DOMAIN_NAME environment variable
2022-06-23 11:07:41 +02:00
## 0.6.17
- Fix 0.6.16
- Errata : HALFAPI_DOMAIN is HALFAPI_DOMAIN_NAME
- Testing : You can now specify "MODULE" class attribute for your "test_domain"
subclasses
2022-06-23 07:24:05 +02:00
## 0.6.16
- The definition of "HALFAPI_DOMAIN_MODULE" environment variable allows to
specify the base module for a domain structure. It is formatted as a python
import path.
The "HALFAPI_DOMAIN" specifies the "name" of the module
2022-05-17 16:19:41 +02:00
## 0.6.15
- Allows to define a "__acl__" variable in the API module's __init__ .py, to
specify how to import the acl lib. You can also specify "acl" in the domain's
config
2022-05-17 10:31:34 +02:00
## 0.6.14
- Add XLSXResponse (with format argument set to "xlsx"), to return .xlsx files
2022-03-21 09:48:34 +01:00
## 0.6.13
- (rollback from 0.6.12) Remove pytest from dependencies in Docker file and
remove tests
- (dep) Add "packaging" dependency
- Add dependency check capability when instantiating a domain (__deps__
variable, see in dummy_domain)
2022-03-17 17:48:41 +01:00
## 0.6.12
- Installs pytest with dependencies in Docker image, tests when building image
2022-03-14 15:16:06 +01:00
## 0.6.11
- Fix "request" has no "path_params" attribute bug
2022-03-08 19:24:21 +01:00
## 0.6.10
- Add "x-out" field in HTTP headers when "out" parameters are specified for a
route
- Add "out" kwarg for not-async functions that specify it
2022-03-02 16:46:32 +01:00
## 0.6.9
- Hide data fields in args_check logs
2022-02-28 10:21:01 +01:00
## 0.6.8
- Fix testing lib for domains (add default secret and debug option)
2021-12-08 16:42:12 +01:00
## 0.6.2
- Domains now need to include the following variables in their __init__ .py
- __name__ (str, optional)
- __id__ (str, optional)
- halfapi domain
2020-07-23 17:54:47 +02:00
## 0.1.0
- Mounts domain routers with their ACLs as decorator
- Configuration example files for systemd and a system-wide halfapi install
- Runs projects
- Handles JWT authentication middleware