|This article has links to websites or programs not trusted by Scratch or hosted by Wikipedia. Remember to stay safe while using the internet, as we cannot guarantee the safety of other websites.|
|This article documents something which is not associated with Scratch, the Lifelong Kindergarten Group, the scratch website or the Massachusetts Institute of Technology.|
For more information, see Python on Wikipedia. Python is a programming language that is generally considered to be easy to learn. It was first released in 1991 by Guido van Rossum, named after the Monty Python comedy group. The language is commonly learnt after Scratch.
This page describes using Python with Scratch and various Scratch-related Python programs.
There are libraries that can help ease writing code that connects Python to Scratch.
|Warning:||The extension mechanisms for the different versions are quite different, and are not compatible.|
- scratchclient — Python3 module for connecting to the Scratch API, updating and viewing cloud variables, and more.
- scratchconnect — Python3 module for connecting to the Scratch API, view and updating cloud variables, and more.
- scratch2py — Python3 module for connecting to the Scratch API, view and updating cloud variables, and more.
- scratchlink — Python3 module for connecting to the Scratch API without requiring users to log in.
- scratchattach — Python3 module with an event listener, and many different features
- scratchcloud — Python3 module for viewing and editing cloud variables.
- blockext — for writing extensions that are compatible with both Scratch 2.0 and Snap!. Generates extension files automatically. Clean programming interface. Needs documentation.
- ScratchAPI — Open source Python library providing an interface for the Scratch APIs.
See the guide for setting up Remote Sensor Connections in Scratch 1.4.
- Scratra — Provides a clean interface for responding to broadcasts and sensor updates using decorators (based on scratch.py)
- scratch.py (forum page) by pquiza — provides code for communicating with Scratch
- Scratch Space by Magnie — a Mesh server
Projects that interact with Scratch using Python and remote sensor connections:
- scratch2web.py by TheSuccessor — allows usage of Scratch as a web server
Scratch-related software written in Python:
- M30W, previously Emerald — a text version of Scratch
Scratch-related libraries that can be used in Python code:
- Kurt — for reading/writing Scratch project files
- See also: Scratch 2.0
The Scratch 2.0 website used Python as its back-end, or server-side code, as do pages on the Scratch 3.0 website that have not yet been modernized to 3.0. This means that pages on the site (such as profile pages) are produced by Python code. Django, a Python library for creating large database-driven websites, is the main library used.
- Python on Wikipedia
- Official Python website