« Back to channel list

#ruby - 02 November 2018

« Back 1 day Forward 1 day »
[00:00:19] orbyt_: has joined #ruby
[00:01:25] phaul: Another completely different question is that if it's sensible to implement a linked list in Ruby in the first place..
[00:01:51] havenwood: phaul: a Hash is a doubly-circularly linked list already :)
[00:02:30] phaul: Yeah Im not saying what's what internally. Im saying using the exposed language features. no FFI
[00:02:37] havenwood: phaul: yeah, I don't get much occasion to implement one mysellf
[00:04:25] warrshrike: phaul: here you go class ListNode attr_accessor :val, :next def initialize(val, n) @val = val @next = n end end
[00:08:45] cd: has joined #ruby
[00:11:30] phaul: I guess insert/delete in the middle would be maybe faster than just an Array, with copying, but, still O(n) either way. But everything else I expect the stdlib Array to be better than this. shift/prepend etc.
[00:23:31] venmx: has joined #ruby
[00:24:24] nicesignal: has joined #ruby
[00:36:06] phaul: havenwood: are you sure Hash is a double linked list?.. I can beleive it has double linked lists in it. Linked lists are not great for lookup :)
[00:55:19] havenwood: phaul: Since Ruby 1.9 it's been this implementation: https://www.igvita.com/2009/02/04/ruby-19-internals-ordered-hash/
[00:55:32] havenwood: phaul: Then in 2.4 it got some nice changes: https://blog.heroku.com/ruby-2-4-features-hashes-integers-rounding#hash-changes
[00:56:04] havenwood: phaul: And in Ruby 2.5 they switched from SipHash24 to SipHash 13 - following Rust's lead.
[00:58:06] havenwood: (One c round and three d rounds.)
[00:58:30] havenwood: "full cycle linear congruential generator" - has a ring to it
[00:59:40] phaul: I would have to read this, once I dug myself into this already but most of it is gone by now..
[01:00:07] phaul: I was just saying that if you are pedantic.. A hash is not a double linked list
[01:00:21] phaul: it can contain double linked lists
[01:00:46] havenwood: "a Hash is also a doubly-circular linked list!" ~ Ilya Grigorik
[01:01:08] phaul: "also" :)
[01:01:21] havenwood: phaul: My girlfriend only allow me one pedantry per day. I've already used todays!
[01:01:51] havenwood: She usually uses her's earlier in the day than I do. :P
[01:02:06] phaul: Im not going to compete :)
[01:03:16] Dimik: has joined #ruby
[01:05:51] phaul: havenwood: how was London?
[01:07:35] havenwood: phaul: it was a grueling trip, but got some good work done.
[01:10:39] m27frogy: has joined #ruby
[01:12:53] TheBloke: has joined #ruby
[01:19:18] whysthatso: has joined #ruby
[01:25:14] cagomez: has joined #ruby
[01:27:35] AJA4350: has joined #ruby
[01:44:13] metus: has joined #ruby
[01:44:38] Xiti`: has joined #ruby
[01:45:09] Pixi_: has joined #ruby
[01:45:42] tdy: has joined #ruby
[02:02:20] sanscoeur: has joined #ruby
[02:16:58] mangold: has joined #ruby
[02:21:56] esrse: has joined #ruby
[02:25:21] SeepingN: has joined #ruby
[02:43:50] pskosinski: has joined #ruby
[02:44:31] darkhanb: has joined #ruby
[03:09:21] kapil____: has joined #ruby
[03:13:12] hurricanehrndz: has joined #ruby
[03:20:46] al2o3-cr: has joined #ruby
[03:42:45] Azure: has joined #ruby
[03:43:39] akaiiro: has joined #ruby
[03:46:05] mangold: has joined #ruby
[03:55:00] sanscoeur: has joined #ruby
[03:57:58] Xiti: has joined #ruby
[04:00:52] akaiiro: has joined #ruby
[04:06:45] sauvin: has joined #ruby
[04:07:30] Xiti`: has joined #ruby
[04:09:32] braincrash: has joined #ruby
[04:12:15] c0san0stra: has joined #ruby
[04:13:14] pragathoys: has joined #ruby
[04:15:05] agrecascino: has joined #ruby
[04:27:20] SeepingN: has joined #ruby
[04:44:54] akaiiro: has joined #ruby
[04:50:09] darkhanb: has joined #ruby
[05:09:27] SeepingN: has joined #ruby
[05:16:53] NightMonkey: has joined #ruby
[05:21:44] MoritaShinobu: has joined #ruby
[05:32:41] nofxx: has joined #ruby
[05:35:04] LightStalker: has joined #ruby
[05:38:56] sauvin: has joined #ruby
[05:40:09] m27frogy: has joined #ruby
[05:48:27] asphyxia: has joined #ruby
[05:54:13] _whitelogger: has joined #ruby
[06:13:28] Nicmavr: has joined #ruby
[06:27:47] m0nty0ne: has joined #ruby
[06:28:33] aufi: has joined #ruby
[06:54:58] conta: has joined #ruby
[07:01:37] aupadhye: has joined #ruby
[07:01:55] gigetoo: has joined #ruby
[07:13:12] dellavg_: has joined #ruby
[07:27:29] Puffball: has joined #ruby
[07:33:34] Puffball: has joined #ruby
[07:36:07] skwurl: has joined #ruby
[07:40:42] cranq: has joined #ruby
[07:42:05] NightMonkey: has joined #ruby
[07:46:38] roshanavand: has joined #ruby
[07:52:28] vondruch: has joined #ruby
[07:53:09] venmx: has joined #ruby
[07:59:46] ellcs: has joined #ruby
[08:03:55] roshanavand: has joined #ruby
[08:11:07] Puffball_: has joined #ruby
[08:15:32] xfbs: has joined #ruby
[08:17:14] Cthulu201: has joined #ruby
[08:19:30] nowhere_man: has joined #ruby
[08:21:52] Puffball: has joined #ruby
[08:27:06] clemens3: has joined #ruby
[08:31:00] aufi: has joined #ruby
[08:31:03] TvL2386: hi guys, is it possible to connect ruby on windows to mssql on windows?
[08:31:12] TvL2386: (I don't want to use powershell)
[08:33:54] TvL2386: https://github.com/Microsoft/sql-server-samples/tree/master/samples/tutorials/ruby/windows
[08:34:07] TvL2386: never mind
[08:34:56] yxhuvud: has joined #ruby
[08:35:48] phaul: has joined #ruby
[08:39:33] DoubleMalt: has joined #ruby
[09:02:50] despai: has joined #ruby
[09:04:10] ricer2: has joined #ruby
[09:07:57] za1b1tsu: has joined #ruby
[09:38:47] venmx: has joined #ruby
[09:40:08] roshanavand: has joined #ruby
[09:40:50] xfbs: has joined #ruby
[09:40:58] nexraf1: has joined #ruby
[10:13:14] johnny56: has joined #ruby
[10:14:14] nowhere_man: has joined #ruby
[10:18:27] voolik: has joined #ruby
[10:19:01] nertzy: has joined #ruby
[10:20:37] al2o3-cr: has joined #ruby
[10:37:45] pragathoys: has joined #ruby
[11:00:07] Cthulu201: has joined #ruby
[11:03:48] roshanavand: has joined #ruby
[11:06:28] apeiros: has joined #ruby
[11:15:14] elphe: has joined #ruby
[11:16:45] phaul: hi apeiros, hows mergeing the ruboto PR going?
[11:17:15] apparition: has joined #ruby
[11:19:17] cd: has joined #ruby
[11:24:38] AJA4350: has joined #ruby
[11:25:05] jsc: has joined #ruby
[11:30:11] conta: has joined #ruby
[11:32:30] roshanavand: has joined #ruby
[11:45:41] asphyxia: has joined #ruby
[11:50:25] doubledup: has joined #ruby
[11:58:01] doubledup: has joined #ruby
[11:58:24] ua: has joined #ruby
[12:00:39] JamieD: has joined #ruby
[12:02:14] status402: has joined #ruby
[12:02:35] elphe: has joined #ruby
[12:02:59] c0ncealed4: has joined #ruby
[12:08:49] dellavg_: has joined #ruby
[12:09:38] apeiros__: has joined #ruby
[12:10:50] k0mpa: has joined #ruby
[12:11:01] elphe: has joined #ruby
[12:15:00] jcalla: has joined #ruby
[12:18:01] TheBloke: has joined #ruby
[12:30:53] aaltohenrik: has joined #ruby
[12:32:46] ua: has joined #ruby
[12:34:12] vonfry: has joined #ruby
[12:35:37] rubydoc: has joined #ruby
[12:39:26] kapil____: has joined #ruby
[12:42:51] zapata: has joined #ruby
[12:44:34] mostlybadfly: has joined #ruby
[12:45:35] aufi: has joined #ruby
[12:47:06] reber: has joined #ruby
[12:48:46] elphe: has joined #ruby
[13:01:07] GodFather: has joined #ruby
[13:03:06] wojnar: has joined #ruby
[13:04:22] voolik: has joined #ruby
[13:08:16] Dimik: has joined #ruby
[13:08:36] elphe: has joined #ruby
[13:09:41] za1b1tsu: has joined #ruby
[13:15:13] cow[moo]: has joined #ruby
[13:18:13] pragathoys: has joined #ruby
[13:20:35] dmitch: has joined #ruby
[13:23:14] cow[moo]: has joined #ruby
[13:38:22] spiette: has joined #ruby
[13:44:36] rippa: has joined #ruby
[13:51:51] SeepingN: has joined #ruby
[13:52:59] Iambchop: TvL2386: "You can connect to a [MS]SQL Database using Ruby on Windows, Linux, or Mac." https://docs.microsoft.com/en-us/sql/connect/ruby/ruby-driver-for-sql-server?view=sql-server-2017
[13:54:17] jlebrech: has joined #ruby
[13:54:40] jlebrech: i'm trying to run capybara with js support and am getting this
[13:54:41] jlebrech: undefined method `<<' for {:read_timeout=>2, :continue_timeout=>nil, :debug_output=>nil}:Hash
[13:54:43] Iambchop: TvL2386: If you're hitting an error post a gist.
[13:55:14] Paraxial: has joined #ruby
[13:55:17] pragathoys: has left #ruby: ("Closing Window")
[13:55:53] Rapture: has joined #ruby
[13:56:15] Iambchop: TvL2386: It's been years since I've tried (and don't have a Windows box to test on) but it did work the last I tried.
[13:58:18] Iambchop: jlebrech: can you post a gist of the code and full trace of the error?
[13:59:31] Tempesta: has joined #ruby
[13:59:32] al2o3-cr: {}.respond_to? :<< #=> false
[14:00:56] jlebrech: Iambchop: https://pastebin.com/0fqFF3zK
[14:00:57] ruby[bot]: jlebrech: we in #ruby do not like pastebin.com, it loads slowly for most, has ads which are distracting and has terrible formatting. Please use https://gist.github.com
[14:02:17] ruby[bot]: al2o3-cr: I'm terribly sorry, I could not evaluate your code because of an error: NoMethodError:undefined method `[]' for nil:NilClass
[14:02:35] despai: has joined #ruby
[14:04:01] jlebrech: Iambchop: i'm trying to run my first capybara test, it's not my code i'm sure. i've seen this issue with webmock but i've not got mocking set up.
[14:04:18] jlebrech: how would i find out which gem is causing the issue?
[14:05:16] jlebrech: my test runs without js, but as soon as I put js: true i get that error for the same test
[14:07:54] krawchyk: has joined #ruby
[14:13:03] Iambchop: jlebrech: paste the output of "bundle show"
[14:16:13] jlebrech: I might be on to something, different error when i commented out fakeweb
[14:21:18] Inline: has joined #ruby
[14:22:44] Inline: has joined #ruby
[14:23:01] elphe: has joined #ruby
[14:23:12] bak1an: has joined #ruby
[14:24:50] Iambchop: jlebrech: let us know if you figure it out or still have trouble :)
[14:24:51] jlebrech: Iambchop: now chromedriver is running on 9515 but getting unable to connect to chromedriver 127.0.0.1:9516
[14:24:56] orbyt_: has joined #ruby
[14:25:07] jlebrech: how to specify the port?
[14:31:45] kaleido: has joined #ruby
[14:33:10] elphe: has joined #ruby
[14:35:57] Iambchop: jlebrech: are you using the chromedriver-helper gem?
[14:36:43] jlebrech: just selenium-webdriver
[14:36:50] jlebrech: or at least trying to use it
[14:37:52] jlebrech: Iambchop: thanks
[14:38:28] dachi: jlebrech I was getting that yesterday but only when I built my gem
[14:38:34] jlebrech: it opened chrome hehe
[14:38:35] dachi: running with $ruby -Ilib was fine
[14:38:48] dachi: It started to work with executable only after I restarted mac
[14:39:03] dachi: I tried many things though, there was something with Xcode probably
[14:39:19] dachi: I was using headless chromedriver
[14:39:23] jlebrech: it's opening chrome now, is that doing to be a problem for circle ci?
[14:39:26] dachi: with Watir
[14:42:12] jlebrech: Iambchop: thanks a lot i've been banging my head for weeks, as i've been told to write test only on fridays
[14:43:21] elphe: has joined #ruby
[14:43:27] Iambchop: jlebrech: you might be able to use headless chrome in your ci
[15:01:53] j416: has joined #ruby
[15:03:28] elphe: has joined #ruby
[15:04:18] chouhoulis: has joined #ruby
[15:06:42] TvL2386: thx Iambchop
[15:08:40] TheBloke: has joined #ruby
[15:09:32] CheetoH1tlerBad: has joined #ruby
[15:14:07] elphe: has joined #ruby
[15:23:47] gigetoo: has joined #ruby
[15:32:42] nowhere_man: has joined #ruby
[15:33:40] jlebrech: mhh now i could use VCR with capybara as i'm writing integration tests on fridays :)
[15:33:48] elphe: has joined #ruby
[15:33:53] jlebrech: re_record after 7 days :)
[15:36:45] arup_r: has joined #ruby
[15:47:47] rubydoc: has joined #ruby
[15:54:00] elphe: has joined #ruby
[16:02:27] rubydoc: has joined #ruby
[16:06:12] roshanavand: has joined #ruby
[16:07:40] sanscoeur: has joined #ruby
[16:10:43] jcarl43: has joined #ruby
[16:14:09] elphe: has joined #ruby
[16:14:44] darkhanb: has joined #ruby
[16:17:36] moei: has joined #ruby
[16:25:30] roshanavand: has joined #ruby
[16:26:54] impermanence: has joined #ruby
[16:32:28] roshanavand: has joined #ruby
[16:34:24] elphe: has joined #ruby
[16:44:20] cthulchu_: has joined #ruby
[16:45:55] ivanskie: has joined #ruby
[16:46:50] roshanavand: has joined #ruby
[16:50:23] GodFather: has joined #ruby
[16:54:34] elphe: has joined #ruby
[16:56:10] akaiiro: has joined #ruby
[17:04:40] elphe: has joined #ruby
[17:08:27] roshanavand: has joined #ruby
[17:12:24] troulouliou_dev: has joined #ruby
[17:13:05] despai: has joined #ruby
[17:13:32] xfbs: has joined #ruby
[17:14:45] elphe: has joined #ruby
[17:17:01] Dbugger: has joined #ruby
[17:24:54] elphe: has joined #ruby
[17:34:59] elphe: has joined #ruby
[17:43:36] eddof13: has joined #ruby
[17:44:59] elphe: has joined #ruby
[17:55:08] elphe: has joined #ruby
[18:01:19] despai: has joined #ruby
[18:05:11] elphe: has joined #ruby
[18:14:33] GodFather: has joined #ruby
[18:14:46] mroutis: has joined #ruby
[18:17:00] dinfuehr: has joined #ruby
[18:25:18] elphe: has joined #ruby
[18:35:24] elphe: has joined #ruby
[18:36:29] za1b1tsu: has joined #ruby
[18:38:24] eckhardt: has joined #ruby
[18:45:01] ellcs: has joined #ruby
[18:46:01] im0nde: has joined #ruby
[18:49:18] za1b1tsu: has joined #ruby
[18:52:55] voker57: has joined #ruby
[18:52:59] whysthatso: has joined #ruby
[18:55:37] elphe: has joined #ruby
[18:57:59] reber: has joined #ruby
[18:58:06] za1b1tsu: has joined #ruby
[19:01:56] gigetoo: has joined #ruby
[19:08:38] Xiti: has joined #ruby
[19:09:17] tdy: has joined #ruby
[19:15:43] elphe: has joined #ruby
[19:16:28] ShekharReddy: has joined #ruby
[19:24:33] k0mpa: has joined #ruby
[19:26:35] d10n-work: has joined #ruby
[19:27:08] apeiros: has joined #ruby
[19:28:21] roshanavand: has joined #ruby
[19:30:21] venmx: has joined #ruby
[19:31:27] apeiros__: has joined #ruby
[19:35:54] elphe: has joined #ruby
[19:36:03] pskosinski: has joined #ruby
[19:40:29] voolik: has joined #ruby
[19:46:01] elphe: has joined #ruby
[19:52:36] roshanavand: has joined #ruby
[19:56:10] elphe: has joined #ruby
[20:04:09] ellcs: has joined #ruby
[20:06:12] elphe: has joined #ruby
[20:10:14] ellcs: has joined #ruby
[20:11:27] ivanskie: i have a net::ssh or net::ssh::gateway question again :)
[20:18:36] eam: ivanskie: what's up
[20:18:57] zapata: has joined #ruby
[20:19:00] ivanskie: i'm trying to do local forward now, through bastion host
[20:20:03] ivanskie: looking at a couple posts https://stackoverflow.com/questions/4103809/how-to-create-a-ssh-tunnel-in-ruby-and-then-connect-to-mysql-server-on-the-remot and https://stackoverflow.com/questions/37985266/create-a-background-ssh-tunnel-in-ruby and https://stackoverflow.com/questions/13998267/how-to-properly-implement-netssh-port-forwards
[20:20:31] ivanskie: ssh -f my_bastion_host -L $myport:$RDS_HOSTNAME:$RDS_PORT "sleep 10"
[20:21:19] ivanskie: something like that from within ruby. expose the port, print a postgresql::// url in cli to open in postico.. then if it doesn't shutdown on its own, have some other loop to shutdown the tunnel
[20:23:19] ivanskie: i tried this: https://dpaste.de/LMYe it aint working
[20:23:27] eckhardt: has joined #ruby
[20:26:03] ivanskie: @params and params are indeed valid and separate things. so its not a typo in that regard.. uhm was looking at debugger output and it doesn't even try to send anything when i click the postgresql url then. for 127.0.0.1 etc etc
[20:26:23] elphe: has joined #ruby
[20:28:51] ivanskie: am i crazy for trying to do this this way? lol
[20:29:29] kaleido: what are you trying to do? send postgres queries to a server hiding behind an ssh tunnel?
[20:29:44] kaleido: sorry, i'm not a pro by any stretch so i can't determine just from reading your paste.
[20:30:39] ivanskie: our RDS (postgress database on amazon) isn't exposed to the public. But our bastion host has access to it. So I'm trying to open a tunnel to bastion with port forwarding to the RDS endpoint from bastion. if that makes sense?
[20:31:32] akaiiro: has joined #ruby
[20:32:08] ivanskie: "ssh -f my_bastion_host -L $myport:$RDS_HOSTNAME:$RDS_PORT "sleep 10"" when the envars are filled... connects to bastion host, does local port forwarding to 65432 (in case one of us has local postgres server running). then I can just launch postico pointing to 127.0.0.1:56432 with credentials for RDS db. and get in there.
[20:32:36] ivanskie: the "sleep 10" command just executes on bastion, giving me time to open postico. then ssh tunnel doesn't close until i close postico or whatever.
[20:33:46] ivanskie: Im trying to do that now in ruby. because I need to dynamically lookup which bastion/jump box to connect to, and pull correct RDS endpoint and creds based on which app / environment is specified beforehand.
[20:34:58] ivanskie: i've got Teletype (tty) / Thor gem going.
[20:35:13] ivanskie: for command line app
[20:35:28] darkhanb: has joined #ruby
[20:35:30] ivanskie: i have everything done except the tunnel building :(
[20:36:17] ivanskie: i've tried building a system ssh command line string. and something isn't working right.
[20:37:39] ivanskie: oh actually i think i just need to keep track of the PID... then i can kill it in ruby afterwords.. hmmmmmmmmmm anyway im hoping i can do this with net::ssh or net::ssh::gateway gem
[20:38:32] alicef: has joined #ruby
[20:41:29] ivanskie: oh i think i just found the issue
[20:44:53] sanscoeur: has joined #ruby
[20:46:03] ivanskie: i did it!!!!!
[20:46:32] elphe: has joined #ruby
[20:46:33] ivanskie: cake time. unfortunately the one day i actually want to grab a beer. work fridge only has pop :( sad day
[20:47:17] ivanskie: for anyone interested... : https://www.madebylotus.com/blog/handling-port-forwarding-in-ruby/
[20:50:35] ivanskie: fridays are so quiet here
[20:50:55] ivanskie: i noticed in debug output that it says when forwarding agent closes...
[20:51:24] ivanskie: i wonder if there's a way I can have a loop in my code to monitor for that and just quit the app. for now i just have a 5 minute timer, or press any key to quit prompt
[20:53:27] ivanskie: hmm... anyway now im in bonus round. maybe time to code a way to run rake tasks on our apps, without sshing in, etc etc
[20:56:24] eddof13: has joined #ruby
[20:56:37] elphe: has joined #ruby
[21:06:39] zapata: has joined #ruby
[21:06:47] elphe: has joined #ruby
[21:12:42] elphe: has joined #ruby
[21:13:11] druonysus: has joined #ruby
[21:17:17] reber: has joined #ruby
[21:17:17] mochiyoda: has joined #ruby
[21:22:03] alicef: has joined #ruby
[21:23:05] jetchisel: has joined #ruby
[21:24:10] bootstrappm: has joined #ruby
[21:25:00] bootstrappm: (crossposted to #rubyonrails): hey all, I wanted to get a little survey of some members of the community, please feel free to point me in the right direction if I'm in the wrong place. We've been having a hard time filling this position (https://www.linkedin.com/jobs/cap/view/911188581/?pathWildcard=911188581&trk=mcm), and I was wondering where do you think we should advertise to get in front of people that have been
[21:25:00] bootstrappm: using Ruby for several years?
[21:28:51] reber__: has joined #ruby
[21:31:51] reber: has joined #ruby
[21:44:34] alicef: has joined #ruby
[21:47:01] eddof13: has joined #ruby
[21:52:43] havenwood: bootstrappm: In-person in Boston or remote?
[21:52:59] havenwood: bootstrappm: Have you tried the Boston Ruby Meetup?
[21:54:10] elphe: has joined #ruby
[21:55:15] bootstrappm: havenwood: In person, a bit old school
[21:55:20] bootstrappm: and I haven't! I'll look them up now
[21:55:22] eckhardt: has joined #ruby
[21:57:22] ivanskie: is there a way to modify yaml file without destroying the comments?
[22:10:01] beefjoe: has joined #ruby
[22:11:14] JJonah: is it possible to use `cycle` on an array and then extract the nth element using `[]` (or another method) without first converting the Enumerator to an array? Said another way, can you get the nth element of an Enumerator without calling `next` n times?
[22:14:13] elphe: has joined #ruby
[22:21:59] TimHugh: has joined #ruby
[22:31:09] havenwood: JJonah: lazy.drop(index).first
[22:32:36] havenwood: >> 'JJonah'.each_char.cycle.lazy.drop(42).first
[22:32:41] ruby[bot]: havenwood: I'm terribly sorry, I could not evaluate your code because of an error: NoMethodError:undefined method `[]' for nil:NilClass
[22:35:52] TheBloke: has joined #ruby
[22:49:31] tAn: has joined #ruby
[22:53:35] justinstoller: has joined #ruby
[22:53:45] apeiros__: JJonah: ary[nth % ary.length]
[22:54:45] apeiros: no need for expensive iteration when you've maths for the rescue.
[22:54:57] tAn: has joined #ruby
[22:55:54] jenrzzz: has joined #ruby
[22:56:14] RougeR: has joined #ruby
[23:06:57] roshanavand: has joined #ruby
[23:07:46] venmx: has joined #ruby
[23:16:19] alicef: has joined #ruby
[23:16:39] Paraxial: has joined #ruby
[23:16:39] orbyt_: has joined #ruby
[23:16:48] asphyxia: has joined #ruby
[23:20:47] SCHAPiE: has joined #ruby
[23:24:24] roshanavand: has joined #ruby
[23:35:36] fredlinhares: has joined #ruby
[23:35:38] alicef: has joined #ruby
[23:38:15] eddof13: has joined #ruby
[23:38:27] eckhardt: has joined #ruby
[23:42:34] RougeR: has joined #ruby
[23:57:03] dviola: has joined #ruby
[23:57:48] jordanm: has joined #ruby