Reader small image

You're reading from  Practical Python Programming for IoT

Product typeBook
Published inNov 2020
Reading LevelIntermediate
PublisherPackt
ISBN-139781838982461
Edition1st Edition
Languages
Right arrow

Chapter 12 

  1. A publish-subscribe approach promotes a highly decoupled approach to programming. This can be beneficial when you have many components (for example, sensors) publishing data that simply needs to be consumed elsewhere in your program.
  2. GIL stands for Global Interpreter Lock. It's a design aspect of the Python programming language that means only one thread ever has access to the Python interpreter at a time.
  1. A pure event loop (for example, one long while loop) can get complex as your program grows. The need for many state variables and non-trivial and intervening conditional tests (for example, if statements) can make the program logic hard to follow and debug.
  2. No. Every approach has its purpose. Event loops are fine when they are small and focused. It's only when they become large and are performing multiple actions that they become complex.
  3. When you are programming with threads, calling join() on another thread...
lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Practical Python Programming for IoT
Published in: Nov 2020Publisher: PacktISBN-13: 9781838982461