Skip to content

Commit 0a376cc

Browse files
authored
Merge pull request #203 from benavlabs/discord-link-fix
Fixed the discord link
2 parents 7c58913 + cd39c56 commit 0a376cc

File tree

2 files changed

+33
-33
lines changed

2 files changed

+33
-33
lines changed

README.md

Lines changed: 31 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@
4545
🧠 **DeepWiki Docs: [deepwiki.com/benavlabs/FastAPI-boilerplate](https://deepwiki.com/benavlabs/FastAPI-boilerplate)**
4646

4747
> **⚠️ Documentation Status**
48-
>
49-
> This is our first version of the documentation. While functional, we acknowledge it's rough around the edges - there's a huge amount to document and we needed to start somewhere! We built this foundation (with a lot of AI assistance) so we can improve upon it.
50-
>
48+
>
49+
> This is our first version of the documentation. While functional, we acknowledge it's rough around the edges - there's a huge amount to document and we needed to start somewhere! We built this foundation (with a lot of AI assistance) so we can improve upon it.
50+
>
5151
> Better documentation, examples, and guides are actively being developed. Contributions and feedback are greatly appreciated!
5252
5353
This README provides a quick reference for LLMs and developers, but the full documentation contains detailed guides, examples, and best practices.
@@ -75,11 +75,11 @@ This README provides a quick reference for LLMs and developers, but the full doc
7575

7676
## 🚀 Join Our Community
7777

78-
💬 **[Join our Discord community](https://discord.gg/jhhbkxBmhj)** - Connect with other developers using the FastAPI boilerplate!
78+
💬 **[Join our Discord community](https://discord.com/invite/TEmPs22gqB)** - Connect with other developers using the FastAPI boilerplate!
7979

8080
Our Discord server features:
8181
- **🤝 Networking** - Connect with fellow developers and share experiences
82-
- **💡 Product Updates** - Stay updated with FastroAI and our other products
82+
- **💡 Product Updates** - Stay updated with FastroAI and our other products
8383
- **📸 Showcase** - Share what you've built using our tools
8484
- **🗒️ Blog** - Latest blog posts and technical insights
8585
- **💬 General Discussion** - Open space for questions and discussions
@@ -290,7 +290,7 @@ CRUD_ADMIN_REDIS_SSL=false # default=false, use SSL for Redis co
290290

291291
**Session Backend Options:**
292292
- **Memory** (default): Development-friendly, sessions reset on restart
293-
- **Redis** (production): High performance, scalable, persistent sessions
293+
- **Redis** (production): High performance, scalable, persistent sessions
294294
- **Database**: Audit-friendly with admin visibility
295295
- **Hybrid**: Redis performance + database audit trail
296296

@@ -1058,21 +1058,21 @@ router = APIRouter(tags=["entities"])
10581058

10591059
@router.get("/entities/{id}", response_model=EntityRead)
10601060
async def read_entity(
1061-
request: Request,
1062-
id: int,
1061+
request: Request,
1062+
id: int,
10631063
db: Annotated[AsyncSession, Depends(async_get_db)]
10641064
):
10651065
entity = await crud_entity.get(db=db, id=id)
1066-
1066+
10671067
if entity is None: # Explicit None check
10681068
raise NotFoundException("Entity not found")
1069-
1069+
10701070
return entity
10711071

10721072

10731073
@router.get("/entities", response_model=List[EntityRead])
10741074
async def read_entities(
1075-
request: Request,
1075+
request: Request,
10761076
db: Annotated[AsyncSession, Depends(async_get_db)]
10771077
):
10781078
entities = await crud_entity.get_multi(db=db, is_deleted=False)
@@ -1150,9 +1150,9 @@ from app.schemas.entity import EntityRead
11501150

11511151
@router.get("/entities", response_model=PaginatedListResponse[EntityRead])
11521152
async def read_entities(
1153-
request: Request,
1154-
db: Annotated[AsyncSession, Depends(async_get_db)],
1155-
page: int = 1,
1153+
request: Request,
1154+
db: Annotated[AsyncSession, Depends(async_get_db)],
1155+
page: int = 1,
11561156
items_per_page: int = 10
11571157
):
11581158
entities_data = await crud_entity.get_multi(
@@ -1189,31 +1189,31 @@ async def create_entity(
11891189
# Check if entity already exists
11901190
if await crud_entity.exists(db=db, name=entity_data.name) is True:
11911191
raise DuplicateValueException("Entity with this name already exists")
1192-
1192+
11931193
# Check user permissions
11941194
if current_user.is_active is False: # Explicit boolean check
11951195
raise ForbiddenException("User account is disabled")
1196-
1196+
11971197
# Create the entity
11981198
entity = await crud_entity.create(db=db, object=entity_data)
1199-
1199+
12001200
if entity is None: # Explicit None check
12011201
raise CustomException("Failed to create entity")
1202-
1202+
12031203
return entity
12041204

12051205

12061206
@router.get("/entities/{id}", response_model=EntityRead)
12071207
async def read_entity(
1208-
request: Request,
1209-
id: int,
1208+
request: Request,
1209+
id: int,
12101210
db: Annotated[AsyncSession, Depends(async_get_db)]
12111211
):
12121212
entity = await crud_entity.get(db=db, id=id)
1213-
1213+
12141214
if entity is None: # Explicit None check
12151215
raise NotFoundException("Entity not found")
1216-
1216+
12171217
return entity
12181218
```
12191219

@@ -1711,7 +1711,7 @@ from your_app.schemas import YourCreateSchema, YourUpdateSchema
17111711

17121712
def register_admin_views(admin: CRUDAdmin) -> None:
17131713
# ... existing models ...
1714-
1714+
17151715
admin.add_view(
17161716
model=YourModel,
17171717
create_schema=YourCreateSchema,
@@ -2115,7 +2115,7 @@ touch tests/test_items.py
21152115
Follow the structure in `tests/test_user.py` for examples. Our tests use:
21162116

21172117
- **pytest** with **pytest-asyncio** for async support
2118-
- **unittest.mock** for mocking dependencies
2118+
- **unittest.mock** for mocking dependencies
21192119
- **AsyncMock** for async function mocking
21202120
- **Faker** for generating test data
21212121

@@ -2133,9 +2133,9 @@ class TestWriteUser:
21332133
with patch("src.app.api.v1.users.crud_users") as mock_crud:
21342134
mock_crud.exists = AsyncMock(return_value=False)
21352135
mock_crud.create = AsyncMock(return_value=Mock(id=1))
2136-
2136+
21372137
result = await write_user(Mock(), sample_user_data, mock_db)
2138-
2138+
21392139
assert result.id == 1
21402140
mock_crud.create.assert_called_once()
21412141
```
@@ -2186,15 +2186,15 @@ filterwarnings = [
21862186
### 7.4 Test Structure
21872187

21882188
- **Unit Tests** (`test_*_unit.py`): Fast, isolated tests with mocked dependencies
2189-
- **Fixtures** (`conftest.py`): Shared test fixtures and mock setups
2189+
- **Fixtures** (`conftest.py`): Shared test fixtures and mock setups
21902190
- **Helpers** (`tests/helpers/`): Utilities for generating test data and mocks
21912191

21922192
### 7.5 Benefits of Our Approach
21932193

2194-
✅ **Fast**: Tests run in ~0.04 seconds
2195-
✅ **Reliable**: No external dependencies required
2196-
✅ **Isolated**: Each test focuses on one piece of functionality
2197-
✅ **Maintainable**: Easy to understand and modify
2194+
✅ **Fast**: Tests run in ~0.04 seconds
2195+
✅ **Reliable**: No external dependencies required
2196+
✅ **Isolated**: Each test focuses on one piece of functionality
2197+
✅ **Maintainable**: Easy to understand and modify
21982198
✅ **CI/CD Ready**: Run anywhere without infrastructure setup
21992199

22002200
## 8. Contributing

docs/community.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Join our vibrant Discord community to connect with other developers, get help, s
44

55
## 🚀 Discord Server
66

7-
**[Join our Discord community](https://discord.gg/jhhbkxBmhj)**
7+
**[Join our Discord community](https://discord.com/invite/TEmPs22gqB)**
88

99
Welcome to the **Benav Labs** community! Our Discord server is the central hub where developers using our FastAPI boilerplate and other products can connect, collaborate, and grow together.
1010

@@ -86,7 +86,7 @@ We actively encourage feedback and suggestions! The community provides multiple
8686

8787
## 🔗 Quick Links
8888

89-
- **Discord Server:** [discord.gg/jhhbkxBmhj](https://discord.gg/jhhbkxBmhj)
89+
- **Discord Server:** [discord.gg/TEmPs22gqB](https://discord.com/invite/TEmPs22gqB)
9090
- **FastroAI:** [benav.io/fastroai](https://benav.io/fastroai)
9191
- **Blog:** [fastro.ai/blog](https://fastro.ai/blog)
9292
- **Benav Labs:** [benav.io](https://benav.io)

0 commit comments

Comments
 (0)