earn the White PyBites Ninja earn the Yellow PyBites Ninja earn the Orange PyBites Ninja right arrow earn more PyBites Ninja belts and certificates
The best way to learn to code in Python is to actually use the language.

Our platform offers effective Test Driven Learning which will be key to your progress.


Join thousands of Pythonistas and start coding!


Join us on our PyBites Platform
Click here to code!

You can now hone your testing / pytest skills on our platform

Posted by Bob on Mon 18 November 2019 in Testing • Tagged with pytest, platform, feature, mutpy, mutation testing, fizzbuzz, fibonacci • 6 min read

Writing test code is an essential skill. As PyBites we believe writing code is the only solution to becoming a master (Ninja) at programming. The same applies to test code. For that reason we extended our regular exercises with Test Bites. In this article you will read about the feature showcasing it on our first ever Test Bite. We also share some details around implementation and a challenge we hit getting it to work. Enjoy and start honing your testing skills today!


Continue reading

PyCon ES 2019 Alicante Highlights

Posted by Bob on Wed 09 October 2019 in PyCon • Tagged with pycon, conference, learning, django, community, katas, marvel, coffee, rasa, chatbots, IoT, data artist, data visualization, pycamp, opensource, hacktoberfest, astronomy • 6 min read

Last weekend it was Pycon time again, my 6th one so far. This time closer to home: Alicante. I had an awesome time, meeting a lot of nice people, watching interesting talks and getting inspired overall to keep learning more Python. In this post I share 10 highlights, but keep in mind this is a selection only, there are quite a few more talks I want to check out once they appear on Youtube ...


Continue reading

How to Create and Serve Zipfiles from Django

Posted by Bob on Wed 08 May 2019 in Django • Tagged with Django, zipfile, snippets, archive, response, request, admin, DB, sqlite3, migrations, virtualenv • 6 min read

We added support to our platfom for bulk downloading of all your code submissions. This feature required creating and serving up zipfiles through Django. In this article I show you how to do it creating a simple Django app collecting code snippets through the admin interface, and serving them up in a zipfile via a download endpoint. Let's dive straight in ...


Continue reading

Building a Python Tips API with Django REST Framework and Deploying it to Digital Ocean

Posted by Bob on Tue 05 March 2019 in Django • Tagged with Django, APIs, Django REST Framework, tips, Digital Ocean, Django Commands, Postman, Nginx, postgres, Gunicorn, BeautifulSoup, requests, curl, SSH, Linux, deployment • 15 min read

In this article I will show you how to build a simple API for our growing collection of Python tips. First we make a simple Django app, defining the model. Next we use Django REST Framework to make an API supporting common CRUD operations. Then we will test it out using curl, Postman and Django REST's browser front-end. Lastly we deploy the API to Digital Ocean so we can start using it via our Slack with a Slash Command, which I will cover in the next article. Sounds exciting? You bet it is! Let's jump straight in!


Continue reading

Generating Beautiful Code Snippets with Carbon and Selenium

Posted by Bob on Tue 26 February 2019 in Tools • Tagged with Selenium, BeautifulSoup, requests, collections, random, urllib, carbon, tips, pprint, automation • 7 min read

Did you notice our Python tips lately? They looks more sexy, don't they? That's thanks to Carbon which lets you create beautiful images of your source code. As much as I love its interface though, what if we can automate this process generating the image for us? That's what we did and posting new tips to Twitter is now a breeze. In this article I will show you how using a bit of BeautifulSoup and selenium. Enjoy!


Continue reading

How to Parse Hidden HTML With Selenium Headless Mode and Deploy it to Heroku

Posted by Bob on Tue 19 February 2019 in Tools • Tagged with Selenium, headless, Heroku, tweepy, argparse, Slack, Packt, books, automation, parsing, BeautifulSoup, requests, namedtuple, Scheduler, git, buildpacks, environment variables • 6 min read

Ever wondered how you scrape hidden (or JS generated) HTML? Selenium is your friend. Ever wondered how to run it without a browser popping up? Use headless mode. How would you run it remotely? Use Heroku. And how about autoposting to Slack and Twitter? With the right libraries and API setup little code is needed. In this 10 step guide I will show you how to build a Packt Free Learning Notifier which will accomplish all these tasks. Ready to learn some nice automation skills in Python?


Continue reading

3 Cool Things You Can do With the dateutil Module

Posted by Bob on Fri 30 November 2018 in Modules • Tagged with dateutil, parse, relativedelta, rrule, fuzzy parser, datetime, timedelta, 100DaysOfCode • 3 min read

In this short article I will show you how to use dateutil's parse, relativedelta and rrule to make it easier to work with datetimes in Python.


Continue reading

How to Test Your Django App with Selenium and pytest

Posted by Bob on Thu 22 November 2018 in Testing • Tagged with django, pytest, selenium, platform, fixtures, dateutil • 8 min read

In this article I will show you how to test a Django app with pytest and Selenium. We will test our CodeChalleng.es platform comparing the logged out homepage vs the logged in dashboard. We will navigate the DOM matching elements and more. Overall you should learn enough Selenium and pytest to start testing a web page including a login. Sounds exciting? Let's dive straight in!


Continue reading

Automating PyBites Review Post Using Github API and collections.defaultdict

Posted by Bob on Tue 13 November 2018 in Data • Tagged with collections, defaultdict, re, regular expressions, requests, challenges, review post, parsing, string manipulation, github, API • 4 min read

In this post I share a quick script I produced last week to automate a portion of our review post. There are some nice idioms that you might find useful.


Continue reading

Career Development for Programmers

Posted by Bob on Sun 23 September 2018 in SoftSkills • Tagged with career, books, blogging, big data, practice, exercise, inspiration, coding, writing, productivity • 7 min read

What makes you excel in your career? Become an expert in x, y, z. Sure, you need to learn technical skills, quite a lot of them. However there is a lot more to it. If you want to succeed in your job, business and life, you want to build a portfolio, share your learning, become a reader and a good writer, and last but not least stick to daily exercising. I published this article on my blog 2 years ago and find a lot is still relevant today and will serve our community. I also added an updated towards the end.


Continue reading