Giter VIP home page Giter VIP logo

Comments (8)

gtorelly avatar gtorelly commented on May 26, 2024 1

I installed version 1.9.0 and it worked correctly, so I guess it really is a permission issue. Thanks for your help and sorry for the trouble.

from pydebloatx.

Teraskull avatar Teraskull commented on May 26, 2024

Could you please test the latest master branch if there is any difference? I am not able to reproduce the issue.

from pydebloatx.

gtorelly avatar gtorelly commented on May 26, 2024

Ok, the error changed, now I get:

  File "e:\OneDrive\Programas\PyDebloatX\pydebloatx\app.py", line 340, in run 
    names_list = json.loads(names_str)
  File "C:\Users\Guilherme\anaconda3\envs\QWSim\lib\json\__init__.py", line 357, in loads
    return _default_decoder.decode(s)
  File "C:\Users\Guilherme\anaconda3\envs\QWSim\lib\json\decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "C:\Users\Guilherme\anaconda3\envs\QWSim\lib\json\decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)  

So I put print(names_list) in the code, and it printed the following (I removed the lines that list each app, because I think that the problem is in the first line):

. : O arquivo C:\Users\Guilherme\Documents\WindowsPowerShell\profile.ps1 nÆo  
pode ser carregado porque a execu‡Æo de scripts foi desabilitada neste        
sistema. Para obter mais informa‡äes, consulte about_Execution_Policies em    
https://go.microsoft.com/fwlink/?LinkID=135170.
No linha:1 caractere:3
+ . 'C:\Users\Guilherme\Documents\WindowsPowerShell\profile.ps1'
+   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ErrodeSeguran‡a: (:) [], PSSecurityException    
    + FullyQualifiedErrorId : UnauthorizedAccess
[
    {
        "Name":  "Microsoft.NET.Native.Runtime.1.4",
        "InstallLocation":  "C:\\Program Files\\Windo
...
...
        "InstallLocation":  "C:\\Windows\\SystemApps\\Microsoft.Windows.SecureAssessmentBrowser_cw5n1h2txyewy"    
    },
    {
        "Name":  "Microsoft.Windows.SecHealthUI",
        "InstallLo
Traceback (most recent call last):
  File "e:\OneDrive\Programas\PyDebloatX\pydebloatx\app.py", line 341, in run
    names_list = json.loads(names_str)
  File "C:\Users\Guilherme\anaconda3\envs\QWSim\lib\json\__init__.py", line 357, in loads
    return _default_decoder.decode(s)
  File "C:\Users\Guilherme\anaconda3\envs\QWSim\lib\json\decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "C:\Users\Guilherme\anaconda3\envs\QWSim\lib\json\decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

There seems to be an issue with the script execution, because it was "disabled in my system". It can't load a powershell profile and throws an error. Maybe the unicode error is in the symbol "nÆo" which should actually be "não". Beyond that, I think that the "json.loads" was expecting a list without this phrase before, but I'm not sure, never used this function.
Running in an elevated command prompt doesn't help with the issue.

from pydebloatx.

Teraskull avatar Teraskull commented on May 26, 2024

What if you remove the following line from line 338:

universal_newlines=True

And set the line 339 to:

names_str = x.communicate()[0].decode('utf-8', errors='ignore')

from pydebloatx.

gtorelly avatar gtorelly commented on May 26, 2024

I get the same error, but the output of "print(names_str)" doesn't show "nÆo", now it's "no".

from pydebloatx.

space9bug avatar space9bug commented on May 26, 2024

First, you try to run with the packaged installation file to see if there are any exceptions.
If the packaged file works properly, the bug has nothing to do with the code.

Solutions in VS Code:

  1. Running PowerShell in administrator mode
  2. View system execution policy status Get-ExecutionPolicy
  3. Modify execution policy status Set-ExecutionPolicy -ExecutionPolicy RemoteSigned
  4. Finally, close PowerShell and VS Code, and then reopen VS Code

from pydebloatx.

Teraskull avatar Teraskull commented on May 26, 2024

Yea, that might be a permission issue. Most users are not expected to run those commands in Powershell. And without them, we don't have access to the app folders without admin rights.

from pydebloatx.

gtorelly avatar gtorelly commented on May 26, 2024

Ok, I will try the steps proposed by @space9bug .

from pydebloatx.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.