pythonmodulepys60importerrorn95

Can't import scriptext module in PyS60 2.0 on N95


When I try and import scriptext on PyS60 version 2.0 on my N95 phone, I get an import error saying that there is no module named scriptext.

How can I work out what the problem is?


Solution

  • From: http://pys60.garage.maemo.org/doc/s60/scriptext.html

    Note: The service is available from 'S60 third edition FP2 and later'.

    N95 is a 3rd edition FP1 device.

    You can adapt your app at runtime according to the availability of this module by putting the import in a try..except block:

    try:
        import scriptext
    except ImportError:
        # Module could not be imported, tell the user to update to a newer device
        # or continue without it if having scriptext is not crucial to your app.