Full-featured ORM library for Golang with associations, hooks, transactions, migrations, and developer-friendly chainable API
Overall
score
81%
{
"context": "This criteria evaluates the engineer's proficiency in using GORM's delete operations, specifically soft delete and hard delete mechanisms. It focuses on proper usage of gorm.DeletedAt field type, the Delete() method, and the Unscoped() method for bypassing soft delete filtering.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Soft Delete Model",
"description": "Task model correctly includes gorm.DeletedAt field or embeds gorm.Model to enable soft delete functionality",
"max_score": 20
},
{
"name": "Delete Method Usage",
"description": "ArchiveTask function uses the Delete() method to perform soft delete on a task by ID",
"max_score": 15
},
{
"name": "Unscoped for Hard Delete",
"description": "PermanentlyDeleteTask function uses Unscoped().Delete() to permanently remove a task from the database",
"max_score": 20
},
{
"name": "Active Tasks Query",
"description": "ListActiveTasks function uses Find() or similar query method without Unscoped(), correctly excluding soft-deleted records",
"max_score": 10
},
{
"name": "Archived Tasks Query",
"description": "ListArchivedTasks function uses Unscoped().Where() with a condition checking DeletedAt IS NOT NULL to retrieve only soft-deleted records",
"max_score": 20
},
{
"name": "Bulk Delete Operation",
"description": "BulkArchiveCompletedTasks function uses Where() clause with completed condition followed by Delete() to archive multiple tasks",
"max_score": 15
}
]
}Install with Tessl CLI
npx tessl i tessl/golang-gorm-io--gormdocs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10