Jan 15, 2015 Tag: Python

Looking for Wisdom about Python

Ongoing attempt to collect links and documentation about TYPO3. New links will go here first and may later be outsourced into a separate post. Will be updated as needed.

Updated on Oct 30, 2018

Navigate this page:

Advocating Python

Application development

BeeWare

BeeWare — build native apps with Python

Kivy

Kivy - Open source Python library for rapid development of applications that make use of innovative user interfaces, such as multi-touch apps. Not looking native.

Argument parsing

Natural Language Processing

<<<<<<< Updated upstream <<<<<<< Updated upstream

>>>>>>> Stashed changes

>>>>>>> Stashed changes

Online Tools

  • Pythontutor: VISUALIZE the execution of Python, Java, JavaScript, and TypeScript code !!!

    Online Python Tutor is a free educational tool created by Philip Guo !!! that helps students overcome a fundamental barrier to learning programming: understanding what happens as the computer executes each line of a program’s source code.

    Using this tool, a teacher or student can write Python, Java, JavaScript, and TypeScript programs in the Web browser and visualize what the computer is doing step-by-step as it executes those programs.

    Over one million people in over 165 countries have used Online Python Tutor to understand and debug their programs, often as a supplement to textbooks, lecture notes, and online programming tutorials.

PyPi Packaging and Publishing

Upload to PyPi

  • Use twine. Twine is a utility for interacting with PyPI.

  • Build the project:

    python setup.py build
    
  • Upload:

    twine upload build/*
    

Python Coding Style

Dan Bader about “The quest for the “definitive Python style guide”:

One of the things I like the most about Python is it’s high readability.

I strongly believe that “code is communication”

And just like there are generally accepted stylistic rules & guidelines for written communication in English, there are code style guides for writing Python. Sticking to these guidelines is one honking great idea. They make it easier for development teams to work together. And even if you’re working on a project by yourself, they’ll help you make changes in the future.

Python and other languages

Snippets

Solutions

‘is last’ for iterator

  • James Bowman: http://www.excamera.com/sphinx/article-islast.html

    islast: handling the last element of an iterator

    Doing something special for the last element of an iterator is a fairly common pattern. I needed it for the Python Jtag tools, so made this small wrapper …

    def islast(o):
       it = o.__iter__()
       e = it.next()
       while True:
          try:
             nxt = it.next()
             yield (False, e)
             e = nxt
          except StopIteration:
             yield (True, e)
             break
    
    # example
    # for i in islast(range(4)): print i
    

Web Frameworks

  • Tornado Web Server

    Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed. By using non-blocking network I/O, Tornado can scale to tens of thousands of open connections, making it ideal for long polling, WebSockets, and other applications that require a long-lived connection to each user.

What’s new?

2014 PyCon

2015 PyCon

Previous topic

Looking for Wisdom about MySql

Next topic

Looking for Wisdom about Ruby

Tags

Archives

Languages

Recent Posts

This Page