Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
This pip packages will help you to make your life easier when working with fastapi and ormar.
For installing this package:
pip install fastapi-helpers
If you need a default settings for your app, it includes an implementation BaseSettings of pydantic.
from fastapi_helpers import DefaultSettings
from utils import env_path
from typing import Optional
class Settings(DefaultSettings):
app_name = "your-app-name"
redis_url: Optional[str] = 'redis://localhost:6379'
version: Optional[str] = '1.0.0.0'
port: Optional[str] = "8000"
env: Optional[str] = "dev" #dev, test, prod
settings = Settings(env_path)
If you need a logger, it includes an implementation a colored console, and in prod envs it will log to aws with the help of watchtower.
from fastapi_helpers import DefaultLogger
from .config import settings
logger = DefaultLogger("your-app-name", settings)
If you need to connect to a db superfast, the only thing you need to do is to:
from fastapi_helpers import DbConfig
from core.config import settings
from core.logger import logger
db_config = DbConfig(settings, logger)
There are other tools for making the usage of ormar and fastapi even easier.
I would really like to make this tools bigger, but I´m looking for help for documenting this package.
Happy codding!
FAQs
An utils package for fastapi
We found that fastapi-helpers demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.