pazz / alot Goto Github PK
View Code? Open in Web Editor NEWTerminal-based Mail User Agent
License: GNU General Public License v3.0
Terminal-based Mail User Agent
License: GNU General Public License v3.0
If an attachment has content-type octet/stream and a filename with extention
let mime lib guess its type: http://docs.python.org/library/mimetypes.html
I would love alot to ask for confirmation before terminating the application.
This is true for when pressing 'q' as much as when closing the last buffer.
Try to convert to ascii first and if that fails convert to mime-utf8.
This applies to all header fields and text parts of a mail.
To fold away body parts of messages, define MessageBodyWidget
as urwid.Pile that contains foldable subparts.
Maybe we can subclass urwid.Text to define a FoldableText widget for this.
These should be selectable so that command.ThreadSelect can handle them
alot regularly dies with this stacktrace for me:
$ alot
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in <module>
main()
File "/usr/local/lib/python2.6/dist-packages/alot/init.py", line 90, in main
args.colours,
File "/usr/local/lib/python2.6/dist-packages/alot/ui.py", line 74, in __init__
self.mainloop.run()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 705, in _loop
self._watch_files[fd]()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/usr/local/lib/python2.6/dist-packages/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/usr/local/lib/python2.6/dist-packages/alot/ui.py", line 349, in apply_command
cmd.apply(self)
File "/usr/local/lib/python2.6/dist-packages/alot/command.py", line 90, in apply
sb.unfold_matching(query)
File "/usr/local/lib/python2.6/dist-packages/alot/buffer.py", line 257, in unfold_matching
mw.fold(visible=True)
File "/usr/local/lib/python2.6/dist-packages/alot/widgets.py", line 312, in fold
bw = self._get_body_widget()
File "/usr/local/lib/python2.6/dist-packages/alot/widgets.py", line 281, in _get_body_widget
cols = [MessageBodyWidget(self.message.get_email())]
File "/usr/local/lib/python2.6/dist-packages/alot/widgets.py", line 438, in __init__
bodytxt = message.extract_body(msg)
File "/usr/local/lib/python2.6/dist-packages/alot/message.py", line 188, in extract_body
rendered_payload = helper.cmd_output(cmd)
File "/usr/local/lib/python2.6/dist-packages/alot/helper.py", line 49, in cmd_output
output = subprocess.check_output(args)
AttributeError: 'module' object has no attribute 'check_output'
$
I am uncertain whether this is unique to my setup.
print_cmd defaults to muttprint, so not setting it and not having muttprint installed
will result in a red error notification.
move mainwidget to overlay bg, promptedit as overlay foreground,
that way apparently the prompt gets all keypresses.
this would make the ugly while-true loop obsolete
http://excess.org/urwid/reference.html#AttrSpec
for colours see/run palette_test.py from http://excess.org/urwid/browser/palette_test.py
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in
main()
File "/usr/local/lib/python2.7/dist-packages/alot/init.py", line 95, in main
args.colours,
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 75, in init
self.mainloop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 705, in _loop
self._watch_filesfd
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 185, in cb
rval = callback(data)
File "/usr/local/lib/python2.7/dist-packages/alot/command.py", line 163, in afterwards
self.on_success()
File "/usr/local/lib/python2.7/dist-packages/alot/command.py", line 766, in openEnvelopeFromTmpfile
key, value = line.strip().split(':', 1)
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in
main()
File "/usr/local/lib/python2.7/dist-packages/alot/init.py", line 90, in main
args.colours,
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 74, in init
self.mainloop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 696, in _loop
self._entering_idle()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 617, in _entering_idle
callback()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 482, in entering_idle
self.draw_screen()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 493, in draw_screen
canvas = self._topmost_widget.render(self.screen_size, focus=True)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/container.py", line 586, in render
focus and self.focus_part == 'body')
File "/usr/local/lib/python2.7/dist-packages/alot/buffer.py", line 41, in render
return self.body.render(size, focus)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/listbox.py", line 328, in render
(maxcol, maxrow), focus=focus)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/listbox.py", line 216, in calculate_visible
self._set_focus_complete( (maxcol, maxrow), focus )
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/listbox.py", line 495, in _set_focus_complete
(maxcol,maxrow), focus)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/listbox.py", line 465, in _set_focus_first_selectable
(maxcol, maxrow), focus=focus)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/listbox.py", line 276, in calculate_visible
next, pos = self.body.get_next( pos )
File "/usr/local/lib/python2.7/dist-packages/alot/walker.py", line 41, in get_next
return self._get_at_pos(start_from + 1)
File "/usr/local/lib/python2.7/dist-packages/alot/walker.py", line 63, in _get_at_pos
widget = self._get_next_item()
File "/usr/local/lib/python2.7/dist-packages/alot/walker.py", line 72, in _get_next_item
next_widget = self.containerclass(next_obj, **self.kwargs)
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 35, in init
self.rebuild()
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 41, in rebuild
datestring = pretty_datetime(self.thread.get_newest_date()).rjust(10)
AttributeError: 'NoneType' object has no attribute 'get_newest_date'
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in
main()
File "/usr/local/lib/python2.7/dist-packages/alot/init.py", line 95, in main
args.colours,
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 75, in init
self.mainloop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 705, in _loop
self._watch_filesfd
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 384, in apply_command
cmd.apply(self)
File "/usr/local/lib/python2.7/dist-packages/alot/command.py", line 89, in apply
sb.unfold_matching(query)
File "/usr/local/lib/python2.7/dist-packages/alot/buffer.py", line 256, in unfold_matching
mw.fold(visible=True)
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 332, in fold
aw = self._get_attachment_widget()
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 288, in _get_attachment_widget
cols = [AttachmentWidget(a)]
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 469, in init
widget = urwid.AttrMap(urwid.Text(unicode(self.attachment)),
File "/usr/local/lib/python2.7/dist-packages/alot/message.py", line 294, in str
self.get_filename(),
File "/usr/local/lib/python2.7/dist-packages/alot/message.py", line 299, in get_filename
return os.path.basename(self.part.get_filename())
File "/usr/lib/python2.7/posixpath.py", line 112, in basename
i = p.rfind('/') + 1
AttributeError: 'NoneType' object has no attribute 'rfind'
I'd very much like the thread view to be column based, so that the (equally spaced (cf issue #17)) dates are nicely aligned to the right of the window.
cf Thunderbird's layout for reference.
I'd like to have those tags displayed with every mail that are 'non-defining' for that thread, where 'defining' tags are those that are attached to every mail in that thread. E.g.:
[inbox alot issues] sent dtk
[inbox alot issues] |_ pazz
[inbox alot issues] replied |_ bruce lee
[inbox alot issues] sent |_ dtk
with the defining tags being put in brackets and only the other one's to be displayed
I want my flagged threads to show up on orange background, my deleted one's on red, unread in blue,bold, ... u catch my drift. alot ;P
the default colours work well in my white-on-black terminal windows
but should be OK on bright terms as well.
Alternatively, provide a nicer looking theme for BoW terms
I started with a fresh setup with the latest notmuch & alot, and now I'm getting this exception.
Traceback (most recent call last):
File "bin/alot", line 20, in <module>
main()
File "/home/lmacken/code/github.org/alot/alot/init.py", line 95, in main
args.colours,
File "/home/lmacken/code/github.org/alot/alot/ui.py", line 75, in __init__
self.mainloop.run()
File "/usr/lib64/python2.7/site-packages/urwid/main_loop.py", line 169, in run
self.screen.run_wrapper(self._run)
File "/usr/lib64/python2.7/site-packages/urwid/raw_display.py", line 233, in run_wrapper
return fn()
File "/usr/lib64/python2.7/site-packages/urwid/main_loop.py", line 180, in _run
self.draw_screen()
File "/usr/lib64/python2.7/site-packages/urwid/main_loop.py", line 360, in draw_screen
canvas = self.widget.render(self.screen_size, focus=True)
File "/usr/lib64/python2.7/site-packages/urwid/widget.py", line 134, in cached_render
canv = fn(self, size, focus=focus)
File "/usr/lib64/python2.7/site-packages/urwid/container.py", line 568, in render
focus and self.focus_part == 'body')
File "/home/lmacken/code/github.org/alot/alot/buffer.py", line 41, in render
return self.body.render(size, focus)
File "/usr/lib64/python2.7/site-packages/urwid/widget.py", line 134, in cached_render
canv = fn(self, size, focus=focus)
File "/usr/lib64/python2.7/site-packages/urwid/listbox.py", line 327, in render
(maxcol, maxrow), focus=focus)
File "/usr/lib64/python2.7/site-packages/urwid/listbox.py", line 214, in calculate_visible
self._set_focus_complete( (maxcol, maxrow), focus )
File "/usr/lib64/python2.7/site-packages/urwid/listbox.py", line 475, in _set_focus_complete
(maxcol,maxrow), focus)
File "/usr/lib64/python2.7/site-packages/urwid/listbox.py", line 445, in _set_focus_first_selectable
(maxcol, maxrow), focus=focus)
File "/usr/lib64/python2.7/site-packages/urwid/listbox.py", line 217, in calculate_visible
focus_widget, focus_pos = self.body.get_focus()
File "/home/lmacken/code/github.org/alot/alot/walker.py", line 34, in get_focus
return self._get_at_pos(self.focus)
File "/home/lmacken/code/github.org/alot/alot/walker.py", line 63, in _get_at_pos
widget = self._get_next_item()
File "/home/lmacken/code/github.org/alot/alot/walker.py", line 72, in _get_next_item
next_widget = self.containerclass(next_obj, **self.kwargs)
File "/home/lmacken/code/github.org/alot/alot/widgets.py", line 37, in __init__
self.rebuild()
File "/home/lmacken/code/github.org/alot/alot/widgets.py", line 44, in rebuild
newest = self.thread.get_newest_date()
AttributeError: 'NoneType' object has no attribute 'get_newest_date'
should be done nicer:
The current master doesn't fill up the rest of a line in a search (e.g. inbox) with the beginning of the mail body. Which I like a lot -.-
The current develop does, though, going sup style. Is there a way to restore the previous behaviour? I find sup's layout highly unclear und like mutt's much better.
thx ;)
Thread already has this parameter for remove_tags and add_tags methods.
The fact that message doesn't but we use msg.remove_tag('unread') when opening messages
lead to unsynced maildir flags..
We should read the corresponding setting from ~/.notmuchrc
needs fumbling around with github-tools because github pages don't like sphinx's _static folder,
see http://pazz.github.com/alot/
doc gen is as easy as cd docs; make html
http://dinoboff.github.com/github-tools/overview.html#usage
cant install on ubuntu
easy_install github-tools
Searching for github-tools
Best match: github-tools 0.2rc1
Processing github_tools-0.2rc1-py2.7.egg
github-tools 0.2rc1 is already the active version in easy-install.pth
Using /usr/local/lib/python2.7/dist-packages/github_tools-0.2rc1-py2.7.egg
Processing dependencies for github-tools
Searching for GitPython==0.1.6
Reading http://pypi.python.org/simple/GitPython/
Reading http://gitorious.org/projects/git-python/
Reading https://github.com/gitpython-developers
No local packages or download links found for GitPython==0.1.6
error: Could not find suitable distribution for Requirement.parse('GitPython==0.1.6')
Traceback (most recent call last):
File "/home/lmacken/code/github.org/alot/env/bin/alot", line 20, in <module>
main()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/init.py", line 90, in main
args.colours,
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/ui.py", line 74, in __init__
self.mainloop.run()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 282, in _run
self.draw_screen()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 493, in draw_screen
canvas = self._topmost_widget.render(self.screen_size, focus=True)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/container.py", line 586, in render
focus and self.focus_part == 'body')
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/buffer.py", line 41, in render
return self.body.render(size, focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/listbox.py", line 358, in render
canvas = widget.render((maxcol,))
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/widgets.py", line 89, in render
return urwid.AttrMap.render(self, size, focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/decoration.py", line 208, in render
canv = self._original_widget.render(size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/container.py", line 1218, in render
focus = focus and self.focus_col == i)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/decoration.py", line 208, in render
canv = self._original_widget.render(size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 131, in cached_render
canv = fn(self, size, focus=focus)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/widget.py", line 622, in render
return apply_text_layout(text, attr, trans, maxcol)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/canvas.py", line 1249, in apply_text_layout
s = LayoutSegment(seg)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/text_layout.py", line 259, in __init__
assert self.sc > 0, repr(seg)
AssertionError: (0, 0, 0)
hit m, choose account (enter) not To: is displayed. Hit esc to cancel and:
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in
main()
File "/usr/local/lib/python2.7/dist-packages/alot/init.py", line 95, in main
args.colours,
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 74, in init
self.mainloop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 705, in _loop
self._watch_filesfd
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 349, in apply_command
cmd.apply(self)
File "/usr/local/lib/python2.7/dist-packages/alot/command.py", line 381, in apply
self.mail['To'] = encode_header('to', to)
File "/usr/local/lib/python2.7/dist-packages/alot/message.py", line 245, in encode_header
rawentries = value.split(',')
AttributeError: 'NoneType' object has no attribute 'split'
attach keymap in envelopes
could be done more elegantly by simply mapping a to prompt attach
make the timestamp in the thread view more detailed, e.g. as in
18.08.2011 02:22
Traceback (most recent call last):
File "./alot/init.py", line 99, in
main()
File "./alot/init.py", line 95, in main
args.colours,
File "/home/pazz/projects/alot/alot/ui.py", line 75, in init
self.mainloop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 705, in _loop
self._watch_filesfd
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-i686.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/home/pazz/projects/alot/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/home/pazz/projects/alot/alot/ui.py", line 384, in apply_command
cmd.apply(self)
File "/home/pazz/projects/alot/alot/command.py", line 503, in apply
in_to = [a for a in my_addresses if a in mail['To']]
TypeError: argument of type 'NoneType' is not iterable
account.SendmailAccount.send and the PrintCommand
basically do the same thing: opening pipes to an external process and
print mails to it. This should be put into alot.helper and and both should just
use it.
This would make piping mails/threads to arbitrary command easy:
maybe add a threadview mapping
| = prompt for shellcommand and pipe selected mail to it.
this makes the start of the tags wiggle (and drives me further from my ultimate goal of having everything locked away in columns evil laugh ;)) seriously though, I think having a column like look here should improve readability; and aligning num_mails should be possible without wasting too much screen space.
When EnvelopeSendCommand sends a mail,
it and the account has a sent_box, it will save the mail to this mbox.
Only after the next notmuch new is triggered will this mail be visible in searches.
It should be added to the index right after it gets saved.
before starting to hack on the larger issues, release a 0.11 version
that merges develop to master.
restructured text?
python-keyczar seems nice, alternatively python-gnupg
One ove the issues would be retrievng passphrases from gpg-agent and alternatively
prompt via the urwid ui and not via readline
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in
main()
File "/usr/local/lib/python2.7/dist-packages/alot/init.py", line 95, in main
args.colours,
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 75, in init
self.mainloop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 705, in _loop
self._watch_filesfd
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 384, in apply_command
cmd.apply(self)
File "/usr/local/lib/python2.7/dist-packages/alot/command.py", line 89, in apply
sb.unfold_matching(query)
File "/usr/local/lib/python2.7/dist-packages/alot/buffer.py", line 255, in unfold_matching
mw.fold(visible=True)
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 334, in fold
bw = self._get_body_widget()
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 303, in _get_body_widget
cols = [MessageBodyWidget(self.message.get_email())]
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 460, in init
bodytxt = message.extract_body(msg)
File "/usr/local/lib/python2.7/dist-packages/alot/message.py", line 187, in extract_body
raw_payload = unicode(raw_payload, enc)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xa8 in position 230: ordinal not in range(128)
call a hook when ui.notify() is triggered.
This could be used to trigger libnotify popups.
The hook should get all the parameters notify received: message, timeout, priority.
Maybe it's a good idea to additionally hand over the 4 standard hook arguments: ui, dbm, accountman, config
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in
main()
File "/usr/local/lib/python2.7/dist-packages/alot/init.py", line 95, in main
args.colours,
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 75, in init
self.mainloop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 705, in _loop
self._watch_filesfd
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/usr/local/lib/python2.7/dist-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 384, in apply_command
cmd.apply(self)
File "/usr/local/lib/python2.7/dist-packages/alot/command.py", line 383, in apply
completer=ContactsCompleter(ui.accountman))
File "/usr/local/lib/python2.7/dist-packages/alot/ui.py", line 144, in prompt
editpart.keypress(size, key)
File "/usr/local/lib/python2.7/dist-packages/alot/widgets.py", line 185, in keypress
self.completer.complete(self.edit_text, self.edit_pos)
File "/usr/local/lib/python2.7/dist-packages/alot/completion.py", line 127, in complete
res = res + abook.lookup(prefix)
File "/usr/local/lib/python2.7/dist-packages/alot/account.py", line 300, in lookup
lines = lines.replace('\t', ' ' * 4).splitlines()
AttributeError: 'NoneType' object has no attribute 'replace'
fill unused line space with message body content as sup does.
This should only require to change widgets.ThreadlineWidget
just as for prompt..
I get the following traceback when trying to reply to a mail from someone with a non-ascii name.
Traceback (most recent call last):
File "/home/lmacken/code/github.org/alot/env/bin/alot", line 20, in <module>
main()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/init.py", line 90, in main
args.colours,
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/ui.py", line 74, in __init__
self.mainloop.run()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 705, in _loop
self._watch_files[fd]()
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/urwid-1.0.0-py2.7-linux-x86_64.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/ui.py", line 349, in apply_command
cmd.apply(self)
File "/home/lmacken/code/github.org/alot/env/lib/python2.7/site-packages/alot/command.py", line 481, in apply
mailcontent += '>' + line + '\n'
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc5 in position 17: ordinal not in range(128)
alot dies reproducibly when trying to open a certain thread.
$ alot
Traceback (most recent call last):
File "/usr/local/bin/alot", line 20, in <module>
main()
File "/usr/local/lib/python2.6/dist-packages/alot/init.py", line 90, in main
args.colours,
File "/usr/local/lib/python2.6/dist-packages/alot/ui.py", line 74, in __init__
self.mainloop.run()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 271, in run
self.screen.run_wrapper(self._run)
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/raw_display.py", line 228, in run_wrapper
return fn()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 292, in _run
self.event_loop.run()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 667, in run
self._loop()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 705, in _loop
self._watch_files[fd]()
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 343, in _update
self.process_input(keys)
File "/usr/local/lib/python2.6/dist-packages/urwid-1.0.0-py2.6-linux-i686.egg/urwid/main_loop.py", line 432, in process_input
k = self._topmost_widget.keypress(self.screen_size, k)
File "/usr/local/lib/python2.6/dist-packages/alot/ui.py", line 42, in keypress
self.ui.apply_command(cmd)
File "/usr/local/lib/python2.6/dist-packages/alot/ui.py", line 349, in apply_command
cmd.apply(self)
File "/usr/local/lib/python2.6/dist-packages/alot/command.py", line 88, in apply
sb = buffer.ThreadBuffer(ui, self.thread)
File "/usr/local/lib/python2.6/dist-packages/alot/buffer.py", line 192, in __init__
self.rebuild()
File "/usr/local/lib/python2.6/dist-packages/alot/buffer.py", line 232, in rebuild
bars_at=bars)
File "/usr/local/lib/python2.6/dist-packages/alot/widgets.py", line 213, in __init__
self.sumline = self._build_sum_line()
File "/usr/local/lib/python2.6/dist-packages/alot/widgets.py", line 235, in _build_sum_line
self.sumw = MessageSummaryWidget(self.message, even=self.even)
File "/usr/local/lib/python2.6/dist-packages/alot/widgets.py", line 361, in __init__
sumstr = self.__str__()
File "/usr/local/lib/python2.6/dist-packages/alot/widgets.py", line 366, in __str__
return self.message.__str__()
File "/usr/local/lib/python2.6/dist-packages/alot/message.py", line 58, in __str__
return "%s (%s)" % (aname, self.get_datestring())
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 1: ordinal not in range(128)
Please let me know if you need further, more specific information on the mails.
it seems that only the widgets are redrawn according to a non-updated thread object.
self.thread.update() ?
pro:
contra:
this needs a rewrite of how command objects are created:
instead of the commandfactory, ui should have an instance of a Cmd2.Cmd subclass
that defines do_X for all alot.Command subclasses that just creates an object of that class.
help_x should print that alot.Command's docstring?
like in TagsCompleter
arrows up/down should browse through a history of recently typed commands.
This can be done either by making the custom edit-widget a bit smarter and reusing
the same widget all the time. Alternatively one can store the history in ui itself
and capture keystrokes in ui.prompt accordingly. The first solution is probably cleaner.
e.g.:
${num_mails_in_thread} ${subject} ${from} ${tags} ${timestamp}
or maybe make the search view column based as well (cf issue #18) and make the order of the columns configurable?
The USAGE file states
[global-maps]
[...]
x = bclose
[bufferlist-maps]
d = closefocussed
For me 'd' seems do close the current buffer while 'x' seems to close the selected buffer while in the bufferlist buffer.
I am rather uncertain, though, whether this is really an error in the documentation, since the documented behaviour might be the more desirable one.
One way would be adding a header line like mutt does.
Another is to have a overlay popup that displays a table
keybinding | cmdline | description.
How do we get the descriptions for user-added maps? Where do we put the descriptions for the default
bindings?
This could be done with an additional (optional) line in the X-maps sections of the config:
for a mapping line, e.g.
t = toggletag TODO
the line
t_help = toggles TODO tag
will be automatically interpreted as help string.
I'd like to be able to specify a set of tags that I don't want to appear in that list that shows all the tags that appear with any mail in the thread.
I apply a 'sent' tag to the mails in the 'sent' maildir directory. That feels pretty intuitive to me and makes for easy searching for the mails oneself sent. If searching for the inbox tag, though, the sent tag always appears in combination with the replied tag - which makes displaying it rather a waste of screen estate.
Additionally, I might spend considerable time in the view of the safed search for the inbox tag (yes, in my inbox; I'm sorry -.-). It might be superfluous to display the inbox tag in that search in every line.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.