# Pavlovia Experiment stuck on loading - SyntaxError: missing ) in parenthetical

**URL:** https://discourse.psychopy.org/t/pavlovia-experiment-stuck-on-loading-syntaxerror-missing-in-parenthetical/8053
**Category:** Online experiments
**Created:** [June 9, 2019, 3:52pm UTC](https://discourse.psychopy.org/t/pavlovia-experiment-stuck-on-loading-syntaxerror-missing-in-parenthetical/8053 "2019-06-09T15:52:36Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![dvbridges](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.psychopy.org/dvbridges/32/1918_2.png) [@dvbridges](https://discourse.psychopy.org/u/dvbridges)
#### Post date: [June 9, 2019, 6:20pm UTC](https://discourse.psychopy.org/t/pavlovia-experiment-stuck-on-loading-syntaxerror-missing-in-parenthetical/8053/2 "2019-06-09T18:20:00Z")

</div>

Hi @imarchesini, I checked your parentheses and they look to line up correctly. I think this is an issue using `and` and `or` in JS. They are not the same as Pythons logical operators, you instead use `&&` and `||` for (`and`, `or`) respectively.

```javascript
if ( ( ( (timer.getTime() < 3) && mouse_3.getPressed && (mouse_3.isPressedIn(respuestaMasculino) || mouse_3.isPressedIn(respuestaFemenino)))) && muyRapido.status === PsychoJS.Status.NOT_STARTED) {

```

Also, `isPressedIn` is not actually a PsychoJS method. Have a look at the link to see how to code the equivalent in JS. You essentially have to check whether your object contains the mouse, and that simultaneously the mouse button has been pressed.

> [@Two questions: (1) steps for generating the online version of my task (2) JS code](https://discourse.psychopy.org/t/two-questions-1-steps-for-generating-the-online-version-of-my-task-2-js-code/7973/2):
>
> Hi @M11, if the code is not being output correctly, it means there is some issue stopping the code from being compiled. The translations above would be made easier if you surround your code in backticks (```). Try: msg = ''; if (mouse.getPressed()[0] === 1) { // If left mouse button pressed clickable = [R, F]; // clickable stim for (const obj of clickable) { // for each clickable stim, check if it contains the mouse if (obj.contains(mouse)) { if (obj === R && R === eval(MathCor…

---

_[View the full topic](https://discourse.psychopy.org/t/pavlovia-experiment-stuck-on-loading-syntaxerror-missing-in-parenthetical/8053)._
