<FromGitter>
<Blacksmoke16> @jgaskins what's the status of the OTLP shard you were working on?
notzmv has joined #crystal-lang
ur5us has joined #crystal-lang
ur5us has quit [Client Quit]
<FromGitter>
<spTorin> @riza but one of them must be derivation of 10^3. In your link: ⏎ one gibibyte 1 GiB = 230 B = 1 073 741 824 B ⏎ one gigabyte 1 GB = 109 B = 1 000 000 000 B
<FromGitter>
<spTorin> In crystal docs: ⏎ This method by default uses the IEC standard prefixes (Ki, Mi, Gi, Ti, Pi, Ei, Zi, Yi) based on powers of 1000
taupiqueur has quit [Read error: Connection reset by peer]
taupiqueur has joined #crystal-lang
taupiqueur has quit [Remote host closed the connection]
taupiqueur has joined #crystal-lang
taupiqueur has quit [Ping timeout: 245 seconds]
deavmi has quit [Ping timeout: 245 seconds]
deavmi has joined #crystal-lang
<FromGitter>
<skinnyjames> Hey all ⏎ I'm trying to dynamically raise Exceptions from a macro, but when I instantiate the subclassed exception with a message, I get this error: ⏎ ```Error: wrong number of arguments for 'Exception#initialize' (given 1, expected 2)``` ⏎ ⏎ Can anyone see what i'm doing incorrectly? ... [https://gitter.im/crystal-lang/crystal?at=6161a38538377967f4418b6a]
<FromGitter>
<Blacksmoke16> can you make a playground link that reproduces it?
<FromGitter>
<skinnyjames> this will likely be a little less performant right?
<FromGitter>
<skinnyjames> I can make the hashmap an array instead if that's easier
<FromGitter>
<Blacksmoke16> probably negligible, no that would be worse i think
<FromGitter>
<skinnyjames> ah okay
<FromGitter>
<Blacksmoke16> could benchmark it if you want, but i prob wouldn't worry about it to much
<FromGitter>
<Blacksmoke16> ofc it's all moot if you remove the need to convert arbitrary strings into exceptions. i.e. if you already know that you want to raise an unknown method exception because of the string, could just do `raise UnknownMethodException.new` versus going thru the case at all
<FromGitter>
<Blacksmoke16> but i assume there is more to it than this example
<FromGitter>
<skinnyjames> definitely did the trick!
<FromGitter>
<skinnyjames> i was originally iterating, but I'm just being lazy
<FromGitter>
<skinnyjames> thanks! I'm pretty excited. I've been looking at ruby's Spinach library, and I would like to implement a similar test runner in Crystal
<FromGitter>
<Blacksmoke16> sounds like quite the challenge
<FromGitter>
<skinnyjames> yeah, I'll probably be bugging you all a little bit :) ⏎ Crystal is definitely my favorite language, so I hope that testing can be a bit more first class
<FromGitter>
<Blacksmoke16> in regards to E2E testing you mean?
<FromGitter>
<Blacksmoke16> main downside is ofc it's JS, but will be a large undertaking to try and match them imo
<FromGitter>
<skinnyjames> cypress is cool, but the api is more cumbersome
<FromGitter>
<skinnyjames> the one thing that I really like about it, is by mocking the network deps, you can turn a unit test suite into an e2e test suite with a switch
<FromGitter>
<Blacksmoke16> they did just add in the #intercept method, which makes that side of it easier more powerful
<FromGitter>
<Blacksmoke16> i also really like their tooling. How you can see what's going on and interact with snapshots of the UI at each point
<FromGitter>
<skinnyjames> `driver.findElement(By.id("username");).sendKeys(username);` ⏎ vs ⏎ `browser.element(id: /username/i).set(username)`
<FromGitter>
<skinnyjames> yeah, I think tooling could be better in selenium, but selenium 4 supports video now
<FromGitter>
<Blacksmoke16> wait, neither of those looks like cypress
<FromGitter>
<Blacksmoke16> `cy.get('#username').click();` is what im familiar with
<FromGitter>
<skinnyjames> oh lol
<FromGitter>
<skinnyjames> I was looking at the wrong docs
<FromGitter>
<skinnyjames> I've built abstractions around the query selector api, but it never seems to be the best
<FromGitter>
<skinnyjames> I'm also a big fan of page object, so I may be biased :)
<FromGitter>
<Blacksmoke16> i think in the ideal world of cypress you'd do something like `cy.get('[data-test=some-unique-id]')` such that you're not relying upon classes/id/order etc
<FromGitter>
<skinnyjames> collections don't usually have unique ids though
<FromGitter>
<Blacksmoke16> but, for this example it would be like `cy.get('input').eq(2)`
<FromGitter>
<Blacksmoke16> er `.eq(1)`, starts a `0`
<FromGitter>
<Blacksmoke16> collections of objects from the db or?
<FromGitter>
<skinnyjames> like a list
<FromGitter>
<Blacksmoke16> true true, depends on the context. A simple list of strings wouldn't, but a list of something fetched from the db would
deavmi has quit [Ping timeout: 260 seconds]
taupiqueur has quit [Ping timeout: 252 seconds]
taupiqueur has joined #crystal-lang
notzmv has quit [Ping timeout: 260 seconds]
deavmi has joined #crystal-lang
deavmi has quit [Read error: Connection reset by peer]
deavmi has joined #crystal-lang
taupiqueur has quit [Ping timeout: 252 seconds]
taupiqueur has joined #crystal-lang
notzmv has joined #crystal-lang
adam12 has quit [Quit: Ping timeout (120 seconds)]
adam12 has joined #crystal-lang
riza has quit [Ping timeout: 245 seconds]
riza has joined #crystal-lang
greenbigfrog has quit [Ping timeout: 245 seconds]
greenbigfrog has joined #crystal-lang
mps has left #crystal-lang [#crystal-lang]
void09_ has joined #crystal-lang
void09 has quit [Remote host closed the connection]
taupiqueur has quit [Remote host closed the connection]
taupiqueur has joined #crystal-lang
antoszka has joined #crystal-lang
Volk has quit [Read error: Connection reset by peer]