updated package to conform to pylint
This commit is contained in:
parent
832196e77e
commit
03901e1d12
22 changed files with 10 additions and 9 deletions
3
backend/.gitignore
vendored
3
backend/.gitignore
vendored
|
@ -1,3 +1,4 @@
|
||||||
.venv/
|
.venv/
|
||||||
__pycache__/
|
__pycache__/
|
||||||
*.egg-info
|
*.egg-info
|
||||||
|
dist/
|
|
@ -7,8 +7,8 @@ from .routes import routes
|
||||||
from .routes.requests import routes_requests
|
from .routes.requests import routes_requests
|
||||||
from .config import ServerSettings
|
from .config import ServerSettings
|
||||||
|
|
||||||
instance = Application.get_instance()
|
APP = Application.get_instance()
|
||||||
app, api = instance.app, instance.api
|
app, api = APP.app, APP.api
|
||||||
api.register_blueprint(routes)
|
api.register_blueprint(routes)
|
||||||
api.register_blueprint(routes_requests)
|
api.register_blueprint(routes_requests)
|
||||||
|
|
|
@ -10,7 +10,7 @@ class DatabaseSettings:
|
||||||
|
|
||||||
class APISettings:
|
class APISettings:
|
||||||
API_TITLE = "Support Organizer"
|
API_TITLE = "Support Organizer"
|
||||||
API_VERSION = "0.1.0-a"
|
API_VERSION = "0.1.0-a1"
|
||||||
OPENAPI_VERSION = "3.1.0"
|
OPENAPI_VERSION = "3.1.0"
|
||||||
|
|
||||||
# openapi.json settings
|
# openapi.json settings
|
0
backend/fgo_request_manager/models/__init__.py
Normal file
0
backend/fgo_request_manager/models/__init__.py
Normal file
|
@ -5,7 +5,7 @@ from ..app import Application
|
||||||
from ..models.interface import HealthGet, HealthStatus
|
from ..models.interface import HealthGet, HealthStatus
|
||||||
from . import routes as blp
|
from . import routes as blp
|
||||||
|
|
||||||
instance = Application.get_instance()
|
APP = Application.get_instance()
|
||||||
|
|
||||||
@blp.route("/health")
|
@blp.route("/health")
|
||||||
class ApiVersion(MethodView):
|
class ApiVersion(MethodView):
|
||||||
|
@ -13,8 +13,8 @@ class ApiVersion(MethodView):
|
||||||
@blp.response(200, HealthGet, description="Successful operation")
|
@blp.response(200, HealthGet, description="Successful operation")
|
||||||
def get(self):
|
def get(self):
|
||||||
response = {
|
response = {
|
||||||
"alive_since": datetime.strftime(instance.alive_since, "%d.%m.%Y %H:%M:%S"),
|
"alive_since": datetime.strftime(APP.alive_since, "%d.%m.%Y %H:%M:%S"),
|
||||||
"alive_for": str(datetime.now() - instance.alive_since),
|
"alive_for": str(datetime.now() - APP.alive_since),
|
||||||
"status": HealthStatus.OK
|
"status": HealthStatus.OK
|
||||||
}
|
}
|
||||||
return response
|
return response
|
|
@ -3,7 +3,7 @@ requires = ["setuptools >= 61.0"]
|
||||||
build-backend = "setuptools.build_meta"
|
build-backend = "setuptools.build_meta"
|
||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "fgo-request-manager"
|
name = "fgo_request_manager"
|
||||||
version = "0.1.0a1"
|
version = "0.1.0a1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"flask~=2.3.3",
|
"flask~=2.3.3",
|
||||||
|
@ -27,4 +27,4 @@ classifiers = [
|
||||||
|
|
||||||
[tool.setuptools.packages.find]
|
[tool.setuptools.packages.find]
|
||||||
where = ["."]
|
where = ["."]
|
||||||
include = ["fgo-request-manager*"]
|
include = ["fgo_request_manager*"]
|
||||||
|
|
Loading…
Reference in a new issue