Changelog
Todos los cambios notables en este proyecto se documentarán en este archivo.
El formato se basa en Keep a Changelog, y este proyecto intenta, pero no necesariamente se adhiere al Versionado Semántico, a decir verdad, se parece más al Versionado por Calendario.
Por aquí hay un post genial, acerca de cada una de estas formas de versionado de software.
Unreleased
Added
Changed
Fixed
Removed
2024.02.16
Added
- support for fields alias on
raw_query
(contrib/mongoDB/mongo_model.py) - a better way to export requirements see commands and tools
- more date utils functions
- added cors support
- background version 0.2.1
Changed
- fix readme
- too much documentation added and/or updated
Fixed
Removed
2023.12.09
Added
- function
hash_from_dict
to generate hash from dict/object (utils/security.py) - firebase connect function (contrib/firebase/connect.py)
allowed_files
functionrealtime_api
function to send data to real time api (this function usesget_gcp_auth_token
to get gcp token)- contrib module for resend mail
- contrib module for foreign exchange
firebase_connect
function- missing async key and return
send_sms_api
(contrib/sms/twilio_sms.py) function- example modules
- contrib module for gcp auth tokens
- middleware
custom_http_exceptions
for handle custom http exceptions , added new error messages - test for api router cities 🆕
- test for api router cities
- module for health check probe
- validation for
'Accept-Encoding'
header and more: - change error messages
user_id
to request.state (/common/middlewares/auth.py)- new error messages, added missing try/except
- cloud build info
- script for tests
- ignore gcp config, fix docker ignore
- more params on MongoClient
- missing 'updated_at' (contrib/mongoDB/mongo_model.py)
Changed
- change
ORJSONResponse
, now usinghttp.response
function (core/resource_model.py) - reaname custom headers params on (/common/http/rest.py)
- more depends on gcp group(), added
firebase-admin
(pyproject.toml) - many docs... for GAE cloud run, fly io, contrib modules
Fixed
- twilio uri api
- logger added try/except mongo close conn
- ORJSONResponse base_api,
- reformat error messages bigquery, mongo connect
- status codes (/app/error_handlers.py)
- fix close function (contrib/mongoDB/connect.py)
- define some vars on firebase config (/contrib/gcp/auth.py)
- fix docs and format string message (/contrib/mail/resend_email.py)
- remove logs, fix indent, missing keys
- module for firebase storage (via admin) fix doc on connect
- fix params and types on response function, the way in which error responses are generated is changed
- typing fix/rework some functions is_valid_hour compare_times add_days compare_times
- examples, locales now using fastapi_restful, roles now using apiRouter
- warning on Draft202012Validator
- docs, fix timeout
- mongo session
- added exception on get_prefix method
as_dict
now using try/except- fix ollection.delete_on filters
Removed
data
key (/app/error_handlers.py) method request (now use self.req
), rename imports prints update reqs unused cli apps (Dockerfile) many unused logs
2023.11.07
Added
response_raw
function (http/response.py)add_days
,add_months
,add_time
andadd_date
(utils/date_utils.py) although revision is needed- template for
restful
model, view, url, dto - template generator for
restful cruds
DefaultMetaDto
(app/common/types.py), for metadadata endpoints- awesome JSON Over POST, template generator (tools/crud_json_over_post.py)
- crud template for mongo (at time)
- tools utils for template and other stuff
- Json Over Post
View
,model
andDto
template (tools/templates/json_over_post/) - JSON Over POST crud (tools/crud_json_over_post.py)
- initial configuration and templates for JSON over POST (tools/templates/json_over_post/)
- function
generate_schema
for create jsonschema info from pydantic models (app/utils/gen_schema.py) - new types
DefaultFieldList
,DefaultSearchDto
,DefaultDeleteDto
is enabled for mongoDB (app/common/types.py) - example of validation, using
jsonschema
- test for locales
- use Thread to create background task, thanks to gabrieljf217
- retries(urllib3.util Retry) to some methods
add_router
function to handle APIRouter routes- move from init,
add_middleware
andadd_exception_handler
(app/server.py) - method
not_allowed
(APIRouter 405 handler) ForceGZipMiddleware
in replacement of "added_gzip_header" better doc, comment "pre_ordered_middlewares"LogRequestMiddleware
in replacement of "after_request"
Changed
- change name on
DefaultToken
- valid if using restful or json_over_post
- rework
crud_gen
, now in many modules - validate function using JSONSchema draft 2020-12 increase maxfail (pytest options)
- more strict validation on locales
- set theme (mkdocs)
- change name to 'details' on http/response
- update twilio, pyotp, minor fixeds
- move code to
error_handlers
, middlewares andserver files
reorganize error handlers (app/error_handlers.py ) - fully rework, now this data live in app/server (main.py)
- update project url (https://cutt.ly/callisto)
- docs: changes to 2023.10.03
- docs: a tag is added to an older version
- docs: corrections in the documentation of many modules to mention here
Fixed
- enum to
AuthRoles
, remove unused role - change default role to GOTU (tools/templates/json_over_post/)
- added many try/Exception on utils/otp
- added missing crud operations with mongoDB, rename macro names
- added
id
toSearchDto
- field name (json_over_post/model_.py)
- added more fields on search, added fix(noqa: A003) on id fields, comments examples
- error messages, added get_by_id method
- and change 'id' field, now use 'item_id' and avoid ruff's A002 issue
A003
(using noqa) ( app/common/types.py)- added gen_restful function bug fixeds (app/common/types.py)
- topic (classifiers) (pyproject.toml)
- added exceptions, fix param position, fix typing and indent (app/core/register.py)
gen_random_number
(app/utils/commons.py )- docs on utils
security
and date_utils - B026 issue (ruff) on include_router
- relative paths, move commands
- fix types, and docs
- in progress fix packages, updated req file (pyproject.toml)
- modules to doc, fix reference (mkdocs)
- home module route (now using version) (app/modules/home/views/home_view.py)
- indent
Removed
- unused prints and logs
- old code, fix indent, validations and more
- APP_VERSION from
app/config/app_settings
- fix response on home
-
tests
folder from black - test for / and /api/home remove "/api" from base_url
- (at time) some code (sqlalchemy/sessions/)
2023.10.03
notice: prepare to next big release
Added
- big upgrade on docs nav
- configuration for test (using pytest and httpx)
- referece for Callisto's source code
- too much documentation added and/or updated
- added media_type to ORJSONResponse
- update docs to 2023-07-18
- changes to 2023.03.26
- changes to 2022.12.07
- [in progress] and after a long, long time... the list of changes...
- many references, docs faq, more fancy docs
- new folder for test
- logo and favicon, thanks to https://icons8.com/icon/61304/european-dragon
- mkdocs main config
- plugins to mkdocs
- added script to make docs
- install dependencies with poetry, fix port, fix use env (tools/gen_pages.py)
- polyline method
- filter to get_all, fix get_by
- options for pytest (ini_options)
pytest = "^7.4.0"
httpx = "^0.24.1"
- new functions:
add_secret_version
and remove_secret - method
multi_save
flatten_list
Changed
- the requirements-dev.txt file is updated, this file is kept for compatibility and during the transition, it will be removed in future versions.
- now a warning is given if launched from a script (main.py)
- added examples and some warnings
- documentation style a bit more Google Docstring and Mkdocs compliant
- rename
validate_access_token
to validate_bearer_token (middlewares/auth.py) - omit "qa" for geospatial modules files
ApiBaseException
move from common exceptions- rename method
mongo_id
to generate_mongo_id - move
STDR_UTC_HOUR
toapp.config.app_settings
- update docs
Fixed
- better request logs
before request
andafter request
(main.py) - griffe warnings (mkdocs) now 'watch' using outisde plugins
- B026 issue (ruff)
- better indent and typing
- order some exceptions, added more exceptions, return dict in
Exception
(http/http_exceptions.py) - set
time_out
to 60 seconds,retries
to 3 (http/base_api.py) customEncoder
renamed to 'custom_encoder', 'try/except' addedget_timestamp
class decorator removedgenerate_id
return None in case of error- in process docstrings correction bugs
- docs on README.md
- internal error codes
cancel_job
, validate location- docs on 'app.common module'
- DeleteMode (MongoModel)
- rename some task, skip y some files
- imports, editor config, exclude tests from docker
- group tests using pytest
- depends and scripts for docs
- more docs
as_dict save, get_by_id, get_by
- responses and messages
- status on created
Removed
if __name__ == "__main__"...
will no longer be used to start the backendFlake8
is removed in favor ofRuff
- unused logs
- 'READY' mark added 'TO FIX' remove in some methods
- unused files
- messages on error, remove unused fields
- returns none if the record was removed, otherwise, a message with error info
- tag inside encrypted data (
encrypt_message
) - unused example on crud
- unused modules, fix doc, added
2023.07.18
Added
- some marks (TO FIX/TO CHECK) in some methods
setuptools = "^68.0.0"
- added
except HTTPException
(http/response.py) - docs dependencies groups (pyproject.toml)
Changed
- change to logger.exception in some methods
- rename HEADER_API_KEY to 'AUTH_HEADER' (middlewares/auth.py)
- messages (http/status.py)
- in methods/functions docs (mongoDB/connect.py and mongo_model.py)
Fixed
- added
None
to response json (http/response.py) - 'async' keyword to some functions/methods
Removed
check_session_role
(mongoDB/sessions/session_handler.py)- many unused imports
- many unused examples
- many unused prints and logs
2023.06.14
Added
- added module for OTP code TOTP/HOTP
- added base_model file
- get_timestamp, added new functions
- module for cache using pymemcache
- module for cache using diskcache
- method 'form_data' to send form-data fields
- functions get_secret_info, create_secret and list_secrets
- module for BigQuery Jobs
- config file
- [progress] for Google Cloud BigQuery
- twilio sms module
- function object_to_xml
- class ApiBaseException, This class implements methods for custom error handling, of urllib3
- class GraphApi to handle GraphQL request
- class XMLApi for XML request and responses (like soap)
- method 'basic_auth' added more docs (web refs)
- methods _get_base_uri, and set_headers fix param (now is 'url')
- added BQ_PROJECT_ID env var
- Api module for handle urllib3 request
- template for baseModel(Pydantic)
- method mongo_id, fix generate_uuid
- method 'geo_within_polygon' to search in a polygon (and examples)
- methods geo_within_bbox and geo_within_sphere (and examples)
- [in progress] radial_query from_geopoint and create_index method (and examples)
- method 'customEncoder' to handle validations over orjson
- method get_all_collections to retrieve all colls from db
- method 'delete_table'
- methods 'get_schema' and 'to_geopoint' (some examples)
- custom example using MongoModel and raw_query (roles)
- method 'raw_query', allow raw queries on custom collection
- 'view' from APIRouter (roles example)
- module roles(examples)
- added SIM rules (flake8-simplify)
- added more rules to ruff, thanks to jerry-git
- added ruff (and their rules), ruff exec script, some descriptions
Changed
- better error response on validation_exception_handler
- support to mongo restful and api_router
- added mongo api_router folder for advanced crud request
- rename to mongo restful folder
- added cache libraries
- dded TODO to encrypt_message and decrypt_message functions
- validate conn param and raise RuntimeError [to revision] comment typechecked on 'tablename' prop (MongoModel)
- move license info to COPYING, LGPL.txt and README.md files
- from_geopoint accept 'as_list' param to convert results
- rename from 'radial_query' to 'geo_nearest_query'
- change old imports, names, now using view vars, (tools/templates/mongo/view_.tpl)
- move ruff config to other file
- validate errors check using '@typechecked'
- test get_by and get_by_id
- validate params on get_all, get_prefix, tablename(property)
- get_by method, now using dict on filter param
- rename, 'delete' to 'remove', 'raw_query' to 'custom_query'
- better docs
- refactor code
Fixed
- the result type of 'collection.insert_one' is changed due to the '_id' field being auto generated
- base64 method added url info
- crud locales and roles examples
- and added missing docs - rename bad file name in app.contrib - rename project name
- docs common.exceptions' fix timeout
- build_response fix timeout on get
- paths and names (tools/templates/mongo/urls.tpl)
- isinstance on Cursor
- black 'required-version'
- docs on to_geopoint
- get_by method, now using dict on filter param, and reorganize params
- build_response, get_by_id and get_by methods (change params order)
- task for isort
- token length(middlewares/auth.py)
- format and lint using (ruff's attack)
Removed
- remove unused imports, remove result in delete_table
- 'roles_view' remove old examples
2023.03.26
Added
- cryptography module and others (started)
- method as_dict
- init_databases, stop_databases, startup_event and shutdown_event
- mongoDB_get_connect and mongoDB_close
- implements DefaultTraceback
- define default endpoint
- function 'is_iterable'
- DefaultException class
- twilio, otp, security (started)
- enums
- new messages for permissions
- HasRoles, HasPerms, check_session_role as Depends (DI)
- locales modules (examples)
- docker support
- poetry-exec-plugin
Changed
- rework mongoDB_connect
- now ValidateSchema is a Depends(DI)
- gcp logger, now is cloud_logging (gcp)
- upgrade Poetry to 1.4.x
- update fastapi, black, pydantic, starlette, uvicorn now using dev groups now using extras (optional) groups
- Script entry is replaced by poetry-exec-plugin
- added check to TODO list (README)
Fixed
- DefaultStatus, DefaultRoles
- E402 errors and other more from flake8
- fix license year
- build_response
- many docs
Removed
- hardcoded connection, now using _init
- classmethod decorator (mongoDB/mongo_model.py)
2022.12.07
Added
- Home example using fastapi_restful
- get_uuid function
- method save_and_set
- generate_id method, added exclude_fields to raw_query method
Changed
- validate _min_properties in ExtrictBaseModel
Fixed
- fix '_id' field, now is validated if the user, send custom id
2022.11.30
Added
- typeguard for strict type check
- some methods for MongoDB Model
- added get_timestamp function
- common types
- SQLAlchemy check_session_role
- many HTTP status
- flake8 config
- questionary
- validate_schema decorator, using draft 2020-12
- middleware require_auth_session
- AuthRoles
- config for mongo cluster
- loguru, jsonschema, mypy and extras
- commons definitions for data bases and sessions for Firestore
- MongoDB database Model
- GCPLoggingHandler and init_gcp_logger
- added response function, to generate json response(ORJSONResponse)
- main configuration file
- BaseEnum
- AuthStatus
- SessionStatus
- DefaultStatus
- ResourceModel
- on_event
- exception_handler
- Poetry config file
Fixed
- fix path, rename or move some modules
2022.11.16
Added
- license files, editor config files, git ignore files etc...