# 3d slicer custom app: how to obfuscate python code

**URL:** <https://discourse.slicer.org/t/3d-slicer-custom-app-how-to-obfuscate-python-code/35006>\
**Category:** Development\
**Created:** [March 21, 2024, 1:23pm UTC](https://discourse.slicer.org/t/3d-slicer-custom-app-how-to-obfuscate-python-code/35006 "2024-03-21T13:23:29Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [March 21, 2024, 1:56pm UTC](https://discourse.slicer.org/t/3d-slicer-custom-app-how-to-obfuscate-python-code/35006/2 "2024-03-21T13:56:28Z")

</div>

I suggest looking at this thread

> [@How to hide the code of the script module?](https://discourse.slicer.org/t/how-to-hide-the-code-of-the-script-module/26135/26):
>
> Corresponding approach was revisited by instead introduce the option CTK\_COMPILE\_PYTHON\_SCRIPT\_KEEP\_ONLY\_PYC to support removing \*.py script once the corresponding \*.pyc file has been generated in the destination directory. See [https://github.com/commontk/CTK/pull/1192](https://github.com/commontk/CTK/pull/1192)@MJamal At your convenience, consider reviewing and testing the proposed changes pray

---

_[View the full topic](https://discourse.slicer.org/t/3d-slicer-custom-app-how-to-obfuscate-python-code/35006)._
