OE 2.2 eConsoleAppContainer error

  • I am trying to convert a plugin to OE 2.2 and the line (where self.appContainer = eConsoleAppContainer() and dump is a dict):-


    self.appContainer.write(dump)


    gives the error :-


    TypeError: eConsoleAppContainer_write expected 3 arguments, got 2


    What should be the 3rd argument ?


    Regards, pcd.

    Einmal editiert, zuletzt von pcd ()

  • old console.cpp I found on the net show that the second argument is the length. but this was also the case in oe1.6. but maybe just give it a try.

    Gruss
    Dre


    Boxen (im Einsatz): DM920, DM900, DMOne
    Developer Project Merlin - we are OpenSource

  • old console.cpp I found on the net show that the second argument is the length. but this was also the case in oe1.6. but maybe just give it a try.


    Thanks dre, it worked with length changing position.


    Openpli 4 :
    dump = "%07d%s" % (len(dump), dump)
    self.appContainer.write(dump)
    OE 2.2:
    ln = len(dump)
    self.appContainer.write(dump, ln)


    Regards.