List support

0 views
Skip to first unread message

ibid

unread,
Jan 23, 2012, 11:07:17 AM1/23/12
to Tyrs
Hi
I'm a new user of tyrs. I like the interface so far.

Last night I started working on adding support for lists. I added a
buffer 'L' and I can pull in a hardcoded list for testing. To make it
usable I just need to add a menu where the user can select the list to
load into the buffer. I think I can bind the 'l' keypress to a menu
with a list of lists.

I hope this can be included upstream when it's finished.

Martin Miller

ibid

unread,
Jan 23, 2012, 5:13:23 PM1/23/12
to Tyrs
I got it working. Looks like 'l' is already bound. I'm using 'a'
instead for no other reason than that the key is available.

Submit via github In presume?

ibid

unread,
Jan 23, 2012, 6:01:07 PM1/23/12
to Tyrs
I started to put my changes into a git fork. I've never used git
before, so let me know if something needs to be done over there.

Mostly done, I noticed two things, possibly related:
1. after the user enters the name of the list to load, the buffer is
not loading right away, but after I hit 'K', it moves directly to that
buffer from the home timeline even though the list buffer is all the
way at the right.

2 I have a line that I more or less copied from the search function,
#self.timelines['list'].empty().

This was causing a crash, so I commented it out. It looks like these
were fixed in the latest git version, but I haven't looked into what
it does.

Anyway, there's enough there that you can get a feel for how it works.
Press 'a', enter a list name, and it will appear in the far right
buffer.

I'll be able to more time in tomorrow evening if there's any interest.

Nicolas Paris

unread,
Jan 24, 2012, 4:12:30 AM1/24/12
to ty...@googlegroups.com
Le Mon, 23 Jan 2012 15:01:07 -0800 (PST),
ibid <martin....@gmail.com> a écrit :

Hi,

First, I'm sorry I couldn't answer earlier, and thank you for your
interest to Tyrs. I'll be pleased to look to you list implementation
and your pull request for sure.

> I've never used git before, so let me know if something needs to be
> done over there.

You should read how to submit a pull request, if you don't already
know, as it simplify everyone life.
http://help.github.com/send-pull-requests/

> It looks like these were fixed in the latest git version,

You really should always works with latest git version (check how to
fetch upstream if there is any changes in the main branch).

> I'll be able to more time in tomorrow evening if there's any interest.

I'm looking forward.

Anyway, there is a guy, Alejandro Gómez, who send me a couple of mails,
he was very interested to implements some new functionalities, such as
lists, follows on hashtags and few other ideas. I don't think it does
started coding, but does read the code. I'm sure it could be an
interesting experience to communicate all together about the code.
Perhaps I should setup a devel mailing list for this kind of talks.

Cheers,
Nicolas

ibid

unread,
Jan 24, 2012, 11:08:32 AM1/24/12
to Tyrs
> You really should always works with latest git version (check how to
> fetch upstream if there is any changes in the main branch).
>
Ya, when I started my git branch this became apparent, so I put
changes
into the latest files. I'll send the pull request when it is ready.
There is one
slight problem I need to fix.

> Anyway, there is a guy, Alejandro Gómez, who send me a couple of mails,
> he was very interested to implements some new functionalities, such as
> lists, follows on hashtags and few other ideas. I don't think it does
> started coding, but does read the code. I'm sure it could be an
> interesting experience to communicate all together about the code.
> Perhaps I should setup a devel mailing list for this kind of talks.

That could be useful. I'd like to help where I can. If there is a more
long term
plan for the UI or other feature support, I would like to hear about
it.

Alejandro Gómez

unread,
Jan 24, 2012, 1:13:59 PM1/24/12
to ty...@googlegroups.com
Is great to hear about being able to follow lists. Currently I'm trying to implement some ideas that I have for making a more flexible UI. I'm opening a new thread for elaborating on that.

Nicolas Paris

