# Function Calls BOOL Parameters not accepting 1 or 0 now?

**URL:** <https://forum.inductiveautomation.com/t/function-calls-bool-parameters-not-accepting-1-or-0-now/86262>\
**Category:** Ignition\
**Tags:** ignition81, scripting\
**Created:** [February 23, 2024, 3:21pm UTC](https://forum.inductiveautomation.com/t/function-calls-bool-parameters-not-accepting-1-or-0-now/86262 "2024-02-23T15:21:58Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![MMaynard](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mmaynard/32/3366_2.png) [@MMaynard](https://forum.inductiveautomation.com/u/MMaynard)\
**Post date:** [February 23, 2024, 3:21pm UTC](https://forum.inductiveautomation.com/t/function-calls-bool-parameters-not-accepting-1-or-0-now/86262/1 "2024-02-23T15:21:58Z")

</div>

When did system.\* function calls stop accepting 0 or 1 for boolean parameters?  
We just upgraded a gateway to 8.1.35 and noticed it.

for example:  
`event.source.text = system.gui.showTouchscreenKeyboard('', 14, 0)`  
Works just fine in 8.1.9  
But will fail on 8.1.35

```auto
Traceback (most recent call last):
  File "<event:mouseClicked>", line 1, in <module>
TypeError: showTouchscreenKeyboard() argument passwordMode: expected Boolean instance, PyInteger found

Ignition v8.1.35 (b2023120517)
Java: Azul Systems, Inc. 17.0.8

```

Is this the way it is going to be going forward?  
Is it a regression?  
Just wondering, and already added to our check list of things to watch out for on upgrades.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [February 23, 2024, 3:28pm UTC](https://forum.inductiveautomation.com/t/function-calls-bool-parameters-not-accepting-1-or-0-now/86262/2 "2024-02-23T15:28:48Z")

</div>

This particular function happened to migrate to using keyword arguments (to support the extra arguments added for the international keyboard stuff). In the process, the argument parsing was made a bit more strict - not exactly intentionally, but not exactly by accident either.

This won't "just happen" unless changes are made on our end in the code. You could call this a regression - feel free to email into support and we could end up relaxing the parsing code for keyword arguments to allow integers are booleans. I personally consider it a smell, relying on type coercion like that, but I know some folks are used to 1/0 as booleans so I won't die on the hill.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [February 23, 2024, 3:50pm UTC](https://forum.inductiveautomation.com/t/function-calls-bool-parameters-not-accepting-1-or-0-now/86262/3 "2024-02-23T15:50:11Z")

</div>

> [@paul-griffith](#):
>
> are used to 1/0 as booleans

Some insufficiently-darned databases, too. You should relax this.

---

<div class="post-metadata">

**Author:** ![MMaynard](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mmaynard/32/3366_2.png) [@MMaynard](https://forum.inductiveautomation.com/u/MMaynard)\
**Post date:** [February 23, 2024, 3:53pm UTC](https://forum.inductiveautomation.com/t/function-calls-bool-parameters-not-accepting-1-or-0-now/86262/4 "2024-02-23T15:53:22Z")

</div>

> [@paul-griffith](#):
>
> - feel free to email into support

Meh. PotHEYto, PoTAHto..  
We are aware of it now, so it's just part of our upgrade checks.  
Might be a good idea to have these kinds of changes in the version change logs though. 🤷‍♂️

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [February 23, 2024, 4:49pm UTC](https://forum.inductiveautomation.com/t/function-calls-bool-parameters-not-accepting-1-or-0-now/86262/5 "2024-02-23T16:49:47Z")

</div>

Yeah, I've convinced myself of that. I'll get it in an upcoming 8.1.X release.
