├── README.md ├── requirements.txt └── todo ├── .70617373776f72642e747874 ├── .gitignore ├── db.sqlite3 ├── manage.py ├── static ├── css │ └── custom.css └── images │ ├── 17580.jpg │ ├── bolebole.gif │ ├── dexter.png │ ├── source.gif │ ├── tasker.png │ ├── test.jpg │ └── wa.png ├── tasks ├── __init__.py ├── __pycache__ │ ├── __init__.cpython-38.pyc │ ├── admin.cpython-38.pyc │ ├── models.cpython-38.pyc │ ├── serializers.cpython-38.pyc │ ├── tests.cpython-38.pyc │ ├── urls.cpython-38.pyc │ └── views.cpython-38.pyc ├── admin.py ├── apps.py ├── migrations │ ├── 0001_initial.py │ ├── 0002_task_priority.py │ ├── 0003_task_complete.py │ ├── 0004_auto_20180506_0853.py │ ├── 0005_auto_20180506_0932.py │ ├── 0006_auto_20180506_0940.py │ ├── 0007_auto_20180506_0946.py │ ├── 0008_auto_20180507_0326.py │ ├── 0009_auto_20180507_0328.py │ ├── 0010_auto_20200816_1820.py │ ├── __init__.py │ └── __pycache__ │ │ ├── 0001_initial.cpython-38.pyc │ │ ├── 0002_task_priority.cpython-38.pyc │ │ ├── 0003_task_complete.cpython-38.pyc │ │ ├── 0004_auto_20180506_0853.cpython-38.pyc │ │ ├── 0005_auto_20180506_0932.cpython-38.pyc │ │ ├── 0006_auto_20180506_0940.cpython-38.pyc │ │ ├── 0007_auto_20180506_0946.cpython-38.pyc │ │ ├── 0008_auto_20180507_0326.cpython-38.pyc │ │ ├── 0009_auto_20180507_0328.cpython-38.pyc │ │ ├── 0010_auto_20200816_1820.cpython-38.pyc │ │ └── __init__.cpython-38.pyc ├── models.py ├── serializers.py ├── templates │ ├── base.html │ ├── homepage.html │ ├── tasks.html │ └── token.html ├── templatetags │ ├── __pycache__ │ │ └── tags.cpython-38.pyc │ └── tags.py ├── tests.py ├── urls.py └── views.py └── todo ├── __init__.py ├── __pycache__ ├── __init__.cpython-38.pyc ├── settings.cpython-38.pyc ├── urls.cpython-38.pyc └── wsgi.cpython-38.pyc ├── settings.py ├── urls.py └── wsgi.py /README.md: -------------------------------------------------------------------------------- 1 | # errBox 2 | 3 |
Step 1: Clone the repo
4 |Step 2: Run pip3 install -r requirements.txt
5 |STep 3: Run python3 manage.py makemigrations
6 |Step 4: Run python3 manage.py migrate
7 |Step 5: Test whether the API GET request is working. Run python3 manage.py test. Should get OK as a response
8 |Step 6: Run python3 manage.py runserver
9 |
10 |
Note: check solution.txt for missing dependencies/errors and ensure you're in the proper path to execute manage.py
-------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | # There might be a missing dependency ! 2 | pytz==2018.4 3 | -------------------------------------------------------------------------------- /todo/.70617373776f72642e747874: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/.70617373776f72642e747874 -------------------------------------------------------------------------------- /todo/.gitignore: -------------------------------------------------------------------------------- 1 | venv 2 | -------------------------------------------------------------------------------- /todo/db.sqlite3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/db.sqlite3 -------------------------------------------------------------------------------- /todo/manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | import os 3 | import sys 4 | 5 | if __name__ == "__main__": 6 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "todo.settings") 7 | try: 8 | from django.core.management import execute_from_command_line 9 | except ImportError as exc: 10 | raise ImportError( 11 | "Couldn't import Django. Are you sure it's installed and " 12 | "available on your PYTHONPATH environment variable? Did you " 13 | "forget to activate a virtual environment?" 14 | ) from exc 15 | execute_from_command_line(sys.argv) 16 | -------------------------------------------------------------------------------- /todo/static/css/custom.css: -------------------------------------------------------------------------------- 1 | .adanger{ 2 | color: #dc3545; /* red */ 3 | } 4 | 5 | .bwarning{ 6 | color: #ffc107; /* orange */ 7 | } 8 | 9 | .csuccess{ 10 | color: #28a745; /* green */ 11 | } 12 | 13 | .dprimary{ 14 | color: #007bff; /* blue */ 15 | } 16 | 17 | .adanger:hover{ 18 | color: #dc3545; /* red */ 19 | } 20 | 21 | .bwarning:hover{ 22 | color: #ffc107; /* orange */ 23 | } 24 | 25 | .csuccess:hover{ 26 | color: #28a745; /* green */ 27 | } 28 | 29 | .dprimary:hover{ 30 | color: #007bff; /* blue */ 31 | } 32 | -------------------------------------------------------------------------------- /todo/static/images/17580.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/static/images/17580.jpg -------------------------------------------------------------------------------- /todo/static/images/bolebole.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/static/images/bolebole.gif -------------------------------------------------------------------------------- /todo/static/images/dexter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/static/images/dexter.png -------------------------------------------------------------------------------- /todo/static/images/source.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/static/images/source.gif -------------------------------------------------------------------------------- /todo/static/images/tasker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/static/images/tasker.png -------------------------------------------------------------------------------- /todo/static/images/test.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/static/images/test.jpg -------------------------------------------------------------------------------- /todo/static/images/wa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/static/images/wa.png -------------------------------------------------------------------------------- /todo/tasks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__init__.py -------------------------------------------------------------------------------- /todo/tasks/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/__pycache__/admin.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__pycache__/admin.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/__pycache__/models.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__pycache__/models.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/__pycache__/serializers.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__pycache__/serializers.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/__pycache__/tests.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__pycache__/tests.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/__pycache__/urls.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__pycache__/urls.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/__pycache__/views.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/__pycache__/views.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | from .models import Songs 3 | 4 | admin.site.register(Songs) 5 | -------------------------------------------------------------------------------- /todo/tasks/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class TasksConfig(AppConfig): 5 | name = 'tasks' 6 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0001_initial.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-03 09:49 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | initial = True 9 | 10 | dependencies = [ 11 | ] 12 | 13 | operations = [ 14 | migrations.CreateModel( 15 | name='Task', 16 | fields=[ 17 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 18 | ('title', models.CharField(max_length=200)), 19 | ('description', models.CharField(blank=True, max_length=1000)), 20 | ('date_of_creation', models.DateTimeField(auto_now_add=True)), 21 | ], 22 | ), 23 | ] 24 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0002_task_priority.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-04 10:14 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0001_initial'), 10 | ] 11 | 12 | operations = [ 13 | migrations.AddField( 14 | model_name='task', 15 | name='priority', 16 | field=models.CharField(choices=[('danger', 'Priority 1'), ('warning', 'Priority 2'), ('success', 'Priority 3'), ('primary', 'Priority 4')], default='danger', max_length=30), 17 | ), 18 | ] 19 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0003_task_complete.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.4 on 2018-05-05 04:06 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0002_task_priority'), 10 | ] 11 | 12 | operations = [ 13 | migrations.AddField( 14 | model_name='task', 15 | name='complete', 16 | field=models.IntegerField(default=0), 17 | ), 18 | ] 19 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0004_auto_20180506_0853.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-06 08:53 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0003_task_complete'), 10 | ] 11 | 12 | operations = [ 13 | migrations.CreateModel( 14 | name='Username', 15 | fields=[ 16 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 17 | ('username', models.CharField(max_length=50)), 18 | ], 19 | ), 20 | migrations.AlterField( 21 | model_name='task', 22 | name='priority', 23 | field=models.CharField(choices=[('adanger', 'Priority 1'), ('bwarning', 'Priority 2'), ('csuccess', 'Priority 3'), ('dprimary', 'Priority 4')], default='adanger', max_length=30), 24 | ), 25 | ] 26 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0005_auto_20180506_0932.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-06 09:32 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0004_auto_20180506_0853'), 10 | ] 11 | 12 | operations = [ 13 | migrations.DeleteModel( 14 | name='Username', 15 | ), 16 | migrations.AddField( 17 | model_name='task', 18 | name='username', 19 | field=models.CharField(default='omkar', max_length=50, unique=True), 20 | preserve_default=False, 21 | ), 22 | ] 23 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0006_auto_20180506_0940.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-06 09:40 2 | 3 | from django.db import migrations, models 4 | import django.db.models.deletion 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('tasks', '0005_auto_20180506_0932'), 11 | ] 12 | 13 | operations = [ 14 | migrations.CreateModel( 15 | name='Username', 16 | fields=[ 17 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 18 | ('username', models.CharField(max_length=50, unique=True)), 19 | ], 20 | ), 21 | migrations.AlterField( 22 | model_name='task', 23 | name='username', 24 | field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='tasks.Username'), 25 | ), 26 | ] 27 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0007_auto_20180506_0946.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-06 09:46 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0006_auto_20180506_0940'), 10 | ] 11 | 12 | operations = [ 13 | migrations.AlterField( 14 | model_name='task', 15 | name='id', 16 | field=models.AutoField(primary_key=True, serialize=False), 17 | ), 18 | ] 19 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0008_auto_20180507_0326.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-07 03:26 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0007_auto_20180506_0946'), 10 | ] 11 | 12 | operations = [ 13 | migrations.AlterField( 14 | model_name='task', 15 | name='priority', 16 | field=models.CharField(choices=[('adanger', 'Priority 1'), ('bwarning', 'Priority 2'), ('csuccess', 'Priority 3'), ('dprimary', 'Priority 4')], default='Select Priority', max_length=30), 17 | ), 18 | ] 19 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0009_auto_20180507_0328.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.0.5 on 2018-05-07 03:28 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0008_auto_20180507_0326'), 10 | ] 11 | 12 | operations = [ 13 | migrations.AlterField( 14 | model_name='task', 15 | name='priority', 16 | field=models.CharField(choices=[('adanger', 'Priority High'), ('bwarning', 'Priority Medium'), ('csuccess', 'Priority Low')], default='adanger', max_length=30), 17 | ), 18 | ] 19 | -------------------------------------------------------------------------------- /todo/tasks/migrations/0010_auto_20200816_1820.py: -------------------------------------------------------------------------------- 1 | # Generated by Django 2.2 on 2020-08-16 18:20 2 | 3 | from django.db import migrations, models 4 | 5 | 6 | class Migration(migrations.Migration): 7 | 8 | dependencies = [ 9 | ('tasks', '0009_auto_20180507_0328'), 10 | ] 11 | 12 | operations = [ 13 | migrations.CreateModel( 14 | name='Songs', 15 | fields=[ 16 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), 17 | ('title', models.CharField(max_length=255)), 18 | ('artist', models.CharField(max_length=255)), 19 | ], 20 | ), 21 | migrations.DeleteModel( 22 | name='Task', 23 | ), 24 | migrations.DeleteModel( 25 | name='Username', 26 | ), 27 | ] 28 | -------------------------------------------------------------------------------- /todo/tasks/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__init__.py -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0002_task_priority.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0002_task_priority.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0003_task_complete.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0003_task_complete.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0004_auto_20180506_0853.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0004_auto_20180506_0853.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0005_auto_20180506_0932.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0005_auto_20180506_0932.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0006_auto_20180506_0940.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0006_auto_20180506_0940.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0007_auto_20180506_0946.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0007_auto_20180506_0946.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0008_auto_20180507_0326.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0008_auto_20180507_0326.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0009_auto_20180507_0328.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0009_auto_20180507_0328.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/0010_auto_20200816_1820.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/0010_auto_20200816_1820.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSevagen/errBox/47866a929f83da8409345b9ee9f7892760546ee0/todo/tasks/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /todo/tasks/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | from django.forms import ModelForm 3 | from django import forms 4 | 5 | class Songs(models.Model): 6 | # song title 7 | title = models.charField(max_length=255, null=False) 8 | # name of artist or group/band 9 | artist = models.charField(max_length=255, null=False) 10 | 11 | def __str__(self): 12 | return "{} - {}".format(self.title, self.artist) 13 | -------------------------------------------------------------------------------- /todo/tasks/serializers.py: -------------------------------------------------------------------------------- 1 | from rest_framework import serializers 2 | from .models import Songs 3 | 4 | 5 | class SongsSerializer(serializers.ModelSerializer): 6 | class Meta: 7 | model = Songs 8 | fields = ("title") -------------------------------------------------------------------------------- /todo/tasks/templates/base.html: -------------------------------------------------------------------------------- 1 | 2 | {% load static %} 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |Congratulation ! You were able to solve the issues in this game. Hope you were able to improve your googling skills while doing so !
17 | 18 | 19 | Click here to get token ! 20 | 21 |Congratulation ! You were able to solve the issues in this game and generate random text. Hope you were able to improve your googling skills while doing so !
18 | 19 | 20 | Click here to get token ! 21 | 22 |Password is {{password}}
16 |