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

TypeError: ("'NoneType' object is not iterable", 'occurred at index 13ece079741148e2' #13

Open
haqthat opened this issue Nov 26, 2019 · 0 comments

Comments

@haqthat
Copy link

haqthat commented Nov 26, 2019

Connects to gmail, collects mail metadata, then traceback.

C:\Users\Admin\AppData\Roaming\Python\Python38\Scripts>mail-sanitizer.exe sanitize
Traceback (most recent call last):
  File "c:\users\admin\appdata\local\programs\python\python38-32\lib\runpy.py", line 192, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "c:\users\admin\appdata\local\programs\python\python38-32\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\Scripts\mail-sanitizer.exe\__main__.py", line 9, in <module>
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\mail_sanitizer\main.py", line 33, in main
    cli()
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\click\core.py", line 764, in __call__
    return self.main(*args, **kwargs)
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\click\core.py", line 717, in main
    rv = self.invoke(ctx)
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\click\core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\click\core.py", line 956, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\click\core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\mail_sanitizer\main.py", line 19, in sanitize
    mail_dump_ops = MailDumpOps()
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\mail_sanitizer\mail_dump_ops.py", line 58, in __init__
    self.df['from_sender'] = self.df.apply(MailDumpOps.get_from_sender, axis=1)
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\pandas\core\frame.py", line 6928, in apply
    return op.get_result()
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\pandas\core\apply.py", line 186, in get_result
    return self.apply_standard()
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\pandas\core\apply.py", line 292, in apply_standard
    self.apply_series_generator()
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\pandas\core\apply.py", line 321, in apply_series_generator
    results[i] = self.f(v)
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\mail_sanitizer\mail_dump_ops.py", line 74, in get_from_sender
    return MailDumpOps.get_header_val(row, 'From')
  File "C:\Users\Admin\AppData\Roaming\Python\Python38\site-packages\mail_sanitizer\mail_dump_ops.py", line 88, in get_header_val
    filtered_from_sender = list(filter(lambda x: x['name'] == header_key, headers))
TypeError: ("'NoneType' object is not iterable", 'occurred at index 13ece079741148e2')```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant