This is my django project hierarchy
project/ apache/ django.wsgi project/ __init__.py, settings.py, urls.py .. pages/ __init__.py widgets.py website_views.py services/ __init__.py apis/ __init__.py fparser.py googleData.py wp.py ... wservice.py ...
Thus, wservice.py is the final class that lies in all classes of the apis module. It even provides some common functionality to all classes that it inherits.
wservice.py
import feedparser from bs4 import BeautifulSoup class WidgetService(FParser): def post_content_summary(self, post_number): .... content_text = content_soup.get_text() ... def get_random_image(self, post_number): ... content_soup = BeautifulSoup(html_content) ...
Class
FParser is located in fparser.py
The methods in fparser.py use the above class this way.
from services.wservice import WidgetService def method1(): obj = WidgetService() m1 = obj.foo1()
I use this WidgetService () in pages/widgets.py . So, I found that when I start using BeautifulSoup , the Apache server does not load. It doesn't even show a syntax error.
I donβt even see errors in the log file.
What could possibly have gone wrong? The interesting part: I did not encounter such an error in the development server, heroic (gunicorn)
source share