unread,
Jan 26, 2012, 10:54:42 AM1/26/12
to ty...@googlegroups.com
Le Tue, 24 Jan 2012 08:08:32 -0800 (PST),
ibid <martin....@gmail.com> a écrit :

> > You really should always works with latest git version (check how to

It has been merged, so it's cool, but there some improvement that could
be done.
More explanation on the pull request:
https://github.com/Nic0/tyrs/pull/124

Cheers ibid :-)
Nicolas

ibid

unread,
Jan 26, 2012, 4:00:14 PM1/26/12
to Tyrs
> Python-twitter module has a
>`List` object that handle lists. I don't know if identica support lists, but it wont
>works as you write the twitter url inside the code.
I remember seeing the List object, but I did not see any method for
retrieving a list, only the metadata. However, looking over it again I
think I see the method I need to use. I think I can fix this pretty
quickly when I get home.

>I'm not sure you are auth during the request, so it won't
>retrieve private lists, but maybe you tried it. I don't use lists in fact.
I can confirm that the current function works for private lists.

>I merged it because it's cool to have a new feature that's working, but I think it
>could be improved.
>
>Thanks ;-)
No problem. Thanks for the merge. I'll work on the improvements and
expand the list features soon. There are some obvious things like add
the highlighted user to a list, or add/remove a specified user to
list.

Nicolas Paris

unread,
Jan 26, 2012, 4:57:33 PM1/26/12
to ty...@googlegroups.com
Le Thu, 26 Jan 2012 13:00:14 -0800 (PST),
ibid <martin....@gmail.com> a écrit :

> > Python-twitter module has a


> >`List` object that handle lists. I don't know if identica support
> >lists, but it wont works as you write the twitter url inside the
> >code.
> I remember seeing the List object, but I did not see any method for
> retrieving a list, only the metadata. However, looking over it again I
> think I see the method I need to use. I think I can fix this pretty
> quickly when I get home.
>

You need to use twitter.Api.GetLists, that retrieves some List
instances. But you certainly figure it out on your own.

> >I'm not sure you are auth during the request, so it won't
> >retrieve private lists, but maybe you tried it. I don't use lists in
> >fact.
> I can confirm that the current function works for private lists.
>

Sweet.

> >I merged it because it's cool to have a new feature that's working,
> >but I think it could be improved.
> >
> >Thanks ;-)
> No problem. Thanks for the merge. I'll work on the improvements and
> expand the list features soon. There are some obvious things like add
> the highlighted user to a list, or add/remove a specified user to
> list.

Awesome, send some pull-requests any time you want :-)

ibid

unread,
Jan 28, 2012, 2:46:43 PM1/28/12
to Tyrs
> You need to use twitter.Api.GetLists, that retrieves some List
> instances. But you certainly figure it out on your own.
The list instance is only the metadata about a list. There isn't a
method to get a Status instance from a list.

I found this issue here about lack of support:
https://code.google.com/p/python-twitter/issues/detail?id=100&sort=-id

There is a patch in the comments that adds a GetListStatuses method.
It's pretty similar to my function, so I combined the two and moved it
to ApiPatch as GetListStatuses. This makes more sense because, like
you said, it uses the private methods of Api. And if this method is
eventually implemented in python-twitter, it will be easy to move to
that.

That issue was last updated 8/2010, so I don't think it's a high
priority for python-twitter devs.

Nicolas Paris

unread,
Feb 1, 2012, 4:17:07 AM2/1/12
to ty...@googlegroups.com
Le Sat, 28 Jan 2012 11:46:43 -0800 (PST),
ibid <martin....@gmail.com> a écrit :

> > You need to use twitter.Api.GetLists, that retrieves some List

I just merged, thanks and sorry for the delay!
There was another function broken, that's why there is an ApiPatch
indeed. So it's nice like that now, thanks a lot.

Reply all
Reply to author
Forward
0 new messages