Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

[open] Error during reopenning of a fonctional experiment

edited March 2016 in OpenSesame

Hi all,

I run on the last version of OpenSesame 3.0.6 with python 2.7.11 on mac capitan.

I coded my experiment and it works well, I have a good export file and the led on the trigger device show me that triggers are operational. But after saving and closing my experiment it's imposible to reopen the file.
This happend after adding few lines of code to add trigger in my recording data. With the old version of OpenSesame the error message said "Failed to parse line .... Is there a closing quotation missing?" and with the new version it say "Missing end block for multiline variable." (And in details : item-stack:``)

To reproduce I put in the following folder:
- the version ok (without the code of trigger)
- the version ko (with the code added, that I ran correctly but that I cant reopen)
- the code added in a .doc (green part is the code which created the error)

image

Somonene already meet this error ? Is it posible to fix / get around this problem ?
I apologize i'm a beginner and my code is probably not optimised.. (but it works usually)

Many thanks for your help,

Cheers,

Nadam

Comments

  • edited 12:03PM

    Hi Nadam,

    You can always extract your script from an .osexp file, because it is either a plain-text script (if no files in the pool) or a .tar.gz archive that you can open with tools like 7zip (if files in the pool). See here:

    In any case, I extracted the script, and you can find it here:

    The script is corrupt in a funny way, and I don't know what could have caused it. The problem: One block is not indented properly:

        if condition=='cong':
        trig_value='B'
    else:
        trig_value='C'
    
    trigger.write(trig_value) # pousse le trigger sur le boitier arduino
    

    This should be:

        if condition=='cong':
            trig_value='B'
        else:
            trig_value='C'
    
        trigger.write(trig_value) # pousse le trigger sur le boitier arduino
    

    That is, in OpenSesame script everything should be tab-indented at least one level deep. (This indentation will be removed when viewing the script as Python code in OpenSesame.)

    So you can just download the script from the link, fix the indentation in a text editor, and then open the script in OpenSesame.

    However, this shouldn't happen. Do you have any idea what caused the problem? Can you reproduce it? That way we can fix it, and avoid it from happening in the future.

    Cheers,
    Sebastiaan

  • edited 12:03PM

    Thanks a lot. The problem is solved. I don't understand what happened because this indentation error was invisible and the experiment ran before closing it. But I did copy-paste of the code (from the word document add to the folder).It's probably the source of this bug. Yes it's possible to reproduce the bug with the elements in the folder by adding the green code to the ok_version of my script. I did it a lot of time before to post this S.O.S.

    Thanks again for your reactivity and your interest.

    Nadam

  • edited 12:03PM

    That's interesting. My gut feeling is that the green text has some hidden control characters (to make it green) that cause the OpenSesame script to become corrupted. I'm going to look into it, and see how we can prevent this from happening.

  • edited 12:03PM

    I put the green color after meeting the problem, just for facilitate the reproduction, so I think there is hidden formatting, but not (or not only because of the color).

    I hope it will be helpfull for you.

Sign In or Register to comment.

agen judi bola , sportbook, casino, togel, number game, singapore, tangkas, basket, slot, poker, dominoqq, agen bola. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 50.000 ,- bonus cashback hingga 10% , diskon togel hingga 66% bisa bermain di android dan IOS kapanpun dan dimana pun. poker , bandarq , aduq, domino qq , dominobet. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 10.000 ,- bonus turnover 0.5% dan bonus referral 20%. Bonus - bonus yang dihadirkan bisa terbilang cukup tinggi dan memuaskan, anda hanya perlu memasang pada situs yang memberikan bursa pasaran terbaik yaitu http://45.77.173.118/ Bola168. Situs penyedia segala jenis permainan poker online kini semakin banyak ditemukan di Internet, salah satunya TahunQQ merupakan situs Agen Judi Domino66 Dan BandarQ Terpercaya yang mampu memberikan banyak provit bagi bettornya. Permainan Yang Di Sediakan Dewi365 Juga sangat banyak Dan menarik dan Peluang untuk memenangkan Taruhan Judi online ini juga sangat mudah . Mainkan Segera Taruhan Sportbook anda bersama Agen Judi Bola Bersama Dewi365 Kemenangan Anda Berapa pun akan Terbayarkan. Tersedia 9 macam permainan seru yang bisa kamu mainkan hanya di dalam 1 ID saja. Permainan seru yang tersedia seperti Poker, Domino QQ Dan juga BandarQ Online. Semuanya tersedia lengkap hanya di ABGQQ. Situs ABGQQ sangat mudah dimenangkan, kamu juga akan mendapatkan mega bonus dan setiap pemain berhak mendapatkan cashback mingguan. ABGQQ juga telah diakui sebagai Bandar Domino Online yang menjamin sistem FAIR PLAY disetiap permainan yang bisa dimainkan dengan deposit minimal hanya Rp.25.000. DEWI365 adalah Bandar Judi Bola Terpercaya & resmi dan terpercaya di indonesia. Situs judi bola ini menyediakan fasilitas bagi anda untuk dapat bermain memainkan permainan judi bola. Didalam situs ini memiliki berbagai permainan taruhan bola terlengkap seperti Sbobet, yang membuat DEWI365 menjadi situs judi bola terbaik dan terpercaya di Indonesia. Tentunya sebagai situs yang bertugas sebagai Bandar Poker Online pastinya akan berusaha untuk menjaga semua informasi dan keamanan yang terdapat di POKERQQ13. Kotakqq adalah situs Judi Poker Online Terpercayayang menyediakan 9 jenis permainan sakong online, dominoqq, domino99, bandarq, bandar ceme, aduq, poker online, bandar poker, balak66, perang baccarat, dan capsa susun. Dengan minimal deposit withdraw 15.000 Anda sudah bisa memainkan semua permaina pkv games di situs kami. Jackpot besar,Win rate tinggi, Fair play, PKV Games