Public bug reported:

I recently installed xubuntu 16.04 and i am a beginner in linux. I
noticed when i press the Light Locker settings, the application doesn't
start. Since I am new to this, I tried to search if there were any
solution to the problem, but even after implementing the changes (from
bug155935) there is something wrong in the code and i can't figure it
out. Thats why i thought opening a bug is probably a good idea.

This is the piece from my light-locker-settings.py file (path:
/usr/share/light-locker-settings/light-locker-settings/ ). This file is
also attached to this bug.

def check_running_process(self, process_name):
        """Return True if the specified process is active."""
        # Find the process...
        # for pid in psutil_get_pids():
        for pid in psutill.pids():
            try:
                p = psutil.Process(pid)
                if self.get_process_username(p) == username:
                    # Return True if the process is found.
                    if self.get_process_name(p) == process_name:
                       return True
            except
                pass

        return False


when i type in terminal 
$ light-locker-settings

I get this error
File 
"/usr/share/light-locker-settings/light-locker-settings/light-locker-settings.py",
 line 226
    return True
SyntaxError: 'return' outside function

 I thought after implementing the changes from bug 1559735 this
application would start working.

Please Help.

** Affects: light-locker-settings (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: light-locker-settings

** Attachment added: "the file which runs light-locker app."
   
https://bugs.launchpad.net/bugs/1607152/+attachment/4708386/+files/light-locker-settings.py

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1607152

Title:
  Light locker settings won't start even after bug 1559735
  implementation

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/light-locker-settings/+bug/1607152/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to