Camelia, the Perl 6 bug

IRC log for #bioperl, 2013-02-12

| Channels | #bioperl index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:10 sivoais joined #bioperl
00:47 drin_m joined #bioperl
00:50 perlhelp joined #bioperl
00:50 perlhelp Hi! :)
03:33 drin_m_ joined #bioperl
04:08 perlhelp joined #bioperl
04:21 perlhelp_ joined #bioperl
04:21 perlhelp_ hi
04:30 drin_m_ hallo
04:32 perlhelp_ good morning!
06:05 perlhelp joined #bioperl
07:53 looper joined #bioperl
09:59 ObseLeTe joined #bioperl
13:53 Danusya joined #bioperl
14:03 _ilbot joined #bioperl
14:03 Topic for #bioperl is now Be patient! People chat here daily, but not necessarily the minute or hour you wandered in. Leave your IRC client connected. | http://bioperl.org/wiki/IRC#Getting_help | http://www.bioperl.org/wiki/Using_Git | nopaste to gist.github.com
14:09 _ilbot joined #bioperl
14:09 Topic for #bioperl is now Be patient! People chat here daily, but not necessarily the minute or hour you wandered in. Leave your IRC client connected. | http://bioperl.org/wiki/IRC#Getting_help | http://www.bioperl.org/wiki/Using_Git | nopaste to gist.github.com
14:33 _ilbot joined #bioperl
14:33 Topic for #bioperl is now Be patient! People chat here daily, but not necessarily the minute or hour you wandered in. Leave your IRC client connected. | http://bioperl.org/wiki/IRC#Getting_help | http://www.bioperl.org/wiki/Using_Git | nopaste to gist.github.com
14:34 _ilbot joined #bioperl
14:34 Topic for #bioperl is now Be patient! People chat here daily, but not necessarily the minute or hour you wandered in. Leave your IRC client connected. | http://bioperl.org/wiki/IRC#Getting_help | http://www.bioperl.org/wiki/Using_Git | nopaste to gist.github.com
14:36 _ilbot joined #bioperl
14:36 Topic for #bioperl is now Be patient! People chat here daily, but not necessarily the minute or hour you wandered in. Leave your IRC client connected. | http://bioperl.org/wiki/IRC#Getting_help | http://www.bioperl.org/wiki/Using_Git | nopaste to gist.github.com
15:19 ObseLeTe joined #bioperl
15:56 perlhelp joined #bioperl
15:56 perlhelp hi!
16:39 sivoais joined #bioperl
16:49 sivoais joined #bioperl
18:09 perlhelp joined #bioperl
18:09 perlhelp hi!
18:09 perlhelp quick (i hope!) perl q
18:19 deafferret pong
18:19 deafferret perlhelp ^
18:21 perlhelp hi!
18:22 perlhelp thanks for writing.
18:24 perlhelp i am trying to display some output
18:24 perlhelp i am not sure how to do so such that th white spce gets fully removed
18:25 perlhelp i tried adding      $value =~ s/^\s+|\s+$//g; where $value takes on what i'm looking to pirnt
18:52 rbuels joined #bioperl
20:28 perlhelp joined #bioperl
20:28 perlhelp hi!
20:29 perlhelp @deafferrent: Are you still here?
20:31 perlhelp Hi!
20:50 scottcain joined #bioperl
20:51 ObseLeTe joined #bioperl
21:39 Danusya left #bioperl
21:49 perlhelp_ joined #bioperl
21:49 perlhelp_ Hi!
22:39 deafferret perlhelp_: pong
22:40 perlhelp_ Hi!
22:40 deafferret irc.perl.org #perl-help has lots of people. here it's often just me :)
22:40 deafferret and I get distracted :)
22:41 perlhelp_ that's ok :)
22:46 deafferret perlhelp_: are you still stuck?
22:46 perlhelp_ yes
22:46 perlhelp_ i made much progress
22:47 deafferret you want to remove all whitespace? Or only leading and trailing whitespace?
22:47 deafferret your | in the middle there isn't going to work, I don't think
22:48 sivoais joined #bioperl
22:48 perlhelp_ oh i removd the white space ! )
22:49 deafferret ok. what are you stuck on now?
22:50 perlhelp_ Can I show you my code?  (It is not terribly long)
22:51 deafferret perlhelp_: don't paste it. use gist.github.com
22:51 deafferret or equivalent paste service
22:51 perlhelp_ http://scsys.co.uk:8002 ?
22:51 deafferret that's fine
22:51 perlhelp_ http://scsys.co.uk:8002/230059
22:52 deafferret so what's your question?
22:54 perlhelp_ When I get to that myurl. . .
22:54 perlhelp_ no.
22:54 perlhelp_ i meant the get
22:54 perlhelp_ $mech->get("https: . . .
22:56 perlhelp_ if i use locations.txt = Benjamin,Schuvlein,Germany,1912,M,White
22:56 perlhelp_ I get only 1 record
22:56 perlhelp_ https://familysearch.org/search/collection/r​esults#count=20&query=%2Bgivenname%3ABen​jamin%20%2Bsurname%3ASchuvlein%20%2Bbirth_pl​ace%3AGermany%20%2Bbirth_year%3A1910-1914~%20%2Bgender%3AM%20%2Brace%3​AWhite&collection_id=2000219
22:57 perlhelp_ but with other data fo locations.txt, i might get something like "no records" or 2 or more.  i only want it to collect the data if it is exactly 1.
23:01 deafferret ... can you reduce that to a Perl question? I don't have a bunch of time to debug your whole program right now
23:02 deafferret are you having a problem parsing text or what?
23:02 perlhelp_ yes, i guess you can say that.
23:02 perlhelp_ it's also i'm not sure the best coding strategy to this conundrm
23:02 deafferret so if you can point me at which 3 lines of code we're talking about...
23:03 deafferret so ... the URL you pasted works fine? Send me a URL where you're not processing it correctly
23:03 deafferret I need a currently broken test case :)
23:06 perlhelp_ Benjamin,Schuvlein,Germany,1912,M,White = 1 of 1 -> scrape
23:06 perlhelp_ Benjamin,Schuvlein,Germany,1919,M,White = 0 (no records) -> no scrape
23:06 perlhelp_ Benjamin,Smith,New York,1912,M,White = definitely more thn 1-> do not scrape
23:07 perlhelp_ could i do something like: if (@$links != 1)   ?
23:07 perlhelp_ or i mean, if (@$links == 1)   { }
23:08 deafferret ya. url_regex => qr/pal:/ is only catching what you want, right?
23:08 perlhelp_ the link of interest
23:08 deafferret so ya,    if (@!links == 1) { }
23:08 perlhelp_ such as: https://familysearch.org/pal:/MM9.1.1/K3BN-LLJ
23:08 deafferret err   if (@$links == 1) { }    sorry  :)
23:09 deafferret sounds like you know what to do :)
23:09 perlhelp_ hold on
23:09 perlhelp_ do i put it right after that line?
23:09 deafferret you should fix all your indenting, start using subroutines
23:09 perlhelp_ my $links = $mech->find_all_links(url_regex => qr/pal:/);    if (@!links == 1) { }
23:10 perlhelp_ sorry.  i am novic.  subroutine? you mean like functions ?
23:10 deafferret yup.  sub fetchdetail { }    foreach link you want to actually process
23:10 deafferret that sort of thing
23:10 perlhelp_ i have no idea what that means
23:11 perlhelp_ does tht just mak the code look tidier?  or does that effect how fast it runs
23:11 perlhelp_ this is only for my purposes, so i just want functionality.
23:11 deafferret it effects programming speed since you can read and modify your code faster  :)
23:11 perlhelp_ like i don't need to tun ths over to anybody.
23:11 deafferret it will have no effect on run speed
23:11 deafferret no but YOU have to be able to read it, right?
23:11 perlhelp_ oh, you mean it affects my speed but not execution of th terminal sped?
23:11 deafferret http://perldoc.perl.org/perlsub.html
23:11 perlhelp_ yes, i can read it find right now
23:12 perlhelp_ i'm afraid i will mess up by changing what i hav
23:12 deafferret you, as a human, need to be able to read your source code in order to program as your code gets more complex
23:12 perlhelp_ it will not get more complex
23:12 perlhelp_ there is 1 more thing i want to do to it
23:12 deafferret that's what version control is for. commit your code, and then clean it up
23:12 perlhelp_ oh ok
23:12 perlhelp_ i do'nt meant to b difficult
23:12 perlhelp_ i'm just very intimidated.
23:13 deafferret github.com is easy. stick your code in there. :)
23:13 deafferret or just use git locally if you want.
23:13 deafferret git init
23:13 deafferret done :)
23:14 perlhelp_ huh?  what is github?
23:14 perlhelp_ it says build software?
23:14 deafferret http://github.com  is a free host for git repositories
23:15 perlhelp_ what does that mean?
23:15 deafferret git is one (very popular) version control system
23:15 deafferret what does "version control" mean?
23:15 deafferret what does what mean? :)
23:15 perlhelp_ yes
23:15 perlhelp_ i'm sorry :(
23:15 perlhelp_ i don't know terms well.
23:15 perlhelp_ i just program.  but i don't the jargon.
23:15 deafferret version control is any system that lets programmers keep track of their changes and not have to worry about losing their code
23:16 deafferret git is one such system
23:16 perlhelp_ http://scsys.co.uk:8002/230063
23:16 perlhelp_ git sounds nice then! :)
23:16 perlhelp_ i will sign up when i have a moment to breathe
23:17 perlhelp_ i am testing the if loop
23:17 perlhelp_ does it look like i put it in the correct place?
23:18 perlhelp_ i am using this locations filee:
23:18 deafferret its hard for me to tell because your indention is whacked
23:18 perlhelp_ locations = http://scsys.co.uk:8002/230064
23:20 perlhelp_ oops.
23:20 perlhelp_ http://scsys.co.uk:8002/230066
23:20 perlhelp_ I think it workd!!
23:20 deafferret \o/   :)
23:20 perlhelp_ it outputtd the people it should !
23:20 perlhelp_ http://scsys.co.uk:8002/230067
23:21 perlhelp_ can i ask a q about that?
23:21 deafferret yup. don't ask to ask, just ask
23:21 perlhelp_ the input had 5 lines.  the output has 3
23:21 perlhelp_ is there a way to output the other 2
23:21 perlhelp_ obviouly it would be dfferent output
23:21 perlhelp_ they will not have ll of the variables
23:21 perlhelp_ only the first 6
23:22 perlhelp_ an if statement?
23:22 deafferret back in 5m
23:22 perlhelp_ if (@$links != 1) {
23:22 perlhelp_ my @values = ( $args{givenname}, $args{surname}, $args{birth_year},$args{birth_pl​ace},$args{gender},$args{race});
23:22 perlhelp_ print($o (join ",", @values), "\n");
23:22 perlhelp_ }
23:22 perlhelp_ ?
23:25 perlhelp_ http://scsys.co.uk:8002/230068?ln=on&amp​;tidy=on&hl=on&submit=Format+it!
23:25 perlhelp_ that did not work :(
23:26 carandraug joined #bioperl
23:26 carandraug joined #bioperl
23:28 perlhelp_ Rats.  That did not work.  http://scsys.co.uk:8002/230069?ln=on&amp​;tidy=on&hl=on&submit=Format+it!
23:28 scottcain joined #bioperl
23:30 perlhelp_ I messd something up there.
23:38 deafferret back
23:39 deafferret perlhelp_++ # fixing indention
23:40 deafferret that looks like it will work once you   # PRINT THE 6 INPUTS   and change the if to elsif
23:40 deafferret errr... either if or elsif should be fine
23:40 deafferret what's not working about it?
23:41 deafferret or just else   :)

| Channels | #bioperl index | Today | | Search | Google Search | Plain-Text | summary