Dynamo Python Primer
  • Take Dynamo Further 🚀
  • 1 Hello Python 🐍
    • 1.1 Why Should I Learn to Code?
    • 1.2 Python Introduction
    • 1.3 What is IronPython?
  • 2 Seeing The Bigger Picture 🔭
    • 2.1 Context Matters
    • 2.2 What is an API?
    • 2.3 The .NET Framework
    • 2.4 Object-Oriented Programming
  • 3 Getting Started 🛴
    • 3.1 Dynamo's Python Node
    • 3.2 Boilerplate Setup Code
    • 3.3 Basics: Input and Output
    • 3.4 Common Errors
  • 4 Revit-Specific Topics 🏡
    • 4.1 Introduction to Revit's API
    • 4.2 How to Read Revit's API Documentation
    • 4.3 Doc, UIDoc, App, UIApp
    • 4.4 Unwrapping Revit Elements
    • 4.5 The FilteredElementCollector
    • 4.6 Geometry Conversion Methods
    • 4.7 Working With Parameters
      • Family Parameters
      • Global Parameters
      • Project Information Parameters
      • Group Parameters
      • Built-In Parameters
    • 4.8 Working With Transactions
    • 4.9 Opening & Closing External Files
    • 4.10 Prompting UI Selection
    • 4.11 Working With Units
    • 4.12 Built-In Categories
    • 4.13 Family Acrobatics
    • 4.14 Feedback: TaskDialogs
  • 5 Glossary 📚
  • About This Primer 👋
Powered by GitBook
On this page

Was this helpful?

  1. 1 Hello Python 🐍

1.3 What is IronPython?

IronPython is simply a dialect of the Python language

Previous1.2 Python IntroductionNext2 Seeing The Bigger Picture 🔭

Last updated 5 years ago

Was this helpful?

Programming Languages Have 'Dialects'

Programming languages are general purpose, but they're always deployed for a specific task; perhaps you're building a website's UI or administering hundreds of databases. This context will always determine what functionality is and isn't important for any given task. Sometimes, a particular 'dialect' of a programming language is spun-off, to better cater for a specific technical requirement. Much like a human dialect, these spin-off languages use same terminology and grammar, but have been adapted slightly to extend certain features or to better-suit their intended context.

These 'dialects' are known as implementations of a programming language.

Python has several popular implementations which have been built for specific purposes: IronPython is the implementation of the Python language that Dynamo uses.

IronPython Targets the .NET Framework

IronPython was specifically designed to target libraries of the .NET framework (See: ). This is very useful as it gives us access to Microsoft's .NET libraries, which are powerful and flexible resources built for professional software developers. A .NET Framework-capable Python implementation (i.e IronPython) was also needed to talk to the broader Autodesk AEC ecosystem which has API access via C#

The trade-off is that IronPython is an open-source project, whose updates are not tied to the main Python project. Its development has lagged behind Python, meaning it lacks some of the newer features of the standard Python language. Furthermore, certain popular Python libraries (such as numpy) were never built to target IronPython and so cannot be used within Dynamo. Finally, it is worth noting that IronPython is almost identical to Python 2 and Python 3, so the knowledge you gain from using IronPython will be directly transferable to many other areas of development outside of Dynamo.

What is the .NET Framework?