From duane.johnson at gmail.com Tue Jun 7 12:27:02 2005 From: duane.johnson at gmail.com (Duane Johnson) Date: Tue Jun 7 12:29:33 2005 Subject: [RPS] How's the group? In-Reply-To: <6fd0654b050524094848b5535f@mail.gmail.com> References: <6fd0654b050503084847680518@mail.gmail.com> <58E1A129-B53C-4EE1-BA6E-ABD18EEC9EF8@gmail.com> <6fd0654b050524094848b5535f@mail.gmail.com> Message-ID: <6672E5CB-DF29-4181-9A55-4E01B8E4F6FC@gmail.com> Hey all, Just wanted to send an e-mail to make sure people are still around :) Our company's project is finally at a stage where we can implement the payment gateway, so I can begin working on that as a piece of the project. Looking at the svn log, it doesn't appear that any commits have been made. Did some of those tests posted earlier make it in to the payment project? Duane From pat.eyler at gmail.com Tue Jun 7 13:17:16 2005 From: pat.eyler at gmail.com (pat eyler) Date: Tue Jun 7 13:13:35 2005 Subject: [RPS] How's the group? In-Reply-To: <6672E5CB-DF29-4181-9A55-4E01B8E4F6FC@gmail.com> References: <6fd0654b050503084847680518@mail.gmail.com> <58E1A129-B53C-4EE1-BA6E-ABD18EEC9EF8@gmail.com> <6fd0654b050524094848b5535f@mail.gmail.com> <6672E5CB-DF29-4181-9A55-4E01B8E4F6FC@gmail.com> Message-ID: <6fd0654b05060710174cbc21c4@mail.gmail.com> So far, things are bogged down. I've been offered a new job, and am in the middle of changing jobs and moving whic is taking much more of my time than I thought it would, and Lucas has been busy with RailsDay (and other stuff). I'd like to see some activity (including your new development), but I'm not sure how much we'll get done until the end of June. -pate On 6/7/05, Duane Johnson wrote: > Hey all, > > Just wanted to send an e-mail to make sure people are still > around :) Our company's project is finally at a stage where we can > implement the payment gateway, so I can begin working on that as a > piece of the project. Looking at the svn log, it doesn't appear that > any commits have been made. Did some of those tests posted earlier > make it in to the payment project? > > Duane > _______________________________________________ > Therps-discuss mailing list > Therps-discuss@rubyforge.org > http://rubyforge.org/mailman/listinfo/therps-discuss > -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From rps-ml at magical-cat.org Tue Jun 7 13:23:53 2005 From: rps-ml at magical-cat.org (ES) Date: Tue Jun 7 13:19:44 2005 Subject: [RPS] How's the group? In-Reply-To: <6672E5CB-DF29-4181-9A55-4E01B8E4F6FC@gmail.com> Message-ID: <358DkRXF.1118165033.3942850.ruerue@bidwell.textdrive.com> Le 7/6/2005, "Duane Johnson" a ?crit: >Hey all, > >Just wanted to send an e-mail to make sure people are still >around :) Our company's project is finally at a stage where we can >implement the payment gateway, so I can begin working on that as a >piece of the project. Looking at the svn log, it doesn't appear that >any commits have been made. Did some of those tests posted earlier >make it in to the payment project? I am trying to manage a DB2 -> Oracle transition :/ Hopefully done sometime soon. >Duane E From duane.johnson at gmail.com Tue Jun 7 18:42:50 2005 From: duane.johnson at gmail.com (Duane Johnson) Date: Tue Jun 7 18:38:40 2005 Subject: [RPS] some issues i've run into In-Reply-To: <42770C26.9090203@lagcisco.com> References: <42770C26.9090203@lagcisco.com> Message-ID: <9B27C3BD-EEF3-429E-9DC4-BA8D63F31746@gmail.com> > just saw the announcement on the rails list about the payment library > today, I just recently got the library to work, had some issues with > these lines: > @cvv2_response = col[38].data > @cavv_response = col[39].data > > because elements 38 and 39 were nil, I simply commented these out > > also the FIELDS hash has 2 keys named 'type' (both of which I > commented > out and use the default functionality that authorize.net uses) I've worked on this issue a bit too... however, I wonder which of the two type fields should be something else? 'type' => 'x_Method' 'type' => 'x_Type' Also defined is the ACTIONS array: ACTIONS = { 'normal authorization' => 'AUTH_CAPTURE', 'authorization only' => 'AUTH_ONLY', 'credit' => 'CREDIT', 'post authorization' => 'PRIOR_AUTH_CAPTURE', 'void' => 'VOID', } Later, in the prepare_data method, we have: @type = (@type.nil? && @card_number) ? 'CC' : @type.upcase # convert the action if ACTIONS.include?(@action) @action = ACTIONS[@action] elsif ! ACTIONS.has_value?(@action) raise PaymentError, "The action '#{@action}' is not valid" end As far as I can tell from the authorize.net docs, x_Type can be one of %w(AUTH_CAPTURE AUTH_ONLY CAPTURE_ONLY CREDIT VOID PRIOR_AUTH_CAPTURE), which is exactly what the ACTIONS hash's values are. Also, x_Method can be either 'CC' or 'ECHECK'. So it seems to me that @action corresponds with x_Type and @type corresponds with x_Method. Is there a reason for this misnomer? I would rather see @type correspond with x_Type and @method correspond with x_Method. Duane Johnson (canadaduane) -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/therps-discuss/attachments/20050607/9d6bb91c/attachment.htm From duane.johnson at gmail.com Wed Jun 8 15:20:40 2005 From: duane.johnson at gmail.com (Duane Johnson) Date: Wed Jun 8 15:16:35 2005 Subject: [RPS] Why is prepare_data not called within submit? Message-ID: <1A973AC6-0321-4FF8-A23F-7A1EC1C35C4D@gmail.com> I've noticed that to perform an Authorize.net credit card transaction, three things need to occur: 1. Create a new Payment::AuthorizeNet object 2. Call #prepare_data on that object 3. Call #submit on that object Why do we have step #2? Duane Johnson (canadaduane) From pat.eyler at gmail.com Mon Jun 20 10:22:51 2005 From: pat.eyler at gmail.com (pat eyler) Date: Mon Jun 20 10:18:21 2005 Subject: [RPS] a fresh start for July and August Message-ID: <6fd0654b05062007223629ed5e@mail.gmail.com> I'm sad to see that we didn't make it too far with Payment over the last two months. I'd like to try a new project for July and August. Rather than trying to make a big splash, let's try to focus on a smaller library and get our process worked out. I think we could fix up r43 (my 43 things wrapper) pretty quickly. There are already some test, and there are a number of well defined tasks that can be done with it. If we finish it up early (we could probably finish it off in July if we wanted to) we could grab another library like the upcoming API wrapper, and do the same thing. Getting a quick easy win or two like this could really help us build the kind of momentum we'd need to take on another (bigger) package. It would also give us a nice sandbox to play in while we get used to a Ruby Programming Shop kind of development. If we're in general agreement, I can add people to the r43 project on RubyForge, and we can start work in July. Between now and then, I'd like to; put our coding/committing standards onto the wiki, get another release of r43 done (just some reorganization and cleanup), and get the r43 tasklist onto the therps wiki. What do you guys think? -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From seanacarley at gmail.com Mon Jun 20 10:31:30 2005 From: seanacarley at gmail.com (Sean Carley) Date: Mon Jun 20 10:26:57 2005 Subject: [RPS] a fresh start for July and August In-Reply-To: <6fd0654b05062007223629ed5e@mail.gmail.com> References: <6fd0654b05062007223629ed5e@mail.gmail.com> Message-ID: <9e272eff0506200731371e0e67@mail.gmail.com> I agree we have had troubles out of the gate. I am willing to work on r43 in the interest of working out our kinks. My user id on rubyforge is milythael. Sean From chris at seagul.co.uk Wed Jun 22 07:53:04 2005 From: chris at seagul.co.uk (Chris Roos) Date: Wed Jun 22 07:48:47 2005 Subject: [RPS] a fresh start for July and August In-Reply-To: <6fd0654b05062007223629ed5e@mail.gmail.com> References: <6fd0654b05062007223629ed5e@mail.gmail.com> Message-ID: <42B95120.1010405@seagul.co.uk> pat eyler wrote: > I'm sad to see that we didn't make it too far with Payment over the last two > months. I'd like to try a new project for July and August. Rather than > trying to make a big splash, let's try to focus on a smaller library and get > our process worked out. I think we could fix up r43 (my 43 things wrapper) > pretty quickly. There are already some test, and there are a number of well > defined tasks that can be done with it. > > If we finish it up early (we could probably finish it off in July if we wanted > to) we could grab another library like the upcoming API wrapper, and do the > same thing. Getting a quick easy win or two like this could really help us > build the kind of momentum we'd need to take on another (bigger) package. It > would also give us a nice sandbox to play in while we get used to a Ruby > Programming Shop kind of development. > > If we're in general agreement, I can add people to the r43 project on > RubyForge, and we can start work in July. Between now and then, I'd like to; > put our coding/committing standards onto the wiki, get another release of r43 > done (just some reorganization and cleanup), and get the r43 tasklist onto the > therps wiki. > > What do you guys think? I'm still very interested in being part of this group but got kinda lost as to where everything was going for the payment project and so just sat back a bit. Being new to Ruby and working in this kind of collaborative process, I think I maybe needed more guidance. In summary. I'm still here, want to help and agree that the r43 project is probably a good start. I will however, require a little hand holding / prompting to start with. Chris From pat.eyler at gmail.com Wed Jun 22 10:20:23 2005 From: pat.eyler at gmail.com (pat eyler) Date: Wed Jun 22 10:15:49 2005 Subject: [RPS] r43 Message-ID: <6fd0654b05062207202c2ecf53@mail.gmail.com> I'm going to cut a 0.1.3 release of r43 this Friday. It will include at least a cleanup of the directory structure, gemification, and separating out the DATA segment from the tests (that's all done). I'm not sure what (if anything) I'll get done beyond this. -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From seanacarley at gmail.com Tue Jun 28 14:41:58 2005 From: seanacarley at gmail.com (Sean Carley) Date: Tue Jun 28 14:37:11 2005 Subject: [RPS] a fresh start for July and August In-Reply-To: <6fd0654b05062007223629ed5e@mail.gmail.com> References: <6fd0654b05062007223629ed5e@mail.gmail.com> Message-ID: <9e272eff0506281141265aae76@mail.gmail.com> Pat, You said you had some well defined tasks for r43. Have you had a chance to get them down in writing so we have an idea what there is to be done? I am eagerly awaiting whatever work I can get right now. Sean Carley From seanacarley at gmail.com Tue Jun 28 14:48:37 2005 From: seanacarley at gmail.com (Sean Carley) Date: Tue Jun 28 14:43:49 2005 Subject: [RPS] Co-Mentorship In-Reply-To: <9e272eff05052306473a9a2db0@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> Message-ID: <9e272eff050628114878dfc9ff@mail.gmail.com> We seem to have more people looking for mentors than we have mentors to guide them. I would still like to work with someone to improve my Ruby and my collaborative development skills. I propose to pair with someone else still seeking a mentor and we can bootstrap ourselves together. If you are interested in co-mentoring each other, please send me a message. I am sure we all have something to learn from each other. Sean Carley From pat.eyler at gmail.com Tue Jun 28 15:05:05 2005 From: pat.eyler at gmail.com (pat eyler) Date: Tue Jun 28 15:00:19 2005 Subject: [RPS] a fresh start for July and August In-Reply-To: <9e272eff0506281141265aae76@mail.gmail.com> References: <6fd0654b05062007223629ed5e@mail.gmail.com> <9e272eff0506281141265aae76@mail.gmail.com> Message-ID: <6fd0654b050628120517019877@mail.gmail.com> On 6/28/05, Sean Carley wrote: > Pat, > > You said you had some well defined tasks for r43. Have you had a > chance to get them down in writing so we have an idea what there is to > be done? A first cut at tasks are: create and document the Response object (I still need to document this -- maybe today on my bus ride home) write a script to build the FakeR43 datafile clean up existing functions to reflect newer API finish the Goal object finsih the Person object finish the City object finish the Team object finish the Comment object all of these can be fleshed out based on the API docs that live at: http://www.43things.com/about/view/web_service_api write the Posting methods write/cleanup docs write some example scripts write a Rakefile to test, rebuild FakeR43 datafile, install, and build release tarballs > > I am eagerly awaiting whatever work I can get right now. > If you want to get started before July, you could work on cleaning up the Person object and associated methods to reflect the newer API. It should be pretty quick work. The tests will need to be updated too. If you'd like to do any of these, you can send diffs/questions to the list for discussion. Once they've been reviewed, we can get them committed to the tree. > Sean Carley > > _______________________________________________ > Therps-discuss mailing list > Therps-discuss@rubyforge.org > http://rubyforge.org/mailman/listinfo/therps-discuss > -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From pat.eyler at gmail.com Tue Jun 28 15:08:37 2005 From: pat.eyler at gmail.com (pat eyler) Date: Tue Jun 28 15:03:48 2005 Subject: [RPS] Co-Mentorship In-Reply-To: <9e272eff050628114878dfc9ff@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> Message-ID: <6fd0654b05062812087d8cebf2@mail.gmail.com> Sean, If you can't find someone else, I'd be happy to work with you. It'll have to be pretty asyncronous though since I don't have many big blocks of time right now. Things I can do: answer questions about r43 or Ruby, review code, help write tests, help write code, provide moral support, help w/ debugging. On 6/28/05, Sean Carley wrote: > We seem to have more people looking for mentors than we have mentors > to guide them. I would still like to work with someone to improve my > Ruby and my collaborative development skills. I propose to pair with > someone else still seeking a mentor and we can bootstrap ourselves > together. If you are interested in co-mentoring each other, please > send me a message. I am sure we all have something to learn from each > other. > > Sean Carley > > _______________________________________________ > Therps-discuss mailing list > Therps-discuss@rubyforge.org > http://rubyforge.org/mailman/listinfo/therps-discuss > -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From seanacarley at gmail.com Tue Jun 28 21:04:04 2005 From: seanacarley at gmail.com (Sean Carley) Date: Tue Jun 28 20:59:16 2005 Subject: [RPS] First Attempts at Usefulness - r43 In-Reply-To: <6fd0654b05062812087d8cebf2@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> <6fd0654b05062812087d8cebf2@mail.gmail.com> Message-ID: <9e272eff05062818042fa0b05e@mail.gmail.com> My biggest challenges are in the area of collaborative development. For example, I have downloaded the r43.0.1.1.tgz and I have used cvs to grab the source module anonymously. I started making changes to the version from the .tgz file. Now, how do I create a diff file (patch file?) that is useful to other people on the list? I have learned that I need to use diff in bash under cygwin (I am running Windows 2003) because under the command shell it always decides the complete contents of the file is different. I currently have the following directory structures on my machine under the projects folder: therps/r43/r43.0.1.1 - contents of r43.0.1.1.tgz therps/r43/source - contents of cvs co source Under these folders, I have the following files: therps/r43/r43.0.1.1/r43.rb - original from .tgz with my changes therps/r43/source/lib/r43.rb - original from cvs (Tuesday Evening) I am using the following diff command: diff -Naur source/lib/r43.rb r43.0.1.1/r43.rb And I get the following results: ********************** BEGIN PATCH ********************** --- source/lib/r43.rb 2005-06-22 09:20:00.000000000 -0500 +++ r43.0.1.1/r43.rb 2005-06-28 19:51:08.734764800 -0500 @@ -98,7 +98,7 @@ # class Person attr_accessor :username, :name, :url, :profile_image_url, - :num_open_goals, :link, :city, :goals + :num_open_goals, :link, :city, :goals, :flickr_username def initialize() # just to create the object, we'll always feed the attributes in @@ -431,9 +431,15 @@ # connection = R43.new() # person = connection.get_person() # - def get_person(id) + def get_person(id,use_flickr=false) person = Person.new() - xml = _get_response("get_person?api_key=1234&id=#{id}") + if (use_flickr) + id_cmd = "flickr_username" + else + id_cmd = "id" + end + xml = _get_response("get_person?api_key=#{@key}&#{id_cmd}=#{id}") + xml.elements.each("person") do |person_element| person = Person.from_xml(person_element) end ********************** END PATCH ********************** Is this what I want to generate? If so, is it best to include it in the message as I did, or should I put it in an attachment (.patch?) and if so, what should the file be named? Finally, Pat, is this what you had in mind when you mentioned changing Person to reflect the new API? If so, I will start on tests for it. If this is not what you had in mind, is it an appropriate change and what did you have in mind? Sean Carley From chris at seagul.co.uk Wed Jun 29 05:00:40 2005 From: chris at seagul.co.uk (Chris Roos) Date: Wed Jun 29 04:55:56 2005 Subject: [RPS] Co-Mentorship In-Reply-To: <9e272eff050628114878dfc9ff@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> Message-ID: <42C26338.8030707@seagul.co.uk> Sean Carley wrote: > We seem to have more people looking for mentors than we have mentors > to guide them. I would still like to work with someone to improve my > Ruby and my collaborative development skills. I propose to pair with > someone else still seeking a mentor and we can bootstrap ourselves > together. If you are interested in co-mentoring each other, please > send me a message. I am sure we all have something to learn from each > other. > Hi Sean, I'd be interested in working with you. I have relatively little ruby experience (although I'm currently working on a Rails project for a local firm) but am willing to learn. Having someone to work with will probably give me more incentive to pick this stuff up and run with it. How do you want to proceed from here (providing of course that you are happy to try to work together)? Maybe we should now communicate off list and see if we can't get started on some of the tasks that Pat has listed? I'll await to hear from you. Chris From seanacarley at gmail.com Wed Jun 29 00:01:46 2005 From: seanacarley at gmail.com (Sean Carley) Date: Wed Jun 29 08:22:50 2005 Subject: [RPS] Re: First Attempts at Usefulness - r43 In-Reply-To: <9e272eff05062818042fa0b05e@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> <6fd0654b05062812087d8cebf2@mail.gmail.com> <9e272eff05062818042fa0b05e@mail.gmail.com> Message-ID: <9e272eff050628210114ba939e@mail.gmail.com> I have done a bit more work, on the premise that what is in CVS is more current than the last file release. The attached patch can be applied from the source directory (after CVS co) with the command patch -p1 < source.patch. I have added more testing to Person. I have added the ability to use get_person(flickr_username, true) to do flickr_username based Person lookups and I believe I have finished Person. Take a look. Let me know what you think and how crazy you think I am. Sean Carley -------------- next part -------------- A non-text attachment was scrubbed... Name: source.patch Type: application/octet-stream Size: 60282 bytes Desc: not available Url : http://rubyforge.org/pipermail/therps-discuss/attachments/20050628/7c94742f/source-0001.obj From pat.eyler at gmail.com Wed Jun 29 14:15:12 2005 From: pat.eyler at gmail.com (pat eyler) Date: Wed Jun 29 14:10:23 2005 Subject: [RPS] Re: First Attempts at Usefulness - r43 In-Reply-To: <9e272eff050628210114ba939e@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> <6fd0654b05062812087d8cebf2@mail.gmail.com> <9e272eff05062818042fa0b05e@mail.gmail.com> <9e272eff050628210114ba939e@mail.gmail.com> Message-ID: <6fd0654b050629111560d2c896@mail.gmail.com> On 6/28/05, Sean Carley wrote: > I have done a bit more work, on the premise that what is in CVS is > more current than the last file release. The attached patch can be > applied from the source directory (after CVS co) with the command > patch -p1 < source.patch. > > I have added more testing to Person. I have added the ability to use > get_person(flickr_username, true) to do flickr_username based Person > lookups and I believe I have finished Person. Take a look. Let me > know what you think and how crazy you think I am. The patch looks good, I don't have a way to test it against live data during the day though. Testing against your provided xml looks fine: $ ruby -Ilib test/test_r43.rb Loaded suite test/test_r43 Started ............................................................................. Finished in 0.824711 seconds. 77 tests, 144 assertions, 0 failures, 0 errors You might want to make the optional use_flicker argument something more meaningful than true or false. It's a bit opaque from the user's point of view. Don't forget to update the documentation so that users will know how to use the flickr_username option, maybe something like: @@ -427,11 +427,14 @@ # # Implements the get_person method from the People API and returns a -# Person object. +# Person object. If the optional true or false value is set to true, +# the username is treated as a flickr username instead of a 43 Things +# username. If the value is false or not set, the username is treated +# as a 43 Things username. # # require 'r43' # connection = R43.new() -# person = connection.get_person() +# person = connection.get_person([, ]) # def get_person(id,use_flickr=false) person = Person.new() > > Sean Carley > > > _______________________________________________ > Therps-discuss mailing list > Therps-discuss@rubyforge.org > http://rubyforge.org/mailman/listinfo/therps-discuss > > > > -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From seanacarley at gmail.com Wed Jun 29 19:13:53 2005 From: seanacarley at gmail.com (Sean Carley) Date: Wed Jun 29 19:09:05 2005 Subject: [RPS] Re: First Attempts at Usefulness - r43 In-Reply-To: <6fd0654b050629111560d2c896@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> <6fd0654b05062812087d8cebf2@mail.gmail.com> <9e272eff05062818042fa0b05e@mail.gmail.com> <9e272eff050628210114ba939e@mail.gmail.com> <6fd0654b050629111560d2c896@mail.gmail.com> Message-ID: <9e272eff0506291613378c12e7@mail.gmail.com> On 6/29/05, pat eyler wrote: > You might want to make the optional use_flicker argument > something more meaningful than true or false. It's a bit > opaque from the user's point of view. > > > Don't forget to update the documentation so that users will know how > to use the flickr_username option, maybe something like: > I have tried to address your concerns. In particular, get_person(flickr_username, true) is now get_person([, (:normal|:flickr)) where get_person(username, :flickr) does a lookup by flickr_username instead of by id. I have added documentation to get_person to reflect the changes. Also, I added get_persons_completed_things from the People API and added an appropriate test method for it to the test suite. This required me to add more to Person. Finally, I extracted the id/flickr_username determination to a private method on R43 to prevent duplicated code in get_person and get_persons_completed_things. The attached patch file is cumulative and includes everything from the first patch. I was not sure if it was better to create the one patch to get from the current CVS to this or if I should have created a patch to get from my last patch to this. I went with the first option for simplicities sake. Sean -------------- next part -------------- A non-text attachment was scrubbed... Name: second_try.patch.gz Type: application/x-gzip Size: 6649 bytes Desc: not available Url : http://rubyforge.org/pipermail/therps-discuss/attachments/20050629/eb0b57cf/second_try.patch.bin From pat.eyler at gmail.com Thu Jun 30 10:36:55 2005 From: pat.eyler at gmail.com (pat eyler) Date: Thu Jun 30 10:32:04 2005 Subject: [RPS] Re: First Attempts at Usefulness - r43 In-Reply-To: <9e272eff0506291613378c12e7@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> <6fd0654b05062812087d8cebf2@mail.gmail.com> <9e272eff05062818042fa0b05e@mail.gmail.com> <9e272eff050628210114ba939e@mail.gmail.com> <6fd0654b050629111560d2c896@mail.gmail.com> <9e272eff0506291613378c12e7@mail.gmail.com> Message-ID: <6fd0654b050630073656d0e9ab@mail.gmail.com> On 6/29/05, Sean Carley wrote: > On 6/29/05, pat eyler wrote: > > You might want to make the optional use_flicker argument > > something more meaningful than true or false. It's a bit > > opaque from the user's point of view. > > > > > > Don't forget to update the documentation so that users will know how > > to use the flickr_username option, maybe something like: > > > I have tried to address your concerns. Concerns is probably too strong a word. :) > In particular, > get_person(flickr_username, true) is now get_person([, > (:normal|:flickr)) where get_person(username, :flickr) does a lookup > by flickr_username instead of by id. I think this is much more sensible for the user. Thanks, > > I have added documentation to get_person to reflect the changes. > > Also, I added get_persons_completed_things from the People API and > added an appropriate test method for it to the test suite. This > required me to add more to Person. Starting to add new methods is where you can really start to see things work and leads right into the refactoring listed below. > > Finally, I extracted the id/flickr_username determination to a private > method on R43 to prevent duplicated code in get_person and > get_persons_completed_things. Have you ever looked at Fowler's 'Refactoring'? It's a great book, and not too exspensive (as computer books go). This is exactly the kind of development model he's talking about. Having the unit tests in place really let's you let go of fear and just work on the code. Awesome job! Would you mind updating your cvs tree (it has your previous changes and the doc changes I added), and creating a diff from that? Then I can commit it and everything will be happy. How do people feel about this style of posting and review? Would it be better to post the tests and code inline instead of attachments? (I kind of lean that way, but I'm not sure.) > > The attached patch file is cumulative and includes everything from the > first patch. I was not sure if it was better to create the one patch > to get from the current CVS to this or if I should have created a > patch to get from my last patch to this. I went with the first option > for simplicities sake. > > Sean > > > _______________________________________________ > Therps-discuss mailing list > Therps-discuss@rubyforge.org > http://rubyforge.org/mailman/listinfo/therps-discuss > > > > -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From pat.eyler at gmail.com Thu Jun 30 11:02:40 2005 From: pat.eyler at gmail.com (pat eyler) Date: Thu Jun 30 10:57:49 2005 Subject: [RPS] r43 task and opportunity Message-ID: <6fd0654b05063008021984947@mail.gmail.com> A while ago, I traded emails with another Ruby developer who was grabbing a bit of stuff from 43 Things using his own homebrew code (see below). His code is pretty ugly, but is worth looking at anyway, if only to see how he did things with XPath. He has one method that r43 doesn't yet -- get_persons_entries. If we were to get that implemented and some example code (maybe mirroring his display_feed_fortythree_goals method), he would be able to replace his stuff with r43. Anyone interested in building get_persons_entries and an example script? ----homebrew 43 things interface--- module FeedSystem # method to update 43things foals feed def update_feed_fortythree(fortythree_feed_row, fortythree_feed_account) key = "1234" base = "http://www.43things.com/service/" begin goals_feed = open("#{base}get_person?api_key=#{key}&id=#{fortythree_feed_account}").read completed_feed = open("#{base}get_persons_completed_things?api_key=#{key}&id=#{fortythree_feed_account}").read entries_feed = open("#{base}get_persons_entries?api_key=#{key}&id=#{fortythree_feed_account}").read if fortythree_feed = FortythreeFeed.find(fortythree_feed_row) fortythree_feed.goals = goals_feed fortythree_feed.completed = completed_feed fortythree_feed.entries = entries_feed fortythree_feed.save end rescue # prevent 404 error end end # method to display 43things goals list def display_feed_fortythree_goals(fortythree_feed_goals, fortythree_feed_account) doc = REXML::Document.new(fortythree_feed_goals) items = [] REXML::XPath.each(doc, "person/open_goals/goal") do |item| item = "
  • #{REXML::XPath.match(item, "name/text()").to_s}
  • " items << item end if items.to_s.size > 0 counter = 1 limit = items.size - 1 list = (0..limit).to_a.map do |x| if counter.modulo(2).nonzero? # everything is ok else items[x].gsub!(/
  • /, "
  • ") end counter+=1 items[x] end output = list.to_s else false end end # method to display 43things completed list def display_feed_fortythree_completed(fortythree_feed_completed, fortythree_feed_account) doc = REXML::Document.new(fortythree_feed_completed) items = [] REXML::XPath.each(doc, "person/completed_goals/goal") do |item| item = "
  • #{REXML::XPath.match(item, "name/text()").to_s}
  • " items << item end if items.to_s.size > 0 counter = 1 limit = items.size - 1 list = (0..limit).to_a.map do |x| if counter.modulo(2).nonzero? # everything is ok else items[x].gsub!(/
  • /, "
  • ") end counter+=1 items[x] end output = list.to_s else false end end # method to display 43things entries list def display_feed_fortythree_entries(fortythree_feed_entries, fortythree_feed_account, fortythree_entries_amount = 10) doc = REXML::Document.new(fortythree_feed_entries) items = [] REXML::XPath.match(doc, "feed/entry").first(fortythree_entries_amount).each do |item| item = "
  • #{REXML::XPath.match(item, "title/text()").to_s}

    #{REXML::XPath.match(item, "content/text()").to_s}

  • " items << item end if items.to_s.size > 0 counter = 1 limit = items.size - 1 list = (0..limit).to_a.map do |x| if counter.modulo(2).nonzero? # everything is ok else items[x].gsub!(/
  • /, "
  • ") end counter+=1 items[x] end output = list.to_s else false end end end -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From nugend at gmail.com Thu Jun 30 18:54:12 2005 From: nugend at gmail.com (Daniel Nugent) Date: Thu Jun 30 18:49:21 2005 Subject: [RPS] A suggestion about organization Message-ID: <28c4258c05063015546110f9d8@mail.gmail.com> Hi guys, First off, I want to apologize for not making much of a contribution to Payment. I was a little unsure of what was going on and wanted to shore up my experience with Ruby before I jumped into it. I know we've had some difficulty with organizing and assigning tasks on payment and honestly I'm not seeing much of an improvement with r43 either. No offense to Pat or any of the other guys, but there doesn't seem to be much way of figuring out what's happening except scanning the mailing list. I was wondering if we might consider opening up a free BaseCamp account to help keep track of milestones and tasks and who's assigned to what and so forth. Though the free account only lets you keep track of one project at a time, I don't think that will necessarily be a hindrance to our goals as we're trying to focus on one at a time anyhow. -- -Dan Nugent From pat.eyler at gmail.com Thu Jun 30 20:17:33 2005 From: pat.eyler at gmail.com (pat eyler) Date: Thu Jun 30 20:12:40 2005 Subject: [RPS] A suggestion about organization In-Reply-To: <28c4258c05063015546110f9d8@mail.gmail.com> References: <28c4258c05063015546110f9d8@mail.gmail.com> Message-ID: <6fd0654b050630171761ea448c@mail.gmail.com> well, there is a backpack page at: http://pate.backpackit.com/pub/1610 I can grant full sharing to anyone who's interested, just email me off-list. If someone's interested in setting up a basecamp account, I'd be happy to use it. On 6/30/05, Daniel Nugent wrote: > Hi guys, > > First off, I want to apologize for not making much of a contribution > to Payment. I was a little unsure of what was going on and wanted to > shore up my experience with Ruby before I jumped into it. > > I know we've had some difficulty with organizing and assigning tasks > on payment and honestly I'm not seeing much of an improvement with r43 > either. No offense to Pat or any of the other guys, but there doesn't > seem to be much way of figuring out what's happening except scanning > the mailing list. > > I was wondering if we might consider opening up a free BaseCamp > account to help keep track of milestones and tasks and who's assigned > to what and so forth. Though the free account only lets you keep > track of one project at a time, I don't think that will necessarily be > a hindrance to our goals as we're trying to focus on one at a time > anyhow. > > -- > -Dan Nugent > > _______________________________________________ > Therps-discuss mailing list > Therps-discuss@rubyforge.org > http://rubyforge.org/mailman/listinfo/therps-discuss > -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From pat.eyler at gmail.com Thu Jun 30 20:22:54 2005 From: pat.eyler at gmail.com (pat eyler) Date: Thu Jun 30 20:18:02 2005 Subject: [RPS] Re: First Attempts at Usefulness - r43 In-Reply-To: <6fd0654b050630073656d0e9ab@mail.gmail.com> References: <9e272eff05052306473a9a2db0@mail.gmail.com> <9e272eff050628114878dfc9ff@mail.gmail.com> <6fd0654b05062812087d8cebf2@mail.gmail.com> <9e272eff05062818042fa0b05e@mail.gmail.com> <9e272eff050628210114ba939e@mail.gmail.com> <6fd0654b050629111560d2c896@mail.gmail.com> <9e272eff0506291613378c12e7@mail.gmail.com> <6fd0654b050630073656d0e9ab@mail.gmail.com> Message-ID: <6fd0654b0506301722591b5e05@mail.gmail.com> On 6/30/05, pat eyler wrote: > > Awesome job! Would you mind updating your cvs tree (it has your > previous changes and the doc changes I added), and creating a diff > from that? Then I can commit it and everything will be happy. > Sorry for responding to myself. The commit that I thought I'd made earlier wasn't made :( I've just updated things with Sean's first round of patches. *sigh* I'll look forward to a newer set (and maybe even some more additions). -- thanks, -pate ------------------------- We are often unable to tell people what they need to know, because they want to know something else, and would therefore only misunderstand what we said - the Raven (George MacDonald, Lilith) From seanacarley at gmail.com Thu Jun 30 22:00:25 2005 From: seanacarley at gmail.com (Sean Carley) Date: Thu Jun 30 21:55:36 2005 Subject: [RPS] r43 task and opportunity In-Reply-To: <6fd0654b05063008021984947@mail.gmail.com> References: <6fd0654b05063008021984947@mail.gmail.com> Message-ID: <9e272eff0506301900651293a9@mail.gmail.com> On 6/30/05, pat eyler wrote: > A while ago, I traded emails with another Ruby developer who was > grabbing a bit of stuff from 43 Things using his own homebrew code > (see below). His code is pretty ugly, but is worth looking at anyway, > if only to see how he did things with XPath. He has one method > that r43 doesn't yet -- get_persons_entries. If we were to get that > implemented and some example code (maybe mirroring his > display_feed_fortythree_goals method), he would be able to replace > his stuff with r43. > > Anyone interested in building get_persons_entries and an example > script? > I will start on get_persons_entries tonight. Once I get it completed, I will whip up a sample script. Sean