Django community: RSS
This page, updated regularly, aggregates Community blog posts from the Django community.
-
How to Customize Django Oscar Models, Views and URLs
In order to customize models, views and urls, you need to fork an Oscar core app in which model/view resides. Then you should be able to override any model/view classes.Steps to fork/customize an app: -
Python Memcached Implementation for Django Project
Memcache is a memory caching system that helps web applications and mobile app backends to improve performance and scalability. We should consider using Memcache when your pages are loading too slowly or your app is having scalability issues. In This Blog Post, Let's see how to use Memcached for server-side application caching. -
CORS with Amazon S3 and CloudFront
We struggle to load fonts from CloudFront because of CORS.CORS - Cross Origin Resource Sharing is a security measure to block macious scripts or resources loading from foreign domain origins. This security will become hurdle when want to load resources from Amazon CloudFront this is often encountered when we want to load fonts from CloudFront. Here are simple yet detailed steps to enable CORS on CloudFront. -
Amazon AWS IAM Roles and Policies
When You want to Provide access to Amazon Web Services Console or if you're planning to provide REST API Keys to your Developers of a Third Party Person, Using Providing access to Root Account Console or API Keys is not advisable since they basically will have full level access. Instead, we can rely on IAM(Identity and Access Management). Require any support regarding AWS IAM Roles and Policies then contact development services to know more -
Generic, Functional Based and Class Based Views in Django REST Framework
Writing Different Types of Views in Django-Rest-Framework.Writing Different Types of Views in Django-Rest-Framework. Django-Rest-Framework(DRF) supports three different types of views. They are Function Based Views, Class Based Views / Generic Views, ViewSets -
Amazon SES - Handling Bounces and Complaints
Why do we go for Bounce and Complaint Handling while sending emails?In general while sending emails, we will prepare some recipient addresses as our mailing list, which is valid and our recipients want and expect our mail. But sometimes, some emails which are invalid will bounce, and if valid recipients do not want your mail, they may mark your email as spam in their email client. High bounce and complaint rates put your account at risk of being shut down. So in order to avoid such problem, we'll handle the bounces and complaints and will remove those emails for not sending any emails further. -
Python Coding Techniques and Programming Practices
Coding techniques and programming practices are one of the features of a professional programmer. While writing code to solve a problem programmer should make simple choices and have to use basic techniques. This is completely depends on the programmers skill and expertise and how wisely he make choices. -
Django Hosting on Amazon EC2 with Wordpress on Same Domain
Configuring the Wordpress as subdirectory can be tricky. In this tutorial, we will Setup a Django Website alongside a WordPress blog. Our Site Structure will beexample.com ------------> Django Websiteexample.com/blog -----------> wordpress -
Django Custom Template Tags And Filters
Django Template Tags are simple Python functions that accept a value, an optional argument, and return a value to be displayed on the page.First, In your application folder, create a "templatetags" directory at the same level as the models and views.You want this directory to be recognized as a Python package, so make sure you create an empty "__init__.py" file. Next, create the Python file that will hold your tags and name it something like app_tags.py. -
Introduction to Object Oriented Programming with Python 3
Introduction to Object Oriented Programming with Python -
Sending Emails Using Sendgrid on Heroku for a Django App
Integrate Sendgrid API to your Heroku app to deliver simplified emails like any notification emails, user signups etc. -
Python using Yield and Generators
Generators are memory efficient. They allow us to code with minimum intermediate arguments, less data structures. Generators are of two types, generator expressions and generator functions. Generators are helpful for reading large files, streaming. -
How to Implement Case Insensitive CSV DictReader in Python
In general use cases we upload the CSV files to the system to store huge amount of data by uploading single file. For example in e-commerce sites we just write thousands of products details in a CSV file and just upload it.In python we can read the data of a CSV file in 2 ways. One by using normal csv.reader and the other by using csv.DictReader. -
Set Up Travis CI For Django Project
Travis CI is a continuous integration service used to build and test applications hosted at GitHub. Here are simple steps to add CI to you django project. -
Integrate Twitter Social API into Django App
Integrating Twitter sign in (OAuth) in Django App, which includes1. Capturing username via Twitter Login2. Updating authenticated user current status on twitter(tweets). -
Create Excel File, Insert Image, Draw Bar Graphs in Excel Files in Python Using Xlsxwriter
Xlsxwriter is a python module through which we can write data to Excel 2007+ XLSX file format. In this blog post we learn to write data, insert images and draw graphs in the excel file. -
Get Count, Average, Min, Max Values from Model Field using Django Aggregate
To retrieve maximum, minimum or average values from group of rows we can use django Aggregation. For example to retrieve max price or avg price of product from catalogue. -
Building Documentation with Readthedocs
In this blog, I'm going to explain you how to write the Sphinx docs using reStructuredText to host in the Read the Docs.Installing Sphinx$ pip install SphinxAnd we have script called sphinx-quickstart in Sphinx that sets up a source directory and creates a default conf.py with the most useful configuration values from a few questions it asks you. Just run the following command-$ sphinx-quickstart -
Improving Page Speed Score in Google Page Score test- PART1
Google's Page Speed Insights measures the performance of a page for mobile devices and desktop devices. It fetches the url twice, once with a mobile user-agent, and once with a desktop-user agent.The Page Speed Score ranges from 0 to 100 points. A higher score is better and a score of 85 or above indicates that the page is performing well. -
Factory Boy - An Alternative for Fixtures
Factory Boy is a fixtures replacement tool. It allows you to use objects customized for the current test, while only declaring the test-specific fields. For testing the Django app, create a root directory named tests. Then create __init__.py, tests.py (to write your tests), factories.py (to write your model factories) in that directory. -
Extract Text with OCR for All Image Types in Python Using Pytesseract
Optical Character Recognition(OCR) is the process of electronically extracting text from images or any documents like PDF and reusing it in a variety of ways such as full text searches. In this blog, we will see, how to use 'Python-tesseract', an OCR tool for python. It will recognize and read the text present in images. It can read all image types - png, jpeg, gif, tiff, bmp etc. It’s widely used to process everything from scanned documents. -
Improving Page Speed Score in Google Page Score Test- PART2
In our previous blog post we got an idea of what are the things that Google's Page Speed Insights will take into count to give page score, now in the present blog post we'll get to know what are the techniques we can use to improve the page score. -
Getting Started with the IPython Notebook
IPython is a set of tools developed to make it easier for the programmers to work with Python and data. IPython provides extensions to the Python programming language that make working interactively convenient and efficient. IPython Notebook lets you write and execute code, analyze data in your web browser. -
Python Arrow to Show Human Friendly Time
Arrow is a python library and command-line tool to genrerate, manipulate dates, times, timestamps.use of arrow:With the use of arrow, we can also create, manipulate, format and convert dates, times, and timestamps, convert timezones, generates time spans, ranges, floors and ceilings with a less code. -
Configuring and Testing Load Balancer in AWS EC2
When You have an application that is serving Huge Customer Base, so will be your Traffic. Sometimes The Application stops responding. We can use load Balancer in cases like this which distribute the Traffic it receives between the multiple VPS running the same application. AWS Professional Services helps to scale your application as your business grows.