SlideShare a Scribd company logo
1 of 18
Download to read offline
{
Python  2  vs.  Python  3	
“event”:      “Python  BCN  Meetup  –  Beginners  session”	
“author”:  “Pablo  Enfedaque”	
“twi6er”:  “@pablitoev56”
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
>  December  1989:  Guido  Van  Rossum  starts  
Python  implementation	
>  January  1994:  Version  1.0  released	
>  October  2000:  Version  2.0  released	
>  December  2008:  Version  3.0  released	
>  June  2009:  Version  3.1  released	
>  July  2010:  Version  2.7  released  with  backports	
>  2014:  current  versions  are  2.7.6  and  3.4	
Python  versions
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
>  December  1989:  Guido  Van  Rossum  starts  
Python  implementation	
>  January  1994:  Version  1.0  released	
>  October  2000:  Version  2.0  released	
>  December  2008:  Version  3.0  released	
>  June  2009:  Version  3.1  released	
>  July  2010:  Version  2.7  released  with  backports	
>  2014:  current  versions  are  2.7.6  and  3.4	
WTF?!
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Python  3  is	
backwards  incompatible
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
>  Backwards  incompatibilities	
>  print  and  exec  become  functions	
>  All  classes  are  new-­‐‑style	
>  Massive  usage  of  generators  instead  of  lists	
>  All  text  (str)  is  Unicode  and  encoded  text  is  
binary  data  (bytes)	
>  Other  minor  changes  in  std  lib	
Python  3.0
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Why  Python  3?
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Mainly  because  of  encodings	
Why  Python  3?
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Google:  Python  encoding  sucks
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Google:  Python  3  sucks
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Really  because  of  encodings??	
Why  Python  3?
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Why  should  I  move  to  Python  3?
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
>  Proper  encoding	
>  asyncio	
>  enums	
>  Standard  library  virtualenvs	
>  Exception  chaining	
>  Single-­‐‑dispatch	
>  uni6est.mock	
>  contextlib	
>  “Be6er”  GIL	
>  concurrent.futures	
>  selectors  module	
>  Qualified  names	
>  …	
Python  3.4  new  features  (vs.  2.7)
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Why  people  don’t  use  Python  3?
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Why  people  don’t  use  Python  3?	
No  dependencies  ported
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Why  people  don’t  use  Python  3?	
Laziness?
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
>  Great  features  are  waiting  us  in  Python  3	
>  We  are  beyond  half  the  planned  life  of  Python  2.7	
>  Python  2.6  is  officially  retired  with  2.6.9  release	
>  Most  3rd  party  dependencies  already  in  Python  3	
>  Or  we  could  return  to  OSS  all  that  we  have  been  given	
>  hZps://caniusepython3.com	
>  Porting  to  Python  3  is  not  such  a  big  deal	
>  In  most  of  the  cases	
>  So,  no  more  excuses	
>  It’s  time  to  start  moving  to  Python  3	
Conclusions
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Conclusions
{  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”}	
	
Q&A	
Thanks  for  coming!	
	
	
Slides:  
h6ps://speakerdeck.com/pablito56/
python-­‐‑2-­‐‑vs-­‐‑python-­‐‑3  

More Related Content

What's hot

Introduction to the basics of Python programming (part 1)
Introduction to the basics of Python programming (part 1)Introduction to the basics of Python programming (part 1)
Introduction to the basics of Python programming (part 1)Pedro Rodrigues
 
Python Exception Handling
Python Exception HandlingPython Exception Handling
Python Exception HandlingMegha V
 
Presentation on python
Presentation on pythonPresentation on python
Presentation on pythonwilliam john
 
Python Tutorial | Python Tutorial for Beginners | Python Training | Edureka
Python Tutorial | Python Tutorial for Beginners | Python Training | EdurekaPython Tutorial | Python Tutorial for Beginners | Python Training | Edureka
Python Tutorial | Python Tutorial for Beginners | Python Training | EdurekaEdureka!
 
Zero to Hero - Introduction to Python3
Zero to Hero - Introduction to Python3Zero to Hero - Introduction to Python3
Zero to Hero - Introduction to Python3Chariza Pladin
 
Python Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | EdurekaPython Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | EdurekaEdureka!
 
Exception Handling In Python | Exceptions In Python | Python Programming Tuto...
Exception Handling In Python | Exceptions In Python | Python Programming Tuto...Exception Handling In Python | Exceptions In Python | Python Programming Tuto...
Exception Handling In Python | Exceptions In Python | Python Programming Tuto...Edureka!
 
Introduction to Python IDLE | IDLE Tutorial | Edureka
Introduction to Python IDLE | IDLE Tutorial | EdurekaIntroduction to Python IDLE | IDLE Tutorial | Edureka
Introduction to Python IDLE | IDLE Tutorial | EdurekaEdureka!
 
Introduction to python programming
Introduction to python programmingIntroduction to python programming
Introduction to python programmingSrinivas Narasegouda
 
Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02Fariz Darari
 
Introduction to Python
Introduction to PythonIntroduction to Python
Introduction to PythonNowell Strite
 

What's hot (20)

Python Programming
Python ProgrammingPython Programming
Python Programming
 
Introduction to the basics of Python programming (part 1)
Introduction to the basics of Python programming (part 1)Introduction to the basics of Python programming (part 1)
Introduction to the basics of Python programming (part 1)
 
Programming with Python
Programming with PythonProgramming with Python
Programming with Python
 
Python final ppt
Python final pptPython final ppt
Python final ppt
 
Python Exception Handling
Python Exception HandlingPython Exception Handling
Python Exception Handling
 
Python Tutorial Part 1
Python Tutorial Part 1Python Tutorial Part 1
Python Tutorial Part 1
 
Python basics
Python basicsPython basics
Python basics
 
Presentation on python
Presentation on pythonPresentation on python
Presentation on python
 
Python Tutorial | Python Tutorial for Beginners | Python Training | Edureka
Python Tutorial | Python Tutorial for Beginners | Python Training | EdurekaPython Tutorial | Python Tutorial for Beginners | Python Training | Edureka
Python Tutorial | Python Tutorial for Beginners | Python Training | Edureka
 
Python
PythonPython
Python
 
Zero to Hero - Introduction to Python3
Zero to Hero - Introduction to Python3Zero to Hero - Introduction to Python3
Zero to Hero - Introduction to Python3
 
Python Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | EdurekaPython Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | Edureka
 
Exception Handling In Python | Exceptions In Python | Python Programming Tuto...
Exception Handling In Python | Exceptions In Python | Python Programming Tuto...Exception Handling In Python | Exceptions In Python | Python Programming Tuto...
Exception Handling In Python | Exceptions In Python | Python Programming Tuto...
 
Introduction to Python IDLE | IDLE Tutorial | Edureka
Introduction to Python IDLE | IDLE Tutorial | EdurekaIntroduction to Python IDLE | IDLE Tutorial | Edureka
Introduction to Python IDLE | IDLE Tutorial | Edureka
 
Control flow statements in java
Control flow statements in javaControl flow statements in java
Control flow statements in java
 
Introduction to python programming
Introduction to python programmingIntroduction to python programming
Introduction to python programming
 
Python Tutorial
Python TutorialPython Tutorial
Python Tutorial
 
Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02
 
Python exception handling
Python   exception handlingPython   exception handling
Python exception handling
 
Introduction to Python
Introduction to PythonIntroduction to Python
Introduction to Python
 

Viewers also liked

Basics of Object Oriented Programming in Python
Basics of Object Oriented Programming in PythonBasics of Object Oriented Programming in Python
Basics of Object Oriented Programming in PythonSujith Kumar
 
Python Tricks That You Can't Live Without
Python Tricks That You Can't Live WithoutPython Tricks That You Can't Live Without
Python Tricks That You Can't Live WithoutAudrey Roy
 
Advance OOP concepts in Python
Advance OOP concepts in PythonAdvance OOP concepts in Python
Advance OOP concepts in PythonSujith Kumar
 
Introduction to Python
Introduction to Python Introduction to Python
Introduction to Python amiable_indian
 
Python的50道陰影
Python的50道陰影Python的50道陰影
Python的50道陰影Tim (文昌)
 
連淡水阿嬤都聽得懂的 機器學習入門 scikit-learn
連淡水阿嬤都聽得懂的機器學習入門 scikit-learn 連淡水阿嬤都聽得懂的機器學習入門 scikit-learn
連淡水阿嬤都聽得懂的 機器學習入門 scikit-learn Cicilia Lee
 
型態與運算子
型態與運算子型態與運算子
型態與運算子Justin Lin
 
常用內建模組
常用內建模組常用內建模組
常用內建模組Justin Lin
 
Python 起步走
Python 起步走Python 起步走
Python 起步走Justin Lin
 
Learn 90% of Python in 90 Minutes
Learn 90% of Python in 90 MinutesLearn 90% of Python in 90 Minutes
Learn 90% of Python in 90 MinutesMatt Harrison
 
[系列活動] Python 程式語言起步走
[系列活動] Python 程式語言起步走[系列活動] Python 程式語言起步走
[系列活動] Python 程式語言起步走台灣資料科學年會
 
[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹
[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹
[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹台灣資料科學年會
 

Viewers also liked (15)

Python 2-基本語法
Python 2-基本語法Python 2-基本語法
Python 2-基本語法
 
Basics of Object Oriented Programming in Python
Basics of Object Oriented Programming in PythonBasics of Object Oriented Programming in Python
Basics of Object Oriented Programming in Python
 
Python Tricks That You Can't Live Without
Python Tricks That You Can't Live WithoutPython Tricks That You Can't Live Without
Python Tricks That You Can't Live Without
 
Advance OOP concepts in Python
Advance OOP concepts in PythonAdvance OOP concepts in Python
Advance OOP concepts in Python
 
Introduction to Python
Introduction to Python Introduction to Python
Introduction to Python
 
Python的50道陰影
Python的50道陰影Python的50道陰影
Python的50道陰影
 
連淡水阿嬤都聽得懂的 機器學習入門 scikit-learn
連淡水阿嬤都聽得懂的機器學習入門 scikit-learn 連淡水阿嬤都聽得懂的機器學習入門 scikit-learn
連淡水阿嬤都聽得懂的 機器學習入門 scikit-learn
 
型態與運算子
型態與運算子型態與運算子
型態與運算子
 
進階主題
進階主題進階主題
進階主題
 
常用內建模組
常用內建模組常用內建模組
常用內建模組
 
Python 起步走
Python 起步走Python 起步走
Python 起步走
 
Learn 90% of Python in 90 Minutes
Learn 90% of Python in 90 MinutesLearn 90% of Python in 90 Minutes
Learn 90% of Python in 90 Minutes
 
[系列活動] Python 程式語言起步走
[系列活動] Python 程式語言起步走[系列活動] Python 程式語言起步走
[系列活動] Python 程式語言起步走
 
[系列活動] Python爬蟲實戰
[系列活動] Python爬蟲實戰[系列活動] Python爬蟲實戰
[系列活動] Python爬蟲實戰
 
[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹
[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹
[系列活動] 無所不在的自然語言處理—基礎概念、技術與工具介紹
 

Similar to Python 2 vs. Python 3

Class 1: Welcome to programming
Class 1: Welcome to programmingClass 1: Welcome to programming
Class 1: Welcome to programmingMarc Gouw
 
EuroPython 2015 - Decorators demystified
EuroPython 2015 - Decorators demystifiedEuroPython 2015 - Decorators demystified
EuroPython 2015 - Decorators demystifiedPablo Enfedaque
 
OpenGurukul : Language : Python
OpenGurukul : Language : PythonOpenGurukul : Language : Python
OpenGurukul : Language : PythonOpen Gurukul
 
Pycon2017 instagram keynote
Pycon2017 instagram keynotePycon2017 instagram keynote
Pycon2017 instagram keynoteLisa Guo
 
Easy contributable internationalization process with Sphinx @ PyCon APAC 2016
Easy contributable internationalization process with Sphinx @ PyCon APAC 2016Easy contributable internationalization process with Sphinx @ PyCon APAC 2016
Easy contributable internationalization process with Sphinx @ PyCon APAC 2016Takayuki Shimizukawa
 
Jupyter Kernel: How to Speak in Another Language
Jupyter Kernel: How to Speak in Another LanguageJupyter Kernel: How to Speak in Another Language
Jupyter Kernel: How to Speak in Another LanguageWey-Han Liaw
 
Execution model and other must-know's
Execution model and other must-know'sExecution model and other must-know's
Execution model and other must-know'sPablo Enfedaque
 
Susanna frazier 1 pager sourcing on git hub
Susanna frazier 1 pager   sourcing on git hubSusanna frazier 1 pager   sourcing on git hub
Susanna frazier 1 pager sourcing on git hubTalent42
 

Similar to Python 2 vs. Python 3 (9)

Decorators demystified
Decorators demystifiedDecorators demystified
Decorators demystified
 
Class 1: Welcome to programming
Class 1: Welcome to programmingClass 1: Welcome to programming
Class 1: Welcome to programming
 
EuroPython 2015 - Decorators demystified
EuroPython 2015 - Decorators demystifiedEuroPython 2015 - Decorators demystified
EuroPython 2015 - Decorators demystified
 
OpenGurukul : Language : Python
OpenGurukul : Language : PythonOpenGurukul : Language : Python
OpenGurukul : Language : Python
 
Pycon2017 instagram keynote
Pycon2017 instagram keynotePycon2017 instagram keynote
Pycon2017 instagram keynote
 
Easy contributable internationalization process with Sphinx @ PyCon APAC 2016
Easy contributable internationalization process with Sphinx @ PyCon APAC 2016Easy contributable internationalization process with Sphinx @ PyCon APAC 2016
Easy contributable internationalization process with Sphinx @ PyCon APAC 2016
 
Jupyter Kernel: How to Speak in Another Language
Jupyter Kernel: How to Speak in Another LanguageJupyter Kernel: How to Speak in Another Language
Jupyter Kernel: How to Speak in Another Language
 
Execution model and other must-know's
Execution model and other must-know'sExecution model and other must-know's
Execution model and other must-know's
 
Susanna frazier 1 pager sourcing on git hub
Susanna frazier 1 pager   sourcing on git hubSusanna frazier 1 pager   sourcing on git hub
Susanna frazier 1 pager sourcing on git hub
 

Recently uploaded

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 

Recently uploaded (20)

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 

Python 2 vs. Python 3

  • 1. { Python  2  vs.  Python  3 “event”:      “Python  BCN  Meetup  –  Beginners  session” “author”:  “Pablo  Enfedaque” “twi6er”:  “@pablitoev56”
  • 2. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} >  December  1989:  Guido  Van  Rossum  starts   Python  implementation >  January  1994:  Version  1.0  released >  October  2000:  Version  2.0  released >  December  2008:  Version  3.0  released >  June  2009:  Version  3.1  released >  July  2010:  Version  2.7  released  with  backports >  2014:  current  versions  are  2.7.6  and  3.4 Python  versions
  • 3. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} >  December  1989:  Guido  Van  Rossum  starts   Python  implementation >  January  1994:  Version  1.0  released >  October  2000:  Version  2.0  released >  December  2008:  Version  3.0  released >  June  2009:  Version  3.1  released >  July  2010:  Version  2.7  released  with  backports >  2014:  current  versions  are  2.7.6  and  3.4 WTF?!
  • 4. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Python  3  is backwards  incompatible
  • 5. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} >  Backwards  incompatibilities >  print  and  exec  become  functions >  All  classes  are  new-­‐‑style >  Massive  usage  of  generators  instead  of  lists >  All  text  (str)  is  Unicode  and  encoded  text  is   binary  data  (bytes) >  Other  minor  changes  in  std  lib Python  3.0
  • 6. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Why  Python  3?
  • 7. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Mainly  because  of  encodings Why  Python  3?
  • 8. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Google:  Python  encoding  sucks
  • 9. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Google:  Python  3  sucks
  • 10. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Really  because  of  encodings?? Why  Python  3?
  • 11. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Why  should  I  move  to  Python  3?
  • 12. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} >  Proper  encoding >  asyncio >  enums >  Standard  library  virtualenvs >  Exception  chaining >  Single-­‐‑dispatch >  uni6est.mock >  contextlib >  “Be6er”  GIL >  concurrent.futures >  selectors  module >  Qualified  names >  … Python  3.4  new  features  (vs.  2.7)
  • 13. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Why  people  don’t  use  Python  3?
  • 14. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Why  people  don’t  use  Python  3? No  dependencies  ported
  • 15. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Why  people  don’t  use  Python  3? Laziness?
  • 16. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} >  Great  features  are  waiting  us  in  Python  3 >  We  are  beyond  half  the  planned  life  of  Python  2.7 >  Python  2.6  is  officially  retired  with  2.6.9  release >  Most  3rd  party  dependencies  already  in  Python  3 >  Or  we  could  return  to  OSS  all  that  we  have  been  given >  hZps://caniusepython3.com >  Porting  to  Python  3  is  not  such  a  big  deal >  In  most  of  the  cases >  So,  no  more  excuses >  It’s  time  to  start  moving  to  Python  3 Conclusions
  • 17. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Conclusions
  • 18. {  “event”:  “Python  BCN  Meetup”,  “author”:  “Pablo  Enfedaque”,  “twi6er”:  “@pablitoev56”} Q&A Thanks  for  coming! Slides:   h6ps://speakerdeck.com/pablito56/ python-­‐‑2-­‐‑vs-­‐‑python-­‐‑3