Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect work if app started from dir with unicode char in name #44

Closed
jane567 opened this issue May 12, 2016 · 6 comments
Closed

Incorrect work if app started from dir with unicode char in name #44

jane567 opened this issue May 12, 2016 · 6 comments
Labels

Comments

@jane567
Copy link
Contributor

jane567 commented May 12, 2016

Hi Florian!
I found following issue:
if application started from dir with cyrillic chars result of scan is ALWAYS: SYSTEM SEEMS TO BE CLEAN.

BUT
Some errors displayed with --debug option:

Traceback (most recent call last):
  File "loki.py", line 206, in scan_path
    if self.app_path.lower() in filePath.lower():
UnicodeDecodeError: 'ascii' codec can't decode byte 0xeb in position 39: ordinal not in range(128)
Traceback (most recent call last):
  File "loki.py", line 206, in scan_path
    if self.app_path.lower() in filePath.lower():
UnicodeDecodeError: 'ascii' codec can't decode byte 0xeb in position 39: ordinal not in range(128)
Traceback (most recent call last):
  File "loki.py", line 206, in scan_path
    if self.app_path.lower() in filePath.lower():
UnicodeDecodeError: 'ascii' codec can't decode byte 0xeb in position 39: ordinal not in range(128)
...

To reproduce issue:
put loki.py with into dir, for example, c:\локи
then run
python loki.py -p c:\test
and
python loki.py -p c:\test --debug

So in this case we got wrong result of scanning
Thanks

@jane567
Copy link
Contributor Author

jane567 commented May 13, 2016

Add fix for get_application_path()

Neo23x0 added a commit that referenced this issue May 13, 2016
Neo23x0 added a commit that referenced this issue May 16, 2016
@jane567
Copy link
Contributor Author

jane567 commented May 19, 2016

fix not allpied to master

@jane567 jane567 closed this as completed May 19, 2016
@jane567 jane567 reopened this May 19, 2016
@SaiGonSeamus
Copy link

Is this the same issue?

File "loki.py", line 1399, in
loki.scan_path(defaultPath)
File "loki.py", line 172, in scan_path
for root, directories, files in os.walk(unicode(path), onerror=walk_error, followlinks=False):
File "/usr/lib/python2.7/os.py", line 296, in walk
for x in walk(new_path, topdown, onerror, followlinks):
File "/usr/lib/python2.7/os.py", line 296, in walk
for x in walk(new_path, topdown, onerror, followlinks):
File "/usr/lib/python2.7/os.py", line 296, in walk
for x in walk(new_path, topdown, onerror, followlinks):
File "/usr/lib/python2.7/os.py", line 286, in walk
if isdir(join(top, name)):
File "/usr/lib/python2.7/posixpath.py", line 80, in join
path += '/' + b
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 6: ordinal not in range(128)

@jane567
Copy link
Contributor Author

jane567 commented Nov 14, 2016

It seems no

MeteorAdminz pushed a commit to MeteorAdminz/Loki that referenced this issue Dec 15, 2016
MeteorAdminz pushed a commit to MeteorAdminz/Loki that referenced this issue Dec 15, 2016
@Neo23x0 Neo23x0 added the bug label Mar 22, 2018
@Neo23x0
Copy link
Owner

Neo23x0 commented Jun 29, 2018

FYI
The alternative scanner SPARK Core, which shouldn't have this issue, has been released this month
https://www.nextron-systems.com/spark-core/

@Neo23x0
Copy link
Owner

Neo23x0 commented Apr 29, 2021

Shouldn't be a problem anymore with the py3 version or use THOR Lite

@Neo23x0 Neo23x0 closed this as completed Apr 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants