{"id":14972719,"url":"https://github.com/tough-dev-school/education-backend","last_synced_at":"2025-04-08T08:16:51.918Z","repository":{"id":37002920,"uuid":"217901987","full_name":"tough-dev-school/education-backend","owner":"tough-dev-school","description":"Django-based backend for our learning management system","archived":false,"fork":false,"pushed_at":"2024-10-29T12:47:00.000Z","size":4940,"stargazers_count":367,"open_issues_count":16,"forks_count":65,"subscribers_count":8,"default_branch":"master","last_synced_at":"2024-10-29T13:09:48.814Z","etag":null,"topics":["django","django-application","django-rest-framework","python","real-world"],"latest_commit_sha":null,"homepage":"https://tough-dev.school","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tough-dev-school.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-10-27T19:01:23.000Z","updated_at":"2024-10-29T11:09:28.000Z","dependencies_parsed_at":"2023-11-19T20:33:11.565Z","dependency_job_id":"f2f5d622-85c7-4a86-b40b-e804200d22d9","html_url":"https://github.com/tough-dev-school/education-backend","commit_stats":{"total_commits":2343,"total_committers":23,"mean_commits":101.8695652173913,"dds":0.3905249679897568,"last_synced_commit":"7ed4fc06668248a234b1729b529c6d2a527f0297"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tough-dev-school%2Feducation-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tough-dev-school%2Feducation-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tough-dev-school%2Feducation-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tough-dev-school%2Feducation-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tough-dev-school","download_url":"https://codeload.github.com/tough-dev-school/education-backend/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247801175,"owners_count":20998339,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["django","django-application","django-rest-framework","python","real-world"],"created_at":"2024-09-24T13:47:25.435Z","updated_at":"2025-04-08T08:16:51.892Z","avatar_url":"https://github.com/tough-dev-school.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Backend for [tough-dev.school](https://tough-dev.school/)\n\n![CI](https://github.com/tough-dev-school/education-backend/actions/workflows/ci.yml/badge.svg) [![Maintainability](https://api.codeclimate.com/v1/badges/fe9fb0b64052a426f355/maintainability)](https://codeclimate.com/github/f213/education-backend/maintainability) [![Test Coverage](https://api.codeclimate.com/v1/badges/fe9fb0b64052a426f355/test_coverage)](https://codeclimate.com/github/f213/education-backend/test_coverage)\n\nDjango-based production project, integrated with Tinkoff, Dashamail, Postmark, S3 and telegram. Frontend is built on vue.js in the [separate repo](https://github.com/tough-dev-school/lms-frontend-v2).\n\n## Configuration\n\nConfiguration is stored in `src/core/.env`, for examples see `src/core/.env.ci`\n\n## Installing on a local machine\n\nThis project requires python 3.11. Deps are managed by [Poetry](https://python-poetry.org/).\n\nInstall requirements:\n\n```bash\npoetry install --no-root\n```\n\nConfigure postgres and redis. It's convenient to use docker and docker-compose:\n\n```bash\ndocker compose up -d\n```\n\nIf you don't have access to de-anonymized db image use `postgres:13.6-alpine` in `docker-compose.yml` instead:\n\n```yaml\npostgres:\n    image: postgres:13.6-alpine\n    ...\n```\n\nRun the server:\n\n```bash\ncp src/core/.env.ci src/core/.env\n\npoetry run python src/manage.py migrate\npoetry run python src/manage.py createsuperuser\n\nmake server\n```\n\nTesting:\n\n```bash\n# run lint\nmake lint\n\n# run unit tests\nmake test\n```\n\n## Backend Code requirements\n\n### Style\n\n* Obey [django's style guide](https://docs.djangoproject.com/en/dev/internals/contributing/writing-code/coding-style).\n* Configure your IDE to use [flake8](https://pypi.python.org/pypi/flake8) for checking your python code. For running flake8 manualy, do `cd src \u0026\u0026 flake8`\n* Prefer English over your native language in comments and commit messages.\n* Commit messages should contain the unique id of issue they are linked to (refs #100500)\n* Every model and a model method should have a docstring.\n\n### Code organisation\n\n* KISS and DRY.\n* Obey [django best practices](http://django-best-practices.readthedocs.io/en/latest/index.html)\n* If you want to implement some business logic — make a service for that. Service examples: [UserCreator](https://github.com/tough-dev-school/education-backend/blob/master/src/users/services/user_creator.py#L22), [OrderCreator](https://github.com/tough-dev-school/education-backend/blob/master/src/orders/services/order_creator.py#L11)\n* **No logic is allowed within the views or templates**. Only services and models.\n* Use PEP-484 [type hints](https://www.python.org/dev/peps/pep-0484/) when possible.\n* Prefer [Manager](https://docs.djangoproject.com/en/1.10/topics/db/managers/) methods over static methods.\n* Do not use [signals](https://docs.djangoproject.com/en/1.10/topics/signals/) for business logic. Signals are good only for notification purposes.\n* No l10n is allowed in python code, use [django translation](https://docs.djangoproject.com/en/1.10/topics/i18n/translation/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftough-dev-school%2Feducation-backend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftough-dev-school%2Feducation-backend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftough-dev-school%2Feducation-backend/lists"}