Python Library, Framework, Module | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Python Library, Framework, Module

What's the difference between these python terms: library, framework, module. I think I may be using them wrongly (interchangeably ).

25th Sep 2020, 10:40 AM
chou awara steven
chou awara steven - avatar
3 Answers
+ 1
FRAMEWORK-A framework is a collection of modules or packages which helps in writing web applications. While working on frameworks in python we don’t have to worry about the low level details such as protocols, sockets or thread management. LIBRARY-A Python library is a reusable chunk of code that you may want to include in your programs/ projects. MODULE-Modules in Python are simply Python files with a .py extension. The name of the module will be the name of the file. A Python module can have a set of functions, classes or variables defined and implemented.
26th Sep 2020, 8:20 AM
Nihar Buliya
Nihar Buliya - avatar
+ 1
A module in python is a .py file. A Python package refers to a directory of Python modules. A package would also contain a __init__.py file. A library is poorly defined for Python. I think people frequently say library in reference to both packages and modules. A framework in Python should have a lot of control over how you program. A framework could be a package but not all packages are frameworks. Some Python frameworks are Django, Flask, Tornado.
26th Sep 2020, 8:25 AM
Josh Greig
Josh Greig - avatar
0
Thank you guys. Things are a lot more clearer now. :)
27th Sep 2020, 1:23 AM
chou awara steven
chou awara steven - avatar