Eduardo Zepeda's latests posts
Django channels: consumers, environments and events
- django
<p>Why Django channels? Because Django does not allow us to create applications with real-time communication natively. Django channels gives Django the ability to handle protocols that require a persistent connection, such as WebSockets, MQTT, chatbots, while keeping intact its i...
Read more
Python vs Go Which is the Best Programming Language in 2025?
- go
- python
<p>These last few months I have been learning go. How did it all start? Well, it started in a rather superficial way; I loved their mascot, yes, that's really what it was all about. So after a brief mental debate, I decided to give the language a try. My first impression of...
Read more
How To Create a Graphql API In Django Rapidly Using Graphene
- django
<p>In this post I will explain how Graphene allows you to speed up the process of creating a GraphQL API if you are using the Django Framework, as well as take advantage of the models you have already defined to perform queries or mutations.</p><p>Normally graphql is used in...
Read more
What Types to use for React components with children
- react
- typescript
- javascript
<p>If you're struggling about what types to use for React components that have children in Typescript, so you can inherit them correctly and avoid errors, then this is the post you need to read, I explain you three different approaches you can save and use as a part of your...
Read more
How to measure requests per second with locust in python?
- python
<p>There are quite simple to use tools that allow us to audit the number of requests per second (rps) that a website supports, locust is one of them, it is made with Python and with a minimal configuration allows us to process information and obtain graphs instantly, and in real ...
Read more
Facebook's plugin chat how to decrease its impact?
- javascript
<p>The facebook chat plugin allows you to add a page button that connects to the chat of a facebook fanpage. But, as you know, facebook is monopolistic and the default installation loads the plugin first, making your website slower and affecting the web vitals indicators of the p...
Read more
OCR with tesseract, python and pytesseract
- python
- artificial intelligence
<p>Python is super versatile, it has a giant community with libraries that allow you to create neural networks from scracth, <a class="markdown-link" href="https://coffeebytes.dev/en/artificial-intelligence/fine-tuning-a-llm-small-practical-guide-with-resources/">fine-t...
Read more
Python tortoise ORM integration with FastAPI
- fastapi
- databases
<p>One of the things I like most about Django is its ORM; <a class="markdown-link" href="https://coffeebytes.dev/en/django/why-should-you-use-django-framework/">one of the reasons why this framework is so popular</a>. On the other hand FastAPI does not have an ORM ...
Read more
The django admin panel and its customization
- django
<p>One of the best features of django is that it has the django admin panel, a ready-to-use administration panel, with basic functions such as create, read, edit and delete models, users, groups and permissions. All ready to use just by setting up your application. But sometimes ...
Read more
Caching in Django REST Framework using memcached
- django
<p>To use the cache in django, just follow three simple steps:</p><div class="google-ads-container-8672022193"> <ins class="adsbygoogle" style="display:block; text-align:center;" data-ad-layout="in-article" data-ad-format="f...
Read more
Django channels places an intermediate layer that is in charge of processing http requests to django views and websocket connections to an http consumer or a websocket consumer.
","datePublished":"Tue, 09 Nov 2021 00:00:00 +0000","dateModified":"Tue, 09 Nov 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/django/django-channels-consumers-environments-and-events/"}},{"@type":"BlogPosting","headline":"Python vs Go Which is the Best Programming Language in 2025?","description":"These last few months I have been learning go. How did it all start? Well, it started in a rather superficial way; I loved their mascot, yes, that’s really what it was all about. So after a brief mental debate, I decided to give the language a try. My first impression of it is that it is quite similar to Python; simple and easy to learn. Now that I have used it a bit more I bring you a comparison of go programming language vs python, where I will explain some of their differences, in case you are interested in learning one or the other this 2025.
","datePublished":"Tue, 02 Nov 2021 00:00:00 +0000","dateModified":"Tue, 02 Nov 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/go/python-vs-go-go-which-is-the-best-programming-language/"}},{"@type":"BlogPosting","headline":"How To Create a Graphql API In Django Rapidly Using Graphene","description":"In this post I will explain how Graphene allows you to speed up the process of creating a GraphQL API if you are using the Django Framework, as well as take advantage of the models you have already defined to perform queries or mutations.
Normally graphql is used in conjunction with Nodejs and express, or other javascript frameworks, to create a graphql API in which to make queries, but graphql can also be implemented with Python frameworks such as Django. We are going to create a django application that serves content with graphql using a cool library called graphene that abstracts almost all the boilerplate of integrating graphql with Django models.
","datePublished":"Tue, 26 Oct 2021 00:00:00 +0000","dateModified":"Tue, 26 Oct 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/django/how-to-create-a-graphql-api-in-django-rapidly-using-graphene/"}},{"@type":"BlogPosting","headline":"What Types to use for React components with children","description":"If you’re struggling about what types to use for React components that have children in Typescript, so you can inherit them correctly and avoid errors, then this is the post you need to read, I explain you three different approaches you can save and use as a part of your typescript skills.
Typescript requires that we specify the types for the different variables and function arguments in React. When they are native types it is not intrincate, but for React components it can be different. Here are 3 ways to specify types for React components that contain children as part of their props.
","datePublished":"Tue, 19 Oct 2021 00:00:00 +0000","dateModified":"Tue, 19 Oct 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/react/what-types-to-use-for-react-components-with-children/"}},{"@type":"BlogPosting","headline":"How to measure requests per second with locust in python?","description":"There are quite simple to use tools that allow us to audit the number of requests per second (rps) that a website supports, locust is one of them, it is made with Python and with a minimal configuration allows us to process information and obtain graphs instantly, and in real time, of the behavior of our website.
Install locust
The first step is to install it using pip or any virtual environment manager.
","datePublished":"Tue, 12 Oct 2021 00:00:00 +0000","dateModified":"Tue, 12 Oct 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/python/how-to-measure-requests-per-second-with-locust-in-python/"}},{"@type":"BlogPosting","headline":"Facebook's plugin chat how to decrease its impact?","description":"The facebook chat plugin allows you to add a page button that connects to the chat of a facebook fanpage. But, as you know, facebook is monopolistic and the default installation loads the plugin first, making your website slower and affecting the web vitals indicators of the pages. There are some ways to mitigate this.
The impact of the facebook chat plugin
Loading the facebook plugin triggers a long list of web requests that download about many MB of information and consumes valuable time that can impact your page load, watch.
","datePublished":"Tue, 05 Oct 2021 00:00:00 +0000","dateModified":"Tue, 05 Oct 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/javascript/facebooks-plugin-chat-how-to-decrease-its-impact/"}},{"@type":"BlogPosting","headline":"OCR with tesseract, python and pytesseract","description":"Python is super versatile, it has a giant community with libraries that allow you to create neural networks from scracth, fine-tune a LLM or use Optical Character Recognition (OCR). For the latter you just need to install tesseract and python bindings, known as pytesseract and you’ll be ready to convert an image to a string in a breeze.
Installation of tesseract-ocr
To perform OCR with Python we will need tesseract, which is the library that handles all the heavy lifting and image processing.
","datePublished":"Tue, 28 Sep 2021 00:00:00 +0000","dateModified":"Tue, 28 Sep 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/python/ocr-with-tesseract-python-and-pytesseract/"}},{"@type":"BlogPosting","headline":"Python tortoise ORM integration with FastAPI","description":"One of the things I like most about Django is its ORM; one of the reasons why this framework is so popular . On the other hand FastAPI does not have an ORM and focuses solely on serving endpoints, showing agnostic on the basis of data. There are enough options ORM to python: django-alchemy, peewee, ponyORM, tortoise. The latter, besides being asynchronous, is inspired by the django ORM, so its syntax is quite similar, even many tortoise functions share name with its Django counterpart, so users who use the Django ORM will save a lot of time learning tortoise functions.
","datePublished":"Tue, 21 Sep 2021 00:00:00 +0000","dateModified":"Tue, 21 Sep 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/fastapi/python-tortoise-orm-integration-with-fastapi/"}},{"@type":"BlogPosting","headline":"The django admin panel and its customization","description":"One of the best features of django is that it has the django admin panel, a ready-to-use administration panel, with basic functions such as create, read, edit and delete models, users, groups and permissions. All ready to use just by setting up your application. But sometimes our needs are different, what if we want to modify the appearance or functions of the interface? Fortunately Django includes many functions to customize the behavior of the admin, I will explain some of them below.
","datePublished":"Tue, 14 Sep 2021 00:00:00 +0000","dateModified":"Tue, 14 Sep 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/django/the-django-admin-panel-and-its-customization/"}},{"@type":"BlogPosting","headline":"Caching in Django REST Framework using memcached","description":"To use the cache in django, just follow three simple steps:
- Install a caching system, be it redis, memcached, etc.
- Set the CACHES variable to the settings.py file of the project.
- Add the middleware necessary for django to return the cache before processing the view.
- Use the low-level cache to cache specific views or data (optional).
Implementing a caching system allows you to greatly improve the performance of an application made in Django .
","datePublished":"Tue, 07 Sep 2021 00:00:00 +0000","dateModified":"Tue, 07 Sep 2021 00:00:00 +0000","author":{"@type":"Person","name":"Eduardo Zepeda"},"mainEntityOfPage":{"@type":"WebPage","@id":"https://coffeebytes.dev/en/django/caching-in-django-rest-framework-using-memcached/"}}]}