This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.core.management.base import BaseCommand, CommandError | |
from apps.flower.models import Flower | |
from bs4 import BeautifulSoup | |
import requests | |
class Command(BaseCommand): | |
help = 'Takes information from webpage' | |
def handle(self, *args, **options): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Unhandled exception in thread started by <function wrapper at 0x7fb1e02931b8> | |
Traceback (most recent call last): | |
File "/home/alopex/Desktop/coding_dojo/week-6/env/local/lib/python2.7/site-packages/django/utils/autoreload.py", line 226, in wrapper | |
fn(*args, **kwargs) | |
File "/home/alopex/Desktop/coding_dojo/week-6/env/local/lib/python2.7/site-packages/django/core/management/commands/runserver.py", line 116, in inner_run | |
self.check(display_num_errors=True) | |
File "/home/alopex/Desktop/coding_dojo/week-6/env/local/lib/python2.7/site-packages/django/core/management/base.py", line 426, in check | |
include_deployment_checks=include_deployment_checks, | |
File "/home/alopex/Desktop/coding_dojo/week-6/env/local/lib/python2.7/site-packages/django/core/checks/registry.py", line 75, in run_checks | |
new_errors = check(app_configs=app_configs) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.conf.urls import include, url, patterns | |
from apps.dontwork.views import MyView | |
urlpatterns = patterns('', | |
url(r'^$', MyView.as_view()), | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.conf.urls import include, url, patterns | |
from django.contrib import admin | |
urlpatterns = patterns('', | |
url(r'^', include('apps.dontwork.urls')), | |
url(r'^admin/', include(admin.site.urls)), | |
) |