Ignore:
Timestamp:
Feb 17, 2017, 2:22:57 PM (2 years ago)
Author:
Juanma
Message:

WIP on blacklist

Location:
lliurex-store/trunk/fuentes/python3-lliurex-store.install/usr/share/lliurexstore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • lliurex-store/trunk/fuentes/python3-lliurex-store.install/usr/share/lliurexstore/plugins/loadStore.py

    r3646 r3661  
    44gi.require_version('AppStreamGlib', '1.0')
    55from gi.repository import AppStreamGlib as appstream
     6import subprocess
    67
    78class loadstore:
     
    3637        #def execute_action
    3738
    38         def get_error(self)
     39        def get_error(self):
    3940                return (self.error)
    4041
     
    7778                        if not app.get_pkgnames():
    7879                                store.remove_app(app)
     80                #Check the blacklist
     81                flavour=subprocess.check_output(["lliurex-version","-f"]).rstrip()
     82
    7983                return (store)
    8084        #def _sanitize_store
     85
  • lliurex-store/trunk/fuentes/python3-lliurex-store.install/usr/share/lliurexstore/storeManager.py

    r3656 r3661  
    66import pkgutil
    77import lliurexstore.plugins as plugins
     8import json
    89######
    910#Ver. 1.0 of storeManager.py
     
    310311        def get_status(self,action=None):
    311312                self.lock.acquire()
     313
    312314                result={}
    313315                if action in self.result:
    314316                        result=self.result[action]['status']
     317                        errorFile=open('/usr/share/lliurex-store/files/error.json').read()
     318                        errorCodes=json.loads(errorFile)
     319                        result['msg']=errorCodes[str(result['status'])]
    315320                self.lock.release()
    316321                return(result)
Note: See TracChangeset for help on using the changeset viewer.