# Python Engines (Poll)

**URL:** <https://forum.dynamobim.com/t/python-engines-poll/62801>\
**Category:** Developers\
**Tags:** python, poll\
**Created:** [April 12, 2021, 4:05pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801 "2021-04-12T16:05:56Z")\
**Posts on this page:** 18\
**Page:** 1

<div class="post-metadata">

**Author:** ![c.poupin](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/c.poupin/32/89152_2.png) [@c.poupin](https://forum.dynamobim.com/u/c.poupin)\
**Post date:** [April 12, 2021, 4:05pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/1 "2021-04-12T16:05:56Z")

</div>

Hello all

With Revit(2022) or Civil3D(2022), It is now possible to use 2 Python engines in Dynamo

- IronPython2 (target Python 2.7)
- CPython3 with Pythonnet Bridge (target Python 3.7+)

> From Dynamo 2.7 onwards, you now have the option of using either IronPython2 (Which has historically been in Dynamo) or the new CPython3 - available as different engines on each Python node which compute using either Python 2 or Python 3 code respectively. Note - you can use both versions in a single graph.

> From Dynamo 2.11 onwards, CPython3 will be the both the default engine and officially supported Python engine inside of Dynamo. You will be able to access IronPython2 via the Package Manager on a per-user basis.

Beyond the difference between Python 2 and Python 3, there are some differences with the .NET 4.0+ Common Language Runtime (CLR) integration:

- IronPython2 → IronPython ([more detail here](https://ironpython.net/))  
_IronPython is a .NET native Implementation of Python for .NET Framework that is built on top of the Dynamic Language Runtime._
- CPython3 → [Python.NET](http://Python.NET) ([more detail here](http://pythonnet.github.io/))  
_Python for .NET is a package that gives Python programmers nearly seamless integration with the .NET Common Language Runtime (CLR)_

_Poll ([view on site](https://forum.dynamobim.com/t/python-engines-poll/62801/1))_

_ **Note** _  
one should not see IronPython and CPython/PythonNet as competitors, each have different qualities

---

<div class="post-metadata">

**Author:** ![c.poupin](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/c.poupin/32/89152_2.png) [@c.poupin](https://forum.dynamobim.com/u/c.poupin)\
**Post date:** [April 12, 2021, 4:30pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/2 "2021-04-12T16:30:31Z")

</div>

Pinned globally on April 12, 2021, 4:30pm UTC



---

<div class="post-metadata">

**Author:** ![jacob.small](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/jacob.small/32/161030_2.png) [@jacob.small](https://forum.dynamobim.com/u/jacob.small)\
**Post date:** [April 12, 2021, 4:37pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/3 "2021-04-12T16:37:43Z")

</div>

In my opinion the advantages of CPython3 is enough that staying with the old is foolhardy after a point. Moving past Python 2 should eventually be a goal for everyone - locking a larger package (say Genius Loci, or Clockwork) down to 2 at the next release and starting to develop only on 3 makes sense to me.

---

<div class="post-metadata">

**Author:** ![Brendan\_Cassidy](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/brendan_cassidy/32/7685_2.png) [@Brendan\_Cassidy](https://forum.dynamobim.com/u/Brendan_Cassidy)\
**Post date:** [April 12, 2021, 7:11pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/4 "2021-04-12T19:11:55Z")

</div>

I dont see them as competitors, i see one as a security risk because of the lack of support for Python 2 anymore. Python 2 had its EOL on 1st Jan 2020, and IronPython is developed by volunteers

Therefore we need to move onto the latest version to hopefully stay away from security risks if any end up being found.

Note: IronPython3 has been in development for a long time, still in WIP status and is done by volunteers only.

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/c/2/c231dbada520ef234045286f4591e16f09194c80.png)

---

<div class="post-metadata">

**Author:** ![Michael\_Kirschner2](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/michael_kirschner2/32/75576_2.png) [@Michael\_Kirschner2](https://forum.dynamobim.com/u/Michael_Kirschner2)\
**Post date:** [April 12, 2021, 7:51pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/5 "2021-04-12T19:51:41Z")

</div>

They both have benefits and many costs, PythonNet is also a non sponsored project AFAIK.

---

<div class="post-metadata">

**Author:** ![c.poupin](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/c.poupin/32/89152_2.png) [@c.poupin](https://forum.dynamobim.com/u/c.poupin)\
**Post date:** [April 12, 2021, 8:18pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/6 "2021-04-12T20:18:39Z")

</div>

> [@Brendan\_Cassidy](#):
>
> Note: IronPython3 has been in development for a long time, still in WIP status

for info IronPython3 is coming very soon in version 3.4

---

<div class="post-metadata">

**Author:** ![Marcel\_Rijsmus](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/marcel_rijsmus/32/8539_2.png) [@Marcel\_Rijsmus](https://forum.dynamobim.com/u/Marcel_Rijsmus)\
**Post date:** [April 12, 2021, 8:20pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/7 "2021-04-12T20:20:25Z")

</div>

These “Software makers” or volunteers are just like Dynamo graph makers i think, “ok guys” 😤 😤

---

<div class="post-metadata">

**Author:** ![c.poupin](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/c.poupin/32/89152_2.png) [@c.poupin](https://forum.dynamobim.com/u/c.poupin)\
**Post date:** [April 13, 2021, 6:42am UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/8 "2021-04-13T06:42:32Z")

</div>

If we are only talking about Python 2 vs Python 3, the choice does not really arise (Python3).

Now if we compare the .Net integration, IronPython has some advantages over the PythonNet package, which can make the choice a little more complicated for some depending on their level of experience.

An example with an [indexed property](https://www.revitapidocs.com/2020.1/2b41a232-8cc9-e2bf-8e47-dd95eaf25275.htm)

 ![Screenshot_19696](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/6/e/6e08b873c88ab5c18b5165348c1654ba949e41aa.png)

Edit  
After thinking about it (no pun intended) there is finally easier for this example…

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/a/9/a9f8ce1d047da426e53e6be9985d61546e849fce.png)

---

<div class="post-metadata">

**Author:** ![Karam\_Baki](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/karam_baki/32/113558_2.png) [@Karam\_Baki](https://forum.dynamobim.com/u/Karam_Baki)\
**Post date:** [April 13, 2021, 10:39pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/9 "2021-04-13T22:39:39Z")

</div>

Surely everything NEW is going to be made with CPython 3.

My only concern would be the given time to us, package developers, to migrate all of our EXISTED nodes to CPython3…

For example my package consists of almost 700 custom nodes, and more than 500 dyn graphs, many which uses Ironpython 2.  
We would eventually move to CPython3, but it will take years… 4 or 5 at least in my side, as I will progressively migrate/test nodes in each update, and it’s really hard work.

---

<div class="post-metadata">

**Author:** ![MartinSpence](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/martinspence/32/25208_2.png) [@MartinSpence](https://forum.dynamobim.com/u/MartinSpence)\
**Post date:** [April 14, 2021, 12:52pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/10 "2021-04-14T12:52:28Z")

</div>

You just made me a little nervous with your initial CPython3 example 😂

---

<div class="post-metadata">

**Author:** ![leonard.moelders](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/leonard.moelders/32/108216_2.png) [@leonard.moelders](https://forum.dynamobim.com/u/leonard.moelders)\
**Post date:** [January 10, 2023, 10:11am UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/11 "2023-01-10T10:11:53Z")

</div>

I have a little question here:

Will Dynamo completely switch from IronPython to CPython? AFAIK the current version of IronPython is 3.4. Will there be chance, that this will be available in future Dynamo for Revit versions?

---

<div class="post-metadata">

**Author:** ![c.poupin](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/c.poupin/32/89152_2.png) [@c.poupin](https://forum.dynamobim.com/u/c.poupin)\
**Post date:** [January 10, 2023, 10:28am UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/12 "2023-01-10T10:28:20Z")

</div>

Probably, in any case, it is under study

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/c/d/cd18a8149cdd27eddc3d2b29a46523efbcaa8c49.png)

> <https://twitter.com/solamour/status/1602646833209253891?s=20&t=mNtUDSbiDVdye4Z79xG9hA>

---

<div class="post-metadata">

**Author:** ![leonard.moelders](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/leonard.moelders/32/108216_2.png) [@leonard.moelders](https://forum.dynamobim.com/u/leonard.moelders)\
**Post date:** [January 10, 2023, 10:30am UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/13 "2023-01-10T10:30:47Z")

</div>

Cool, this seems promising 🙂 👍

---

<div class="post-metadata">

**Author:** ![GavinNicholls](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/gavinnicholls/32/190442_2.png) [@GavinNicholls](https://forum.dynamobim.com/u/GavinNicholls)\
**Post date:** [January 10, 2023, 1:59pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/14 "2023-01-10T13:59:24Z")

</div>

Boy do I hope so. Finding a lot of quirks and some brick walls in CPython3 so far.

---

<div class="post-metadata">

**Author:** ![Vladimir](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/vladimir/32/147600_2.png) [@Vladimir](https://forum.dynamobim.com/u/Vladimir)\
**Post date:** [January 10, 2023, 2:36pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/15 "2023-01-10T14:36:08Z")

</div>

> [@Karam\_Baki](#):
>
> We would eventually move to CPython3, but it will take years… 4 or 5 at least in my side, as I will progressively migrate/test nodes in each update, and it’s really hard work.

@Karam_Baki, totally agree with you.  
The power of Dynamo is speed of graphs development. So any good packages matter.  
Especially great ones, like Synthesize and many more. Many authors won’t update their,  
many packages are abandoned but working good!  
One advantage of using CPython now in Dynamo is an ability to use native Python Packages from [PyPi](https://pypi.org/) repo.  
The IronPython 2.7 is 10 about years old now, but it works stable. If we’ll able to install Python Packages in IronPython 3.4 it will be great. Doesn’t matter, as Dynamo package or main solution.

---

<div class="post-metadata">

**Author:** ![Brendan\_Cassidy](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/brendan_cassidy/32/7685_2.png) [@Brendan\_Cassidy](https://forum.dynamobim.com/u/Brendan_Cassidy)\
**Post date:** [January 10, 2023, 3:38pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/16 "2023-01-10T15:38:28Z")

</div>

> [@Vladimir](#):
>
> One advantage of using CPython now in Dynamo is an ability to use native Python Packages from [PyPi](https://pypi.org/) repo.

Do watch out for TypoSquatting of packages and other safety risks. There has been a couple of articles about rogue packages recently on PyPi.

---

<div class="post-metadata">

**Author:** ![Vladimir](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/vladimir/32/147600_2.png) [@Vladimir](https://forum.dynamobim.com/u/Vladimir)\
**Post date:** [January 10, 2023, 3:58pm UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/17 "2023-01-10T15:58:48Z")

</div>

I think we all use some antivirus software. Of course, we can say NO to all packages PyPi. But can you be shure, that all Dynamo packages are safe? Working on PC is a risk in our days anyhow.

P.S. Is CPython more safe than IronPython, if we use PyPi packages?

---

<div class="post-metadata">

**Author:** ![Brendan\_Cassidy](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/brendan_cassidy/32/7685_2.png) [@Brendan\_Cassidy](https://forum.dynamobim.com/u/Brendan_Cassidy)\
**Post date:** [January 11, 2023, 8:00am UTC](https://forum.dynamobim.com/t/python-engines-poll/62801/18 "2023-01-11T08:00:58Z")

</div>

Do not rely on a virus scanner. They may not be able to detect a new version, but they are a ok first line of defence while not being the only thing you should do.

Some of the rogue packages that have been found out, do not install any malware but instead extract Cloud Tokens or other information which may be by-passing virus scanners.

On the note about Dynamo Packages, I generally stay with the well known packages or packages that have the source code released(eg on github).

I would treat IronPython(2.7 or 3.4) and Cpython packages as the same.
