Jump to content

extension modification from 3.2 to 3.4


Recommended Posts

Posted · extension modification from 3.2 to 3.4

good morning. 

i did an important extension for my prusa i3 printer in cura to have a complete set of commands to tune bed level. after upgrading from 3.2 to 3.3 and 3.4 the extension not works. i was able to identify the changings causing the error. 

def _getPrinterOutputDevices(self) -> List[PrinterOutputDevice]:
    return [printer_output_device for printer_output_device in Application.getInstance().getOutputDeviceManager().getOutputDevices() if isinstance(printer_output_device, PrinterOutputDevice)]

in def on old 3.2 cura there was not the  -> List[PrinterOutputDevice]. if i insert it the extension is not loaded at all , if i delete  the extension is loaded. 

what is the meaning ? is it required about you? 

  • Link to post
    Share on other sites

    Posted · extension modification from 3.2 to 3.4

    Without the rest of the code or an understanding of what your plugin does, there is no way we can tell you if that code is required.

  • Link to post
    Share on other sites

    Posted · extension modification from 3.2 to 3.4

    I have too much going on to go hunt for your code in other topics, sorry.

     

    Please have a look at cura.log in your configuration folder. It will tell you if there's a (Pyhton-)error in your code. The file is probably fairly large. You can delete it and Cura will create a new one. Then start Cura and the log will tell you what is going wrong.

     

    Specifically the bit "   -> List[PrinterOutputDevice]  " is called "type hinting"; it tells Python what sort of data to expect. It is optional (but recommended). It could be that Python is having an issue understanding what "PrinterOutputDevice" is; are you importing it?

    from cura.PrinterOutputDevice import PrinterOutputDevice

     

  • Link to post
    Share on other sites

    Posted · extension modification from 3.2 to 3.4

    yes of course is standard in pluging import statements i have 

    from cura.PrinterOutputDevice import PrinterOutputDevice

     the log says that

    2018-08-02 12:44:57,266 - ERROR - [MainThread] UM.Qt.Bindings.PluginsModel._update [61]: BedlevelPlugin is missing a plugin metadata entry

    2018-08-02 12:44:57,347 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [301]: file:///C:/Program Files/Ultimaker Cura 3.4/resources/qml/Topbar.qml:19: TypeError: Cannot read property 'stageId' of null

    2018-08-02 12:44:57,348 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [301]: file:///C:/Program Files/Ultimaker Cura 3.4/resources/qml/Topbar.qml:104: TypeError: Cannot read property 'stageId' of null

    2018-08-02 12:44:57,349 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [301]: file:///C:/Program Files/Ultimaker Cura 3.4/resources/qml/Topbar.qml:175: TypeError: Cannot read property 'stageId' of null

    2018-08-02 12:44:57,350 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [301]: file:///C:/Program Files/Ultimaker Cura 3.4/resources/qml/Cura.qml:433: TypeError: Cannot read property 'mainComponent' of null

    2018-08-02 12:44:57,352 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [301]: file:///C:/Program Files/Ultimaker Cura 3.4/resources/qml/Cura.qml:427: TypeError: Cannot read property 'mainComponent' of null

    2018-08-02 12:44:57,353 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [301]: file:///C:/Program Files/Ultimaker Cura 3.4/resources/qml/Cura.qml:465: TypeError: Cannot read property 'sidebarComponent' of null

    2018-08-02 12:44:57,354 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [301]: file:///C:/Program Files/Ultimaker Cura 3.4/resources/qml/Cura.qml:497: TypeError: Cannot read property 'sidebarComponent' of null

     

    this error disappear if i eliminate -> List[PrinterOutputDevice]:

  • Link to post
    Share on other sites

    Posted · extension modification from 3.2 to 3.4

    last versione works and works fine also in 3.4. thanks for hints

    BedlevelPlugin ok .zip

  • Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now
    • Our picks

      • UltiMaker Cura 5.7 stable released
        Cura 5.7 is here and it brings a handy new workflow improvement when using Thingiverse and Cura together, as well as additional capabilities for Method series printers, and a powerful way of sharing print settings using new printer-agnostic project files! Read on to find out about all of these improvements and more. 
         
          • Like
        • 18 replies
      • S-Line Firmware 8.3.0 was released Nov. 20th on the "Latest" firmware branch.
        (Sorry, was out of office when this released)

        This update is for...
        All UltiMaker S series  
        New features
         
        Temperature status. During print preparation, the temperatures of the print cores and build plate will be shown on the display. This gives a better indication of the progress and remaining wait time. Save log files in paused state. It is now possible to save the printer's log files to USB if the currently active print job is paused. Previously, the Dump logs to USB option was only enabled if the printer was in idle state. Confirm print removal via Digital Factory. If the printer is connected to the Digital Factory, it is now possible to confirm the removal of a previous print job via the Digital Factory interface. This is useful in situations where the build plate is clear, but the operator forgot to select Confirm removal on the printer’s display. Visit this page for more information about this feature.
          • Like
        • 0 replies
    ×
    ×
    • Create New...