00:00:10 | Araq | politics is always #im-offtopic |
00:00:58 | nasusiro | Araq: true. I just wanted a quick review of what's going on in Austria, that's all |
00:01:24 | nasusiro | because through news websites and TV, they speak gibberish that I don't understand |
00:05:12 | nasusiro | Araq: apart from Nim itself, what is the largest Nim project that people have reported it to you? |
00:05:17 | Araq | nasusiro, the law is only about allowing employees to work as much as 12 hours |
00:05:30 | nasusiro | Araq: ...are they mad or something?! O.o |
00:05:42 | nasusiro | 8 hours is already exhausting, not 12! |
00:06:12 | nasusiro | eventually they will start paying people the same amount of money they would get with traditional 8 hours |
00:06:21 | nasusiro | it's like going back to 1936 |
00:06:28 | nasusiro | anyway, that's the end of politics |
00:06:30 | nasusiro | back to Nim now |
00:09:37 | * | dddddd quit (Remote host closed the connection) |
00:11:52 | Araq | nasusiro, some computer algebra system with 300K loc, but it's closed source and I may misremember the number |
00:12:31 | nasusiro | I guess it gave you an incredible satisfaction when they shared this info with you :D |
00:12:40 | Araq | some games around maybe 100K loc. |
00:12:48 | Araq | (closed source, sorry) |
00:13:40 | nasusiro | I don't mind whether they are closed source or opened |
00:14:06 | Araq | and one I'm eager to announce where they replaced their C++ server with Nim |
00:14:27 | Araq | with a code reduction of a factor of 3 or 4. |
00:15:43 | nasusiro | even though I'm a die-hard C++ lover, I do understand them for doing so |
00:16:03 | nasusiro | and let me tell you this: I "know" the basics of the basics |
00:16:17 | nasusiro | C++ must be the only language that cannot be taught completely |
00:16:44 | nasusiro | but so far with Nim I feel very comfortable learning it. |
00:22:07 | * | elrood quit (Quit: Leaving) |
00:23:09 | * | fjvallarino quit (Remote host closed the connection) |
00:23:35 | * | fjvallar_ joined #nim |
00:27:45 | * | fjvallar_ quit (Ping timeout: 248 seconds) |
00:46:55 | FromGitter | <kayabaNerve> Is it weird if I group ⏎ Nim, Elm, Elixir, Crystal ⏎ BUT ALSO D? |
00:48:09 | Araq | no. |
00:48:27 | ldlework | Well Elm is pretty unique there |
00:48:32 | Araq | but it's weird Rust is missing from your list |
00:48:37 | nasusiro | Araq: I wanted to ask. How come you chose Nimrod and then renamed it to Nim? What's up with Nimrod? |
00:48:45 | Araq | marketing. |
00:48:50 | nasusiro | meaning? |
00:48:54 | ldlework | nimrods didn't understand nimrod |
00:49:05 | FromGitter | <kayabaNerve> Eh. Rust too if you want. It's my lift of... new languages I guess |
00:49:07 | nasusiro | I have no idea what Nimrod is |
00:49:12 | FromGitter | <kayabaNerve> Languages not accepted by the norm |
00:49:17 | ldlework | nasusiro: you nimrod |
00:49:19 | ldlework | :) |
00:49:21 | FromGitter | <kayabaNerve> Nimrod = Nim's original langauge or a fan of Nim |
00:49:22 | FromGitter | <kayabaNerve> Or an idiot |
00:49:30 | FromGitter | <kayabaNerve> *my group of |
00:49:33 | ldlework | or a great hunter king |
00:49:49 | nasusiro | a hunter king? |
00:50:15 | nasusiro | is it a character from a video game or something? |
00:50:27 | ldlework | https://en.wikipedia.org/wiki/Nimrod |
00:51:05 | nasusiro | ah I see |
00:51:18 | nasusiro | so what was the original objective of choosing this guy's name? |
00:51:37 | nasusiro | the rebellious concept? |
00:51:48 | * | icebattle quit (Quit: leaving) |
00:51:55 | Araq | king, godlike, built the tower of Babel, you get the idea |
00:52:29 | Araq | Babel a reference for Nim allowing every language concept to be expressed because macros |
00:52:45 | nasusiro | ah OK |
00:54:25 | FromGitter | <rayman22201> No worse than Git as a name for a version control system lol |
00:55:28 | nasusiro | rayman22201: trust me, there are worse things out there lol |
00:55:29 | nasusiro | https://en.wikipedia.org/wiki/WTFPL |
00:56:24 | FromGitter | <rayman22201> lol. Exactly. That's what I mean. |
00:57:04 | FromGitter | <rayman22201> Though I agree with the marketing decision to shorten it to Nim |
00:57:17 | nasusiro | yes, Nim sounds better than Nimrod |
00:57:25 | nasusiro | Nimrod sounds aggressive |
00:58:42 | FromGitter | <kayabaNerve> NIMROD |
00:58:46 | FromGitter | <kayabaNerve> NIMROD NIMROD NIMROD |
00:58:53 | FromGitter | <kayabaNerve> NIM ⏎ NIM NIM NIM |
00:59:00 | FromGitter | <kayabaNerve> Insult/Pokemon chirp? |
00:59:08 | FromGitter | <rayman22201> lol |
00:59:58 | nasusiro | it have been named MLP after My Little Pony! |
01:01:59 | FromGitter | <kayabaNerve> no |
01:02:01 | FromGitter | <kayabaNerve> no |
01:02:01 | FromGitter | <kayabaNerve> plz no |
01:02:04 | FromGitter | <kayabaNerve> ill do anything |
01:02:12 | FromGitter | <kayabaNerve> ill make the compiler 1.0 myself |
01:02:13 | FromGitter | <kayabaNerve> plz no |
01:02:31 | * | fjvallarino joined #nim |
01:02:33 | nasusiro | there you have it Araq, I have found you the ultimate volunteer for v1.0! |
01:05:24 | FromGitter | <rayman22201> Who knew it would be so easy? :-P |
01:07:19 | * | ashleyk_ joined #nim |
01:07:51 | FromGitter | <kayabaNerve> I didn't promise a good 1.0 |
01:08:35 | nasusiro | it doesn't matter, v1.0 is on its way now ^_^ |
01:09:43 | * | ashleyk__ quit (Ping timeout: 250 seconds) |
01:10:48 | nasusiro | anyway folks, I'm off for today. Keep up the good work everyone! |
01:10:51 | * | nasusiro quit (Quit: Quitting for now...) |
01:13:44 | * | BitPuffin quit (Remote host closed the connection) |
01:17:08 | * | ng0_ joined #nim |
01:20:07 | * | ng0 quit (Ping timeout: 250 seconds) |
01:20:12 | * | krux02 quit (Read error: Connection reset by peer) |
02:48:33 | * | leorize joined #nim |
03:00:56 | * | endragor joined #nim |
04:03:19 | * | endragor quit (Remote host closed the connection) |
04:31:24 | * | fjvallarino quit (Remote host closed the connection) |
04:31:31 | * | fjvallarino joined #nim |
04:34:30 | Sargun | rayman22201 I'm here. |
04:44:48 | * | lompik joined #nim |
04:55:47 | * | NimBot joined #nim |
04:57:24 | FromGitter | <rayman22201> Hi Sargun! Thanks for responding on your post :-) |
05:06:11 | FromGitter | <kayabaNerve> What's the best UI lib for Nim? Must be cross platform for the big 3 OSs. Windows, Linux, and BSD. ⏎ ⏎ Jokes on BSD. Mac OS. If it has BSD compatibility though... |
05:12:37 | * | fjvallarino quit (Remote host closed the connection) |
05:13:05 | * | fjvallarino joined #nim |
05:16:49 | * | miran joined #nim |
05:18:00 | * | fjvallarino quit (Ping timeout: 260 seconds) |
05:32:13 | FromGitter | <sclee15> You may for get the U |
05:33:23 | FromGitter | <sclee15> UI bindings for NIm |
05:34:48 | FromGitter | <citycide> @kayabaNerve nigui & nimx are probably the best ones. I like nigui but it's kind of stagnant |
05:50:19 | * | fjvallarino joined #nim |
05:51:56 | * | mal`` quit (Quit: Leaving) |
06:04:31 | * | mal`` joined #nim |
06:25:55 | * | xet7 quit (Quit: Leaving) |
06:37:50 | FromGitter | <bevo009> just tried nim secret after seeing earlier comments |
06:38:04 | FromGitter | <bevo009> seems completely broken, unless I'm missing a trick |
06:38:48 | FromGitter | <kayabaNerve> Is it just a Nim REPL? |
06:39:08 | FromGitter | <bevo009> apparently, but it just borks my console |
06:39:30 | FromGitter | <bevo009> how do you even exit without a restart? |
06:40:30 | FromGitter | <bevo009> maybe that's the secret :) |
06:55:13 | FromGitter | <kayabaNerve> Why is it named secret? |
06:55:46 | FromGitter | <Quelklef> that's the secret |
06:57:47 | FromGitter | <rayman22201> It's named secret because it's really broken and @Araq doesn't want people to use it lol |
07:01:37 | FromGitter | <bevo009> It worked like a year ago, mostly, apart from modules that depend on C code |
07:01:40 | FromGitter | <bevo009> https://github.com/nim-lang/Nim/issues/5886 |
07:02:01 | FromGitter | <bevo009> completely broken now though |
07:02:40 | FromGitter | <bevo009> there's still iNim :) |
07:17:21 | * | lompik quit (Ping timeout: 248 seconds) |
07:19:48 | * | nasusiro joined #nim |
07:22:38 | * | nkr joined #nim |
07:32:10 | * | Trustable joined #nim |
07:35:13 | FromGitter | <Varriount> @bevo009 It works fine for the small snippets I throw at it. |
07:44:33 | * | nkr quit (Ping timeout: 248 seconds) |
07:55:26 | * | Trustable quit (Remote host closed the connection) |
08:00:24 | FromGitter | <bevo009> now it works here too |
08:00:35 | FromGitter | <bevo009> well that's weird |
08:10:08 | FromGitter | <bevo009> I've got another computer that iNim isn't installed on, I'll use nim secret instead...like being back at python, js, ruby etc |
08:12:19 | nasusiro | question: is this message considered a segfault? "SIGSEGV: Illegal storage access. (Attempt to read from nil?)" |
08:16:17 | FromGitter | <mratsim> yes |
08:16:33 | FromGitter | <mratsim> it’s when you try to dereference a nil pointer |
08:17:27 | FromGitter | <mratsim> If you are using ref objects, check that you properly initialize them with new result, before accessing its fields |
08:17:56 | FromGitter | <bevo009> same msg if you run .add on an uninitialized sequence |
08:18:02 | FromGitter | <mratsim> or use constructors ObjectType(field1: foo, field2: bar) it will implicitly initialize them for you |
08:18:27 | FromGitter | <mratsim> normally on devel seq and string are automatically not nil @bevo009 |
08:19:07 | FromGitter | <mratsim> @Araq, I think you have to think about a deprecation strategy, seems like this RFC is quite popular: https://github.com/nim-lang/Nim/issues/8208 |
08:19:11 | FromGitter | <bevo009> I'm still on last release |
08:21:44 | nasusiro | I managed to get that aforementioned error message by doing a silly thing inside my local nim.cfg |
08:23:56 | FromGitter | <bevo009> @mratsim So this part of the tutorial is changing? ⏎ "Sequence variables are initialized with nil. However, most sequence operations cannot deal with nil (leading to an exception being raised) for performance reasons. Thus one should use empty sequences @[] rather than nil as the empty value. But @[] creates a sequence object on the heap, so there is a trade-off to be made here." |
08:23:56 | nasusiro | all I did was to add the following line in it: nimcache=getCurrentDir() |
08:24:01 | FromGitter | <mratsim> is it crashing at compile-time or runtime? if compile-time it’s a bug in the compiler, probably related to the not nil change |
08:24:20 | FromGitter | <mratsim> @bevo009 yes |
08:24:55 | FromGitter | <mratsim> you can use newSeqUninitialized if you want. |
08:25:32 | FromGitter | <bevo009> so there wasn't much of a tradeoff really I take it? |
08:25:46 | FromGitter | <mratsim> @bevo009 seems like it’s still gated: https://github.com/nim-lang/Nim/blob/devel/changelog.md |
08:26:58 | FromGitter | <mratsim> the perf reason if that to support nil, each proc would need “if cpp.isNil: initialize(); doSomething”. |
08:27:11 | FromGitter | <bevo009> Thanks, I'll note that newSeqUninitialized down |
08:27:33 | FromGitter | <mratsim> in a tight loop, all those if statement would become a bottleneck |
08:32:49 | nasusiro | can someone tell me where to find the list of predefined .cfg variable names? All I know is $project_path |
08:43:34 | Araq | mratsim: with the fine grained .experimental feature, we have a nice path forward |
08:43:59 | Araq | we can enable your solution with .experimental and then gradually use it everywhere and then make it the default |
08:44:39 | FromGitter | <mratsim> sounds good |
08:44:59 | nasusiro | still up Araq? |
08:50:30 | FromGitter | <bevo009> @mratsim so uninitialized string default will be "", empty string in 0.19.0? ⏎ are typetraits planned to merge into system, or is that rumour |
08:53:54 | * | nsf joined #nim |
09:01:28 | * | rosshadden quit (Read error: Connection reset by peer) |
09:02:00 | dom96 | Spammers love to advertise cheap kitchens on our forum |
09:03:38 | * | rosshadden joined #nim |
09:05:16 | nasusiro | dom96: lol. do they look good though? |
09:05:42 | dom96 | cheapkitchens.uk.com |
09:05:47 | dom96 | Judge for yourself :P |
09:06:08 | nasusiro | they look pretty decent I would say |
09:06:33 | nasusiro | and they charge quite cheap I have to admit |
09:06:54 | dom96 | Woulnd't be surprised if it's a complete scam |
09:07:02 | nasusiro | dom96: yeah, most probably |
09:07:37 | nasusiro | dom96: by the way, is there any page where it lists all .cfg variables I could potentially use? |
09:07:54 | dom96 | nim --help? |
09:08:11 | nasusiro | nope |
09:08:19 | nasusiro | variables of $project_path format |
09:08:29 | dom96 | oh, no idea |
09:08:36 | nasusiro | I'm trying to set a different path for nimcache and cannot make it work |
09:08:42 | nasusiro | I even managed to crash nim lol |
09:10:55 | nasusiro | I have tried to add "nimcache=getCurrentDir()" in my local nim.cfg and crashed nim lol |
09:11:13 | dom96 | report that as an issue |
09:11:25 | nasusiro | right away sir! |
09:13:13 | nasusiro | double-checked it with a vanilla demo and reproduces the same behavior. |
09:19:24 | Araq | can we also kill 'defer' please? |
09:20:26 | dom96 | lol |
09:20:27 | nasusiro | I'm not good with terminology Araq |
09:20:46 | Araq | https://forum.nim-lang.org/t/4022 |
09:20:55 | nasusiro | ticket #8236 just got opened |
09:21:40 | dom96 | fix defer? |
09:22:25 | FromGitter | <mratsim> yeah, fix defer |
09:22:58 | Araq | it's not fixable. |
09:23:08 | Araq | the syntax doesn't have enough information. |
09:23:26 | miran | what are the advantages of defer, compared to try-finally? |
09:23:54 | FromGitter | <mratsim> are there cases when starting the try block at the same line as the defer statement doesn’t work? |
09:24:07 | FromGitter | <mratsim> @miran, it’s less noisy |
09:24:42 | FromGitter | <mratsim> you avoid indentation hell |
09:24:44 | FromGitter | <bevo009> @dom96 before the reaper forum got redone, they had a fake general discussion page one level above as a spamtrap...only the spammers posted in there |
09:25:09 | dom96 | bevo009: nice. |
09:25:13 | miran | @mratsim doesn's seem like much of an advantage to me, to be honest |
09:25:49 | nasusiro | Araq: how does Nim's defer compare to that of Golang's? |
09:26:04 | Araq | I think it's exactly the same |
09:26:08 | FromGitter | <mratsim> Some people like indentation: https://github.com/lougehrig10/C-Deep-Reinforcement-Learning/blob/master/src/NeuralNetwork/neuralNet.c |
09:27:03 | FromGitter | <mratsim> also you put the defer right next to the acquiring the resource, i.e. you can train that as a muscle/reflex |
09:27:05 | nasusiro | Araq: then I guess your example in 4022 is wrong. defer should come first and then setupFoo() should follow |
09:27:11 | FromGitter | <mratsim> try/finally has more friction |
09:27:46 | Araq | mratsim: usually you would just use a destructor and avoid it altogether |
09:28:12 | FromGitter | <mratsim> Where can i find those famed beasts ?;) |
09:28:26 | Araq | and if a destructor can't be used, try-finally is good enough and clearer |
09:28:58 | FromGitter | <mratsim> I agree destructors are better |
09:29:08 | FromGitter | <mratsim> but will they be triggered on exceptions? |
09:29:35 | Araq | sure they will. |
09:29:40 | dom96 | Maybe we should adopt the Python way (TM)? |
09:29:44 | FromGitter | <mratsim> great |
09:29:59 | Araq | the Python way is a 'with' template |
09:30:03 | dom96 | yes |
09:30:13 | Araq | well sure |
09:30:14 | dom96 | But we need that in the stdlib |
09:30:19 | Araq | can add it to sugar.nim |
09:30:30 | Araq | but I hate 'defer' now |
09:30:32 | FromGitter | <mratsim> it’s in the manual iirc. |
09:30:52 | Araq | was hard to implement, it's still a bit buggy and leads to unclear and buggy code |
09:31:09 | dom96 | I don't really care that much about it personally |
09:31:19 | Araq | and it was against Nim's design. |
09:31:21 | dom96 | AFAIK async still doesn't support it |
09:31:27 | Araq | yep. :P |
09:31:42 | FromGitter | <mratsim> well just kill it, RFC on the tracker and then deprecate it |
09:31:43 | Araq | whenever we do something against Nim's design, it bites us :P |
09:32:07 | FromGitter | <mratsim> “when we do something it bites us” FTFY |
09:32:53 | FromGitter | <mratsim> The Python way: https://nim-lang.org/docs/manual.html#templates-passing-a-code-block-to-a-template |
09:34:04 | FromGitter | <mratsim> but that supposes we have a concept of “open” and “close” for all resources you can acquire (files, socket, database …) |
09:34:51 | Araq | destructors are that concept. |
09:34:54 | dom96 | Araq: I'm going to fix c2nim and protect the main branch from pushes |
09:34:54 | FromGitter | <mratsim> since open would have different args, you can’t just use a generic template. |
09:35:03 | FromGitter | <mratsim> so destructors are just better |
09:35:06 | Araq | dom96: I fixed it yesterday |
09:35:12 | Araq | what's wrong with it? |
09:35:19 | dom96 | No you didn't. The tests are still failing. |
09:35:27 | Araq | they are green on Windows. |
09:35:30 | dom96 | You've broken the tests and then left them broken for months |
09:35:43 | Araq | probably some OS specific code in there that I need to fix |
09:35:54 | Araq | I updated the tests. |
09:35:58 | Araq | yesterday. |
09:36:10 | dom96 | You've broken installation via Nimble, that's the problem |
09:36:49 | Araq | well travis agrees with you |
09:36:56 | Araq | need to make c2nim not OS specific |
09:37:06 | dom96 | so from now on it's PRs always, and only when they pass they'll be mergeable |
09:38:21 | Araq | doesn't work for c2nim |
09:38:45 | Araq | as the tests were already broken and looking at travis |
09:38:55 | Araq | --noBabelPath |
09:39:06 | Araq | this stuff is old... |
09:39:49 | dom96 | Not sure why that means it doesn't work for c2nim |
09:39:58 | Araq | it was red before |
09:40:08 | Araq | I create a PR |
09:40:13 | Araq | still red and you reject it |
09:40:35 | dom96 | yes, that's the point |
09:40:58 | Araq | ok, but the real problem is that c2nim depends on compiler/renderer |
09:41:08 | Araq | and so changes to Nim can change c2nim's output |
09:41:25 | dom96 | yes, which is why we pin the compiler commit hash |
09:41:31 | dom96 | and why we use nimble to build it |
09:41:41 | Araq | ah ok. |
09:41:42 | dom96 | so we're not constantly after a moving target |
09:41:53 | Araq | alright then |
09:41:54 | FromGitter | <mratsim> @bevo009 the plan is to make not nil the default, but just monitor the changeling to see if it will be in next rel or not |
09:41:57 | * | Vladar joined #nim |
09:43:46 | * | noonien joined #nim |
09:47:41 | * | xet7 joined #nim |
09:49:04 | Araq | dom96: please update the compiler's hash then |
09:49:19 | dom96 | Yes, I'm doing that |
09:49:31 | Araq | ok thanks |
09:49:56 | Araq | btw Nimble might have a new regression |
09:50:35 | Araq | yeah, a serious one |
09:51:01 | Araq | ./src/nimblepkg/nimscriptsupport.nim |
09:51:01 | Araq | 80: if x.kind == nkPar and x.len == 2 and x[0].isStrLit and x[1].isStrLit: |
09:51:21 | Araq | this needs to be x.kind in {nkTupleConstr, nkPar} |
09:51:53 | dom96 | what issue does it cause? |
09:51:56 | Araq | in fact, I wonder why it worked at all... :-) |
09:52:18 | Araq | I think requires can also be used with tuples |
09:52:25 | dom96 | https://travis-ci.org/nim-lang/c2nim/builds/401178838#L1870 |
09:52:31 | dom96 | Still seeing differences |
09:52:39 | Araq | ("packageName", "version") |
09:53:16 | dom96 | meh, I don't really want that to work anyway |
09:53:26 | dom96 | What's the point when `requires "packageName version"` works? |
09:54:33 | Araq | it's cleaner IMO. |
09:54:57 | dom96 | The c2nim test-suite is incredibly annoying |
09:55:04 | dom96 | locally it shows even more errors |
09:55:44 | Araq | the hash computation is based on times.nim and times.nim was changed quite a bit |
09:55:56 | Araq | it's just bad, we need to change it |
09:56:29 | dom96 | It's missing a bunch of empty lines too |
09:56:30 | dom96 | locally |
09:56:46 | Araq | I think locally you just use the wrong compiler version |
09:57:19 | Araq | also, sorry, but c2nim's test suite is not nearly as annoying as Nimble's :P |
09:57:33 | Araq | Nimble tests take forever on my machine |
10:00:48 | dom96 | ahh, it's because the tester uses c2nim from my path |
10:00:59 | dom96 | That's a poor choice :P |
10:02:02 | miran | sorry to interupt, but a quick question - is it expected that (closure) iterators are 2x slower than procs? |
10:05:03 | dom96 | probably |
10:05:09 | Araq | miran: that seems a good number, in fact |
10:06:02 | miran | ok, thanks guys |
10:08:56 | FromGitter | <mratsim> I did a bench somewhere |
10:09:05 | FromGitter | <mratsim> it was worse than than on it |
10:12:20 | miran | i had no clue! ok, back to using procs :) |
10:13:47 | * | BitPuffin joined #nim |
10:23:13 | FromGitter | <mratsim> @retsyo I found something from CERN to process High Energy Physics abstract and automatically tag them: https://github.com/inspirehep/magpie |
10:33:24 | * | elrood joined #nim |
10:39:33 | * | miran quit (Ping timeout: 265 seconds) |
10:43:27 | * | yglukhov[i] joined #nim |
10:47:11 | FromGitter | <mratsim> I’m trying to parse/scrap webpages, why are there so many xml parsers? https://nim-lang.org/docs/parsexml.html, https://nim-lang.org/docs/xmltree.html, https://nim-lang.org/docs/xmlparser.html, https://nim-lang.org/docs/xmldomparser.html |
10:48:23 | FromGitter | <mratsim> oh and that: https://nim-lang.org/docs/xmldom.html |
10:49:17 | Yardanico | @mratsim usually you would use parsexml and xmltree |
10:49:27 | Yardanico | and yeah, you can try to use nimquery for parsing via css selectors |
10:50:37 | FromGitter | <mratsim> for now I’m trying to understand with the minimum tool, that’s like a completely new domain for me so I’m approaching like I did for deep learning. |
10:51:19 | FromGitter | <mratsim> there is this as well for css selectors it seems: https://github.com/OpenSystemsLab/q.nim |
10:51:33 | FromGitter | <mratsim> but AFAIK CSS selectors are less powerful than XPath |
10:52:51 | FromGitter | <GULPF> If it's html you're parsing you should use htmlparser, not the XML ones |
10:53:14 | Yardanico | @mratsim but css selectors are easier to use than parsehtml :) |
10:53:18 | FromGitter | <mratsim> Yeah I’m looking there to try to make sense of this: https://nim-lang.org/docs/lib.html#pure-libraries-xml-processing |
10:53:28 | FromGitter | <mratsim> I don’t really care about easy :P |
10:54:03 | FromGitter | <GULPF> XPath is probably more powerful, but CSS selectors are more specialized for html |
10:55:31 | FromGitter | <mratsim> I see, I’ll check it out, since you’re the author of Nim query @GULPF, what is the state of your lib vs https://github.com/OpenSystemsLab/q.nim? (going AFK) |
10:58:26 | * | yglukhov[i] quit (Remote host closed the connection) |
10:59:01 | * | yglukhov[i] joined #nim |
11:01:48 | FromGitter | <GULPF> @mratsim Nimquery has support for more selectors and is more actively maintained. I subjectively like the API better as well, but that's no surprise since I implemented it :P |
11:03:47 | * | yglukhov[i] quit (Ping timeout: 256 seconds) |
11:07:20 | dom96 | mratsim: You should use htmlparser |
11:07:40 | dom96 | Alternatively if you want to do it properly: https://github.com/dom96/webdriver |
11:08:04 | dom96 | You'll end up using a full browser but you'll get 100% compatibility with JS and all weird HTML quirks |
11:14:07 | * | BitPuffin quit (Remote host closed the connection) |
11:27:39 | livcd | What is the most usable ORM pkg out there atm ? |
11:35:04 | * | lompik joined #nim |
11:39:44 | * | yglukhov[i] joined #nim |
11:40:27 | * | BitPuffin joined #nim |
11:56:37 | * | yglukhov[i] quit (Remote host closed the connection) |
11:56:50 | * | pomdepin joined #nim |
11:57:51 | * | dorelix quit (Read error: Connection reset by peer) |
11:58:29 | * | dorelix joined #nim |
12:00:42 | * | thomasross_ joined #nim |
12:01:39 | * | xet7 quit (Quit: Leaving) |
12:03:01 | * | pomdepin quit (Quit: Page closed) |
12:03:10 | * | thomasross quit (Ping timeout: 265 seconds) |
12:04:27 | * | ng0_ is now known as ng0 |
12:05:38 | FromGitter | <kaushalmodi> dom96: I agree with @mratsim though, are are too many similarly named stdlibs.. |
12:06:44 | FromGitter | <kaushalmodi> Both parsexml and xmlparsers libs? Shouldn't they be merged? ( I have not looked what both do by the way. So merging them is a dumb idea, then may be name them differently?) |
12:07:10 | FromGitter | <kaushalmodi> *xmlparser |
12:07:59 | * | aziz joined #nim |
12:12:23 | * | nsf quit (Quit: WeeChat 2.1) |
12:15:27 | * | aziz quit (Ping timeout: 240 seconds) |
12:19:36 | FromGitter | <mratsim> @dom96 webdriver is cool as well |
12:20:14 | FromGitter | <Vindaar> @Araq @dom96 is `stmt` and `expr` finally removed from the language? |
12:21:36 | FromGitter | <mratsim> basically I’m exploring scraping because it’s the only way to get data at scale and being able to scrap say marketplaces or social networks and apply data science (image and text analysis) in an easy way would be a killer use case and I know several startups that would be interested. |
12:26:02 | elrood | just don't forget to ask for permission if you're scraping at scale |
12:34:04 | FromGitter | <mratsim> Isn’t that described in robots.txt? |
12:34:35 | FromGitter | <mratsim> I’ve raised https://github.com/nim-lang/Nim/issues/8238 for the html/xml parser issues. |
12:38:10 | FromGitter | <Vindaar> ok, I'm really confused. e.g. `SomeReal` is now also throwing `undeclared identifier` errors, instead of deprecated hints. Is that an issue with deprecation or what happened? Getting the same thing on 2 computers |
12:38:48 | FromGitter | <mratsim> someone deleted it too early? :p |
12:38:58 | FromGitter | <Vindaar> It just broke arraymancer for me :P |
12:49:43 | FromGitter | <Vindaar> https://github.com/mratsim/Arraymancer/pull/256 |
12:49:52 | ng0 | I'd simply write a crawler+scraper which respects the codex beyond robots.txt. good user-agent, etc |
12:56:49 | FromGitter | <mratsim> @Vindaar Nim is broken here, SomeFloat doesn’t exist on stable so I can’t merge your PR. |
12:57:01 | FromGitter | <Vindaar> oh, forgot about that |
12:57:31 | FromGitter | <Vindaar> well, it can stay there and merge it later or close it. :) |
12:57:49 | FromGitter | <mratsim> I can merge it when 0.19 stable is out. |
12:57:55 | FromGitter | <Vindaar> :) |
12:58:10 | FromGitter | <Vindaar> but you're seeing the same behavior now? |
12:58:17 | FromGitter | <mratsim> but since it changes everything I will have to redo the PR anyway if I add new stuff so we’ll see. |
12:58:28 | FromGitter | <Vindaar> yeah |
12:58:37 | FromGitter | <mratsim> I didn’t check. I’m trying not too update too often because it breaks work :P |
12:58:50 | FromGitter | <Vindaar> haha, good point |
13:01:11 | FromGitter | <mratsim> My guess is that there was a plan to remove the {.deprecated: TFooType, Footype.} Pragma and SomeReal was caught in that |
13:01:30 | * | miran joined #nim |
13:01:47 | FromGitter | <Vindaar> nope, found it: ⏎ https://github.com/nim-lang/Nim/commit/c7298561c199255facc562402700322360408179 |
13:01:58 | FromGitter | <mratsim> @Araq ^ |
13:04:05 | FromGitter | <kaushalmodi> @Vindaar You can do this for SomeFloat support on older Nim: https://github.com/kaushalmodi/strfmt/commit/8701480cc9eac5e04389a392bf50bb2962016e7e |
13:05:09 | FromGitter | <mratsim> @Vindaar https://github.com/nim-lang/Nim/pull/8239 |
13:07:41 | FromGitter | <Vindaar> @kaushalmodi thanks, yes, that's a possibility. :) ⏎ @mratsim ok. If Araq decides to not merge your PR for some reason, I'll add your suggestion to my PR |
13:12:10 | * | smt quit (Ping timeout: 256 seconds) |
13:14:03 | * | sz0 joined #nim |
13:14:27 | dom96 | Okay, definitely looks like a mistaken removal |
13:14:29 | dom96 | I'll merge it |
13:14:38 | FromGitter | <Vindaar> :) |
13:16:51 | * | dddddd joined #nim |
13:40:04 | FromGitter | <mratsim> btw @dom96, when you merge a PR with just “merge”, the history is noisier because there is your “Merge foo from branch bar”, while when using squash and merge, you have a single commit. For example my single line change added my commit + your merge: https://github.com/nim-lang/Nim/commits/devel |
13:42:13 | Araq | huh? |
13:42:20 | Araq | why was that re-added? |
13:42:29 | Araq | got deprecated just in this cycle? |
13:42:30 | * | nkr joined #nim |
13:42:39 | FromGitter | <mratsim> because 0.18 doesn’t have SomeFloat |
13:42:41 | FromGitter | <mratsim> yes |
13:44:32 | FromGitter | <kaushalmodi> Araq: That's why I suggest mandating the version to be added with the deprecated pragma. Using changelog to record such stuff is not efficient/scriptable |
13:45:09 | Araq | I agree but .deprecated with a list of deprecations is its own beast |
13:45:26 | Araq | and needs to be deprecated :-) |
13:46:05 | * | fourouge quit (Ping timeout: 245 seconds) |
13:50:41 | Araq | we could have added a comment though |
13:53:31 | * | yglukhov[i] joined #nim |
13:58:01 | * | yglukhov[i] quit (Ping timeout: 260 seconds) |
14:00:17 | * | xet7 joined #nim |
14:24:08 | dom96 | mratsim: a merge commit provides a link to the PR, that's useful information and I don't consider it "noise" |
14:24:30 | dom96 | GitHub really needs a "Merge when tests pass" button |
14:25:14 | FromGitter | <mratsim> squash and merge also adds the link to the PR in parenthesis |
14:30:00 | * | Trustable joined #nim |
14:30:26 | FromGitter | <mratsim> squash and merge also adds the link to the PR in parenthesis |
14:31:19 | elrood | a programmer could utilize git hooks and not depend on someone else implementing a feature button |
14:31:27 | FromGitter | <mratsim> Interesting: https://github.com/nim-lang/Nim/commit/04b3f8f24aa0a39d66fcce174c377e523f382a3a, https://github.com/nim-lang/Nim/commit/9b31f6785947974e89d46bbc0dee11f1c78754dc |
14:40:56 | miran | is there a way for nim vscode plugin (nimsuggest?) to notify about unused imports? |
14:44:22 | * | xet7 quit (Quit: Leaving) |
14:44:43 | * | nkr quit (Quit: Leaving) |
15:01:07 | dom96 | oh cool. My HN submission made it to the front page. |
15:02:54 | FromGitter | <mratsim> congrats |
15:03:44 | nasusiro | dom96: nice dissertation project mate. Well done +1 |
15:03:49 | dom96 | Thanks :) |
15:04:43 | * | fjvallarino quit (Remote host closed the connection) |
15:04:50 | * | fjvallarino joined #nim |
15:07:03 | nasusiro | dom96: how come you haven't the PDF link anywhere on the website? Maybe under an FAQ section? |
15:07:12 | FromGitter | <mratsim> this proves that you are only shadow-banned for Nim stuff :P |
15:07:33 | dom96 | nasusiro: Because I put that website together in 4 hours, a day before the deadline ;) |
15:07:48 | dom96 | mratsim: hah, totally |
15:07:52 | nasusiro | so you just graduated? |
15:08:09 | dom96 | yep, a week ago to be precise |
15:08:18 | nasusiro | welcome to the real world mate |
15:09:13 | dom96 | Won't be able to pay less for Amazon Prime and Spotify for much longer :( |
15:09:58 | nasusiro | don't you worry; NASA will hire you lol |
15:11:17 | miran | dom96: chosing simple fizzbuzz and C++ produces an errror |
15:11:46 | dom96 | That's because it's not C++ code? |
15:12:42 | miran | oh, i thought i could choose anything from the drop down menus as an example |
15:14:21 | elrood | congrats, dom |
15:20:25 | dom96 | miran: oh no, each example is for a specific lang |
15:20:42 | miran | thanks for the clarification |
15:39:17 | * | crem quit (Ping timeout: 255 seconds) |
15:41:02 | * | crem joined #nim |
15:48:42 | federico3 | nasusiro: plot twist: people don't want to work for NASA |
16:03:55 | * | qwargl joined #nim |
16:04:35 | * | endragor joined #nim |
16:08:57 | * | endragor quit (Ping timeout: 245 seconds) |
16:10:30 | qwargl | i am trying to create bindings to a library called soundtouch. i followed the "Binding to C Libraries"-guide, created a .nim using c2nim, and it compiles also. But when i try to call a function, i get: Error: internal error: (filename: "ccgcalls.nim", line: 423) ... nim version is 0.18. (more details: https://pastebin.com/G3Rt6JnQ) Any hints? And yes, i am a beginner with this. |
16:11:41 | FromGitter | <mratsim> internal error should be reported, they are compiler bugs. Though in that case there is probably an issue in your code as well |
16:12:26 | FromGitter | <mratsim> can you remove the @ in soundtouch_getVersionString(@) |
16:13:17 | FromGitter | <mratsim> the @ passes all arguments passed to the Nim function to the C++ library but here you have no arguments |
16:14:33 | qwargl | same thing |
16:17:18 | qwargl | i added information about the SoundTouchDLL.h: https://pastebin.com/cBDGdCRP |
16:18:35 | * | sz0 quit (Quit: Connection closed for inactivity) |
16:19:02 | dom96 | Can you paste your full .nim code? |
16:19:15 | FromGitter | <mratsim> use gist for example |
16:19:51 | * | gb00s quit (Quit: Ping timeout (120 seconds)) |
16:20:09 | * | BitPuffin quit (Ping timeout: 264 seconds) |
16:20:27 | * | gb00s joined #nim |
16:20:33 | * | miran quit (Remote host closed the connection) |
16:20:51 | qwargl | dom96: https://pastebin.com/ePArDGuz |
16:21:04 | * | miran joined #nim |
16:21:10 | FromGitter | <mratsim> Does c2nim supports const char return values? https://gitlab.com/soundtouch/soundtouch/blob/master/source/SoundTouchDLL/SoundTouchDLL.h#L76 |
16:21:51 | qwargl | Do u mean gist instead of soundtouch? |
16:22:19 | FromGitter | <mratsim> I mean to post the Nim code, seems like Pastebin doesn’t highlight properly |
16:22:57 | dom96 | okay, I can reproduce |
16:27:04 | dom96 | https://gist.github.com/dom96/047accf5fcf024045e6f00760de15401 |
16:27:07 | dom96 | Here is a minimal repro |
16:28:01 | dom96 | really weird |
16:28:08 | dom96 | .importc works |
16:28:12 | dom96 | .importcpp doesn't |
16:30:12 | qwargl | https://gist.github.com/marcus-wishes/ec3b99592b1a80f7e9f1fc69e3adfe15 (its the SoundTouchDLL.nim as gist) |
16:30:24 | shashlick | having some trouble with https://github.com/nim-lang/Nim/pull/8232 |
16:30:47 | shashlick | can someone try `echo formatBiggestFloat(1234.567, ffDecimal, 0, '.')` and see what output they get on #head? |
16:31:23 | shashlick | strutils had a test which checked output with "1235." which didn't work on my machines which output "1235" (without decimal) |
16:31:30 | shashlick | but appveyor test fails |
16:32:44 | shashlick | aah - okay I figured it out - `nim c` outputs "1235." whereas `nim js` outputs "1235" without decimal |
16:33:41 | shashlick | will open another bug |
16:37:30 | dom96 | qwargl: I created an issue for this: https://github.com/nim-lang/Nim/issues/8241 |
16:37:43 | dom96 | I suppose you can change `importcpp` to `importc` for these as a workaround |
16:38:28 | dom96 | I'm really puzzled by this though. Araq, are you there? |
16:42:00 | * | nsf joined #nim |
16:43:03 | qwargl | dom96: i am trying. so far i get this error: could not import: soundtouch_getVersionString() |
16:43:17 | qwargl | when executing the compiled binary |
16:48:36 | dom96 | Remove the parenthesis |
16:52:22 | qwargl | main.nim(17, 6) Error: type mismatch: got <proc (): cstring{.cdecl.}> |
16:53:16 | FromGitter | <mratsim> we don’t have enough info, what is the rest, there should be a line “Expected …" |
16:53:30 | qwargl | main.nim(17, 6) Error: type mismatch: got <proc (): cstring{.cdecl.}> |
16:53:32 | qwargl | but expected one of: |
16:53:33 | qwargl | proc `$`(x: string): string |
16:53:35 | qwargl | proc `$`(s: WideCString): string |
16:53:36 | qwargl | proc `$`[T: tuple | |
16:53:38 | qwargl | object](x: T): string |
16:53:39 | qwargl | proc `$`(x: uint64): string |
16:53:41 | qwargl | proc `$`(x: int64): string |
16:53:42 | qwargl | proc `$`[T, IDX](x: array[IDX, T]): string |
16:53:44 | qwargl | proc `$`[Enum: enum](x: Enum): string |
16:53:45 | qwargl | proc `$`(w: WideCString; estimate: int; replacement: int = 0x0000FFFD): string |
16:53:47 | qwargl | proc `$`[T](x: set[T]): string |
16:53:48 | qwargl | proc `$`[T](x: seq[T]): string |
16:53:50 | qwargl | proc `$`(x: int): string |
16:53:51 | qwargl | proc `$`(x: cstring): string |
16:53:53 | qwargl | proc `$`(x: bool): string |
16:53:54 | qwargl | proc `$`(x: float): string |
16:53:56 | qwargl | proc `$`(x: char): string |
16:53:57 | qwargl | proc `$`(err: OSErrorCode): string |
16:53:59 | qwargl | sorry! |
16:54:31 | FromGitter | <mratsim> you called echo soundtouch_getVersionString without parenthesis, it should be echo soundtouch_getVersionString() |
16:55:05 | FromGitter | <rayman22201> @dom96 Congrats on your thesis getting HN front paged! I'm assuming it's written in Nim? Just remember to not forget about us when you get your fancy job at FB :-P |
16:55:12 | qwargl | thats what i did before when i got this: error: could not import: soundtouch_getVersionString() |
16:55:22 | FromGitter | <mratsim> So: ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5b40f07a3572e970c17e277e] |
16:55:33 | FromGitter | <mratsim> without parenthesis in the importcpp |
16:55:39 | FromGitter | <mratsim> with parenthesis for the echo |
16:59:10 | qwargl | yay, works |
17:20:55 | FromGitter | <tim-st> can I write async downloaded data to a file? |
17:20:59 | FromGitter | <tim-st> let html = client.getContent(url) ⏎ ⏎ ```let f = open(filename, fmWrite) ⏎ f.write(html) ⏎ f.close()``` [https://gitter.im/nim-lang/Nim?at=5b40f67b3d8f71623d64ab6b] |
17:21:04 | FromGitter | <tim-st> doesnt work |
17:23:25 | FromGitter | <tim-st> oh, I forgot `await`, it works now |
17:28:49 | FromGitter | <tim-st> This async thing really needs hard fix, I manually need to shutdown pc... |
17:30:18 | dom96 | hrm? |
17:32:37 | FromGitter | <tim-st> when I replaced httpclient by asynchttpclient it didnt write a single html file to my pc, instead it ate all in RAM and the process couldnt be killed by filemanager |
17:32:48 | FromGitter | <tim-st> long pressing pc shutdown fixed it |
17:33:14 | dom96 | what was your code? |
17:33:25 | FromGitter | <tim-st> I think the same from httpclient page |
17:33:38 | FromGitter | <tim-st> one moment |
17:34:14 | FromGitter | <tim-st> My hope was that asynchttpclient can download multiple files instead of one per time, is that the intention? |
17:35:00 | dom96 | sure, but you need to create multiple instances of AsyncHttpClient |
17:35:17 | FromGitter | <tim-st> ok, is there any example in the docs? |
17:35:47 | FromGitter | <tim-st> yes, I had a shared client |
17:36:36 | FromGitter | <tim-st> will try again with new clients for each call |
17:38:10 | FromGitter | <tim-st> at least it wasnt interuptable by ctrl+c when using async, I think this is a bug |
17:39:09 | FromGitter | <tim-st> same again, needs shutdown^^ |
17:42:31 | FromGitter | <tim-st> https://gist.github.com/tim-st/57f9a197366a893feddc7a3b6b6d48bf |
17:44:25 | * | miran quit (Ping timeout: 256 seconds) |
17:45:37 | * | Hotkeys joined #nim |
18:03:19 | m712 | is there an up to date LLVM binding for nim? |
18:03:22 | m712 | llvm 6/7 |
18:06:26 | elrood | 7 is still two months away, there isn't even a release candidate yet |
18:09:04 | elrood | you could have a look at nlvm |
18:10:14 | dom96 | First time properly trying Docker. Definitely impressed. |
18:11:01 | m712 | okay |
18:11:12 | m712 | i always found docker overly convoluted |
18:11:26 | FromGitter | <tim-st> I updated my example code for easier testing, does someone know how to actually do async requests? |
18:14:26 | * | qwargl quit (Quit: Konversation terminated!) |
18:16:53 | dom96 | I just set up a container for my obfuscator in like 2 hours. |
18:17:41 | dom96 | And it was pretty smooth going, I only wish it took up less HD space |
18:24:28 | Araq | dom96: well importcpp with '(' is a pattern and patterns require # or @ |
18:24:57 | Araq | and probably we need to redesign this a bit :-( |
18:25:27 | Araq | it should really be 'import' and 'importPattern' |
18:25:42 | Araq | and these patterns are not C++ specific |
18:25:52 | Araq | and shouldn't trigger C++ compilations |
18:26:10 | Araq | (though we also make C++ the default target anyway) |
18:30:38 | shashlick | seeing random build failures |
18:31:07 | shashlick | tests\method\tmultim2.nim is crashing on #head |
18:31:44 | shashlick | passes on Windows, crashes on Linux |
18:33:42 | FromGitter | <data-man> @Araq: https://github.com/nim-lang/c2nim/pull/130 tests are green now |
18:33:59 | shashlick | tmultim2.nim(17, 8) Error: internal error: genMagicExpr: mTypeTrait |
18:34:05 | shashlick | unable to generate stack trace even with nim_temp |
18:34:39 | Araq | shashlick: it's green here :-) |
18:35:12 | shashlick | hmm, failing on two PRs |
18:35:37 | shashlick | #8240 and #8232 |
18:38:14 | shashlick | nope, refreshed #head and it still crashes for me on Ubuntu |
18:51:57 | * | dorelix quit (Ping timeout: 240 seconds) |
18:53:20 | * | noonien quit (Quit: Connection closed for inactivity) |
19:00:15 | FromGitter | <tim-st> does the httpclient automatically replace spaces by `%20 `? it seems only these failed |
19:07:09 | dom96 | Araq: Happens without '()' too |
19:09:49 | * | thomasross_ is now known as thomasross |
19:24:15 | * | nasusiro quit (Quit: Quitting for now...) |
19:42:16 | * | yglukhov[i] joined #nim |
19:47:09 | * | yglukhov[i] quit (Ping timeout: 264 seconds) |
19:56:31 | dom96 | Wow. Somebody just PWND me well. |
20:00:09 | m712 | dom96: what do you mean? |
20:00:29 | dom96 | Someone managed to find a security vulnerability in my obfuscator web app :) |
20:00:41 | FromGitter | <kayabaNerve> dom96: What app? |
20:01:04 | dom96 | https://picheta.me/obfuscator |
20:02:08 | shashlick | what did they do |
20:02:35 | FromGitter | <kayabaNerve> ^^ |
20:02:39 | FromGitter | <kayabaNerve> What's the vuln |
20:03:31 | livcd | lol |
20:04:00 | dom96 | They POSTed: {"code":"...","language":"`bash code here`","rename":true} |
20:04:19 | dom96 | My app took the `language` and appended it to the filename as the extension |
20:04:37 | dom96 | But since I didn't escape the ` the bash code was executed |
20:04:52 | dom96 | Was fun investigating this :D |
20:05:03 | livcd | how did you find out you got pwnd ? |
20:06:16 | elrood | as long as your graduation doesn't get revoked for that glaring oversight.. |
20:07:05 | dom96 | hah, like I said: I put this together in 4 hours |
20:07:12 | dom96 | I should have reviewed the code before posting on HN |
20:07:30 | dom96 | Anyway, here is how I noticed it: https://i.imgur.com/zL9VXv5.png |
20:07:39 | dom96 | Basically `systemctl status obfuscator` |
20:08:19 | dom96 | And I saw the `python ...` and thought "huh, that's odd" |
20:08:19 | livcd | i dont get it |
20:08:22 | livcd | the python code ? |
20:08:33 | dom96 | soon to be followed by "oh shit" |
20:08:36 | dom96 | yep |
20:08:55 | livcd | did you look at the ip ? |
20:09:29 | dom96 | hrm, let me reup that image without my VPS' IP |
20:10:17 | livcd | ah :D |
20:11:12 | dom96 | https://i.imgur.com/AdTjyYt.png |
20:11:25 | FromGitter | <kayabaNerve> What did the python do? |
20:11:44 | dom96 | Set up a reverse SSH connection |
20:12:00 | dom96 | The attacker then added an SSH key and SSH'd normally |
20:12:07 | FromGitter | <kayabaNerve> What did they then do |
20:12:28 | dom96 | Good question |
20:12:37 | dom96 | I see nothing in the .bash_history |
20:12:41 | livcd | but they sshd into a docker container right ? |
20:12:43 | dom96 | So I'm not entirely sure |
20:12:55 | Hotkeys | they responsibly reported the vulnerability and did no damage? :D |
20:13:12 | dom96 | livcd: Sadly no :) |
20:13:34 | livcd | dom96: uh how is that possible ? |
20:13:54 | FromGitter | <kayabaNerve> dom96: I would've done that... totally... not setup a cryptocurrency miner... |
20:14:18 | dom96 | livcd: because the web app isn't running in a Docker container |
20:14:24 | Hotkeys | can't imagine you'd mine that much crypto from a vps :P |
20:14:40 | livcd | did you rebuild your VPS ? |
20:15:11 | FromGitter | <kayabaNerve> livcd: He saved a file to the disc. They mangled the file name to execute bash. This bash allowed a foreign server to send commands to be executed. This is known as a reverse SSH sessions, as it's a shell connection started by the host server. |
20:15:31 | FromGitter | <kayabaNerve> Then they enabled themselves to use the standard SSH. |
20:15:44 | FromGitter | <kayabaNerve> Or are you asking how something else is possible |
20:15:57 | livcd | yeah but i saw docker and thought they would just be able to get into the docker container |
20:16:00 | livcd | but whatever |
20:16:01 | FromGitter | <kayabaNerve> Ah |
20:16:20 | FromGitter | <kayabaNerve> Hotkeys depends on the service |
20:17:20 | * | yglukhov[i] joined #nim |
20:17:29 | dom96 | hrm, .bashrc was modified |
20:17:33 | dom96 | but I don't see what changed |
20:17:36 | FromGitter | <kayabaNerve> dun dun dunnnnn |
20:17:36 | * | mwbrown quit (Ping timeout: 268 seconds) |
20:18:00 | dom96 | lol |
20:18:18 | * | mwbrown joined #nim |
20:18:50 | dom96 | strangely, .bash_history isn't being populated |
20:19:01 | livcd | that's an old trick |
20:19:04 | FromGitter | <kayabaNerve> ps aux? |
20:19:05 | FromGitter | <mratsim> Welcome to the world of botnet. 1B computer are celebrating the new joiner |
20:19:23 | FromGitter | <mratsim> if you prepend a comment with a space it’s hidden from history |
20:19:30 | FromGitter | <mratsim> a command* |
20:19:30 | FromGitter | <kayabaNerve> Check all the running processes? Update your secret files sych as an API key? |
20:19:36 | FromGitter | <kayabaNerve> Reboot, check it again? |
20:19:52 | FromGitter | <kayabaNerve> Check cron and other time based services? |
20:20:09 | dom96 | I diffed .bashrc with /etc/skel/.bashrc and see no changes |
20:20:21 | FromGitter | <mratsim> and .bash_profile? |
20:20:41 | livcd | afaik you can do smh like this with no tty allocation ssh -T user@host /bin/bash -i |
20:21:06 | dom96 | The person had a TTY and I was trying to redirect it somewhere but couldn't :( |
20:21:15 | FromGitter | <mratsim> he might be running in a screen or tmux too |
20:21:58 | * | yglukhov[i] quit (Ping timeout: 265 seconds) |
20:22:17 | FromGitter | <kayabaNerve> What if you ask for a new IP from the service? |
20:22:39 | livcd | dom96: you should rebuild your VPS |
20:22:53 | dom96 | yeah, I will |
20:23:50 | FromGitter | <kayabaNerve> How important/good is it to use the raises pragma? |
20:23:53 | livcd | you might have just changed shell and unset HISTFILE that usually does the trick |
20:24:00 | shashlick | do we already have scripts in nim-lang/nim to update a cloned devel view? |
20:24:02 | livcd | if you change your shell you wont get logged |
20:24:08 | livcd | he* |
20:24:14 | dom96 | livcd: Sounds like you have experience :P |
20:24:27 | livcd | phrack 64, issue 4 |
20:24:34 | FromGitter | <kayabaNerve> And if I possibly throw an Exception not in raises, the compiler will stop, right? |
20:24:47 | Araq | right |
20:25:02 | FromGitter | <kayabaNerve> Thanks Araq. So then it's just how important/good is it to use? |
20:25:05 | livcd | i just read lots of stuff that i might never need |
20:26:39 | dom96 | anything else I should check? |
20:27:12 | livcd | if he cared enough to cover his traces you should just rebuild immediatelly |
20:28:13 | livcd | just assume the worst case scenario and that everything is compromised. Do you have some sensitive data on that vps ? ssh keys etc ? |
20:29:35 | dom96 | Yeah, I revoked those |
20:29:51 | livcd | so umh you did ?? |
20:29:52 | livcd | :D |
20:30:04 | FromGitter | <kayabaNerve> livcd is the hacker |
20:30:07 | FromGitter | <kayabaNerve> That's how he knows |
20:30:13 | dom96 | lol |
20:30:19 | FromGitter | <kayabaNerve> I think my project is a bit stuck. The TODO list is almost out. Before I add in, say, the UI tasks, I'm working on cleaning up the code base. That's why I'm asking about raises. Anyone else have any good suggestions? |
20:31:12 | livcd | dom96: yeah anyway just get rid of that vps, any git repos you cloned there, any mirrors etc |
20:31:15 | livcd | nuke it |
20:31:22 | dom96 | But ... downtime :( |
20:31:49 | dom96 | well, actually, I can rebuild it without shutting this one down |
20:32:03 | livcd | well at least you learned a lesson :) |
20:32:05 | FromGitter | <kayabaNerve> Rebuild then transfer the DNS |
20:32:08 | FromGitter | <kayabaNerve> Then update it |
20:32:12 | livcd | you are famous enough to get hacked just by posting to HN |
20:32:14 | FromGitter | <kayabaNerve> *delete it |
20:33:21 | dom96 | Yeah, I've got cloudflare too so it should be painless |
20:33:31 | dom96 | Need my pizza to arrive first though :P |
20:33:35 | livcd | i would check for the ips of the attacker of the nim forum registered users if you can etc |
20:34:06 | dom96 | Pretty sure the IP is a droplet |
20:34:26 | dom96 | The attacker was smart to do it through a droplet, not from their own PC |
20:34:37 | dom96 | I feel like I'm a character from the movie Hackers |
20:35:20 | * | brainproxy quit (Quit: WeeChat 2.1) |
20:35:37 | livcd | ah DO droplet ? |
20:35:49 | livcd | then just contact DO maybe they will give you an identity of the attacker |
20:36:08 | livcd | might have been just dude that tried to just poke around |
20:36:10 | livcd | still unpleasant |
20:40:34 | dom96 | Educational experience though |
20:42:36 | livcd | it would scare me tbh |
20:43:29 | livcd | we dont have a torrent lib right ? |
20:44:21 | * | [ZED] joined #nim |
20:44:53 | * | [ZED] left #nim ("Leaving") |
20:44:54 | FromGitter | <Varriount> dom96: You didn't put the app in a docker container? |
20:45:04 | dom96 | The whole app? no |
20:45:31 | shashlick | livcd: could wrap one of the c libs |
20:45:48 | livcd | shashlick: i have never done it but i guess it's possible right? |
20:45:57 | FromGitter | <Varriount> Hrm, why doesn't Github use the "recently updated" sorting of issues/pull requests by default? |
20:45:58 | livcd | Do nim apps behave correctly in docker containers ? |
20:46:08 | dom96 | sure, why wouldn't they? |
20:46:57 | livcd | Crystal apps were suffering from huge performance hits |
20:48:20 | FromGitter | <Varriount> Why? |
20:48:44 | livcd | I do not know the reason and if it has been fixed already |
20:48:55 | shashlick | livcd: I could wrap one if you have some time to wait |
20:49:34 | FromGitter | <Varriount> livcd: https://github.com/crystal-lang/crystal/issues/5725 |
20:49:39 | shashlick | am currently working on ensuring nimgen wrappers work from 0.17.0 upto #head |
20:50:03 | FromGitter | <Varriount> shashlick: <3 Nimgen. Makes maintaining wrappers so much easier |
20:50:25 | livcd | shashlick: that's cool! |
20:53:16 | shashlick | varriount: do you have any wrappers you've made? i want to add them to the nimgen test matrix so that i can ensure something doesn't break as the tool evolves |
20:53:53 | FromGitter | <Varriount> shashlick: I have a toy one I made for linenoise, however I think it's broken at the moment. |
20:54:05 | FromGitter | <Varriount> (Not due to Nimgen, due to me messing around with it) |
20:54:50 | shashlick | cool, let me know when its on github and i'll add it |
20:57:39 | * | lompik quit (Ping timeout: 256 seconds) |
21:03:57 | * | yglukhov[i] joined #nim |
21:06:12 | FromGitter | <tim-st> I have a download running since two hours using httpclient and ssl and the ram grows slowly for unknown reason (nothing is hold in memory for a long time), it's now at 700mb, is this a "memory leak"? |
21:06:59 | FromGitter | <tim-st> or is this memory growth "normal" |
21:08:49 | * | yglukhov[i] quit (Ping timeout: 260 seconds) |
21:10:14 | FromGitter | <tim-st> hm, maybe I should call `client.close` the examples in the docs arent good |
21:13:20 | * | PMunch joined #nim |
21:14:16 | * | fjvallarino quit (Remote host closed the connection) |
21:14:43 | * | fjvallarino joined #nim |
21:19:33 | * | fjvallarino quit (Ping timeout: 264 seconds) |
21:23:59 | FromGitter | <tim-st> yes, calling close makes it stay constant at 14mb |
21:26:17 | * | Vladar quit (Quit: Leaving) |
21:28:27 | * | Trustable quit (Remote host closed the connection) |
21:36:32 | * | Jesin joined #nim |
21:41:54 | * | rockcavera quit (Remote host closed the connection) |
21:45:35 | * | crem quit (Ping timeout: 255 seconds) |
21:46:36 | * | crem joined #nim |
21:53:45 | shashlick | how do you test your app/project against multiple nim versions? do you use any tool to automate? |
21:56:35 | dom96 | choosenim :P |
21:59:01 | shashlick | ya i'm already using choosenim, but something to automate picking a version and doing nimble install && nimble test |
21:59:12 | shashlick | i have a bat script but would like something cross-platform |
22:22:02 | shashlick | cool so now all nimgen wrappers are tested and working from 0.17.0 onwards |
22:26:25 | PMunch | shashlick, a nim script? |
22:27:26 | shashlick | looks like that's the best option |
22:27:47 | * | bevo quit (Quit: Page closed) |
22:30:00 | PMunch | But how do you test the script for different version?! |
22:31:16 | shashlick | well, i find all versions installed by choosenim, set each version and run specified tests |
22:31:21 | shashlick | could do the same with nims |
22:31:26 | shashlick | instead of a batch file |
22:33:45 | FromGitter | <Varriount> Looks like we need a tox-like application for Nim |
22:33:45 | PMunch | I was just joking :P |
22:34:25 | shashlick | 🙂 |
22:34:34 | shashlick | varriount: would be nice, yes |
22:34:48 | PMunch | If you test your Nim code with Nim, how do you test the testing script? :P |
22:35:37 | shashlick | you could use the testing script to test the testing script |
22:35:38 | * | elrood quit (Quit: Leaving) |
22:37:53 | * | mwbrown quit (Ping timeout: 248 seconds) |
22:53:40 | FromDiscord | <exelotl> is it planned to have myNumbers.sort() work without having to pass system.cmp[int] ? |
22:56:32 | PMunch | Hmm, is there something special I need to do in order to get the gc working in a dll? |
22:56:47 | PMunch | I get this: http://ix.io/1go5 |
22:58:24 | PMunch | pimolayout is compiled with "nim c --app:lib --noMain --out:dynlibs/liblayout.so -d:use_pkg_config_static --debugger:native pimolayout.nim" and pimo.nim is compiled with: "nim c --passL:-rdynamic --debugger:native pimo.nim" |
23:04:57 | PMunch | Ah wait, this is because I'm not using nimrtl isn't it.. |
23:11:21 | * | fjvallarino joined #nim |
23:16:52 | * | rockcavera joined #nim |
23:19:46 | * | nsf quit (Quit: WeeChat 2.1) |
23:20:07 | FromDiscord | <exelotl> I'm loving `/` as a syntactic sugar to join file paths in a cross platform way |
23:20:37 | FromDiscord | <exelotl> I wasn't really digging `&` for string concatenation but this makes up for it xD |
23:23:02 | * | crem quit (Ping timeout: 256 seconds) |
23:24:59 | * | crem joined #nim |
23:36:15 | PMunch | Hmm, Nim really doesn't like to load libraries.. |
23:36:17 | * | rockcavera quit (Remote host closed the connection) |
23:45:52 | * | find0x90 joined #nim |
23:49:05 | FromGitter | <kayabaNerve> @Varriount I have one planned |
23:49:07 | FromGitter | <kayabaNerve> Not over Nim |
23:49:14 | FromGitter | <kayabaNerve> Just a secure decentralized chat |
23:49:33 | FromGitter | <kayabaNerve> I can't remember my issue with Tox but Keybase is centralized. It's secure, but a single point of failure. |
23:50:25 | * | ng0 quit (Quit: Alexa, when is the end of world?) |
23:53:25 | FromGitter | <Varriount> @kayabaNerve I'm referring to https://pypi.org/project/tox/ |
23:59:18 | PMunch | I keep getting illegal storage access from initTable.. |
23:59:20 | PMunch | Line 340 |