workspace
stringclasses
4 values
channel
stringclasses
4 values
text
stringlengths
1
3.93k
ts
stringlengths
26
26
user
stringlengths
2
11
elmlang
general
fudge... i'm trying to switch to parcel from webpack, and my elm resources aren't compiling anymore, with the "Map.!: given key is not an element in the map" error
2019-05-08T06:19:50.194000
Emilee
elmlang
general
seems weird that the bundler could have any impact on that :face_with_raised_eyebrow:
2019-05-08T06:21:57.194600
Nana
elmlang
general
Try a version of parcel without the debugger.
2019-05-08T06:22:01.194700
Timika
elmlang
general
well, when using the bundler it doesn't compile, not generally^^
2019-05-08T06:22:13.195200
Emilee
elmlang
general
aah right, Parcel always runs with `--debug`
2019-05-08T06:22:31.195600
Nana
elmlang
general
1.10.2 for example.
2019-05-08T06:22:37.195700
Timika
elmlang
general
how would i do that? i'm not entirely sure how to conf anything with parcel
2019-05-08T06:22:39.195900
Emilee
elmlang
general
i c
2019-05-08T06:22:43.196100
Emilee
elmlang
general
i assume there's no way at all to just tell it to not use the debugger?
2019-05-08T06:23:08.196300
Emilee
elmlang
general
Last time I checked there wasn’t, it’s a bit annoying. :disappointed:
2019-05-08T06:23:21.196500
Timika
elmlang
general
you could probably edit the source code in node_modules if you really want
2019-05-08T06:23:57.196800
Nana
elmlang
general
ofc it won't persist between reinstalls and such
2019-05-08T06:24:39.197000
Nana
elmlang
general
…and on CI and who knows where else. :smile:
2019-05-08T06:25:05.197200
Timika
elmlang
general
in CI you probably build for production though :slightly_smiling_face:
2019-05-08T06:25:33.197400
Nana
elmlang
general
Fair point :smile:
2019-05-08T06:25:42.197600
Timika
elmlang
general
maybe i should wait with this switch until 0.19.1 is out ^^'
2019-05-08T06:25:49.197800
Emilee
elmlang
general
i really like the "correct by default" attitude of parcel, but our project is so weird that some config is going to be necessary
2019-05-08T06:26:08.198000
Emilee
elmlang
general
In some cases you can’t use the debugger, even without the `Map.!:` bug, it tends to smash the stack with large models. Hopefully both issues (configurable debugger and the compiler issue) will be fixed soon. :slightly_smiling_face:
2019-05-08T06:27:21.198200
Timika
elmlang
general
like when you do millions of updates per second to emulate a GameBoy CPU? :laughing:
2019-05-08T06:30:53.198400
Nana
elmlang
general
Let’s just say the amount of updates is… …unusually high. :stuck_out_tongue:
2019-05-08T06:31:37.198600
Timika
elmlang
general
I'll republish under the new org name. Thanks for the heads-up
2019-05-08T07:39:26.198800
Carl
elmlang
general
there's so many bugs with parcel right now >_<
2019-05-08T08:31:52.199700
Emilee
elmlang
general
<@Carl> when building from intellij, I don’t see the file resulting from the compilation. Where should it be?
2019-05-08T08:59:50.202500
Allyn
elmlang
general
I taught an Elm course and there were a surprising number of issues getting Elm set up on everyone’s machine. I would second recommendations for Ellie.
2019-05-08T09:00:26.203200
Leoma
elmlang
general
On my side, the two only issues I faced were the access right issues on linux, and the fact many people came to the workshop without having done the installation they were asked to do (so they had less time during the workshop). I’m talking of about 40 persons, so I may have more surprises later...
2019-05-08T09:10:42.203400
Allyn
elmlang
general
However, this discussion made me considering to create a lighter version of the workshop, without tests, and based on ellie.
2019-05-08T09:12:31.203600
Allyn
elmlang
general
I'm also getting the "Map.!" error when in debug mode, and trying to debug something without the debug mode is really hard. Does anyone know of any workarounds? :(
2019-05-08T11:22:01.206300
Willetta
elmlang
general
My personal favourite: `update msg model = case Debug.log "msg" msg of ...`
2019-05-08T11:23:06.206900
Huong
elmlang
general
Ohhh! That's a good idea. Thanks! :)
2019-05-08T11:24:40.208400
Willetta
elmlang
general
I use it too, but it’s limited compared to the debugger, so I hope this issue will be solved quite soon.
2019-05-08T11:25:04.208900
Allyn
elmlang
general
Me too…
2019-05-08T11:27:47.209500
Willetta
elmlang
general
Doesn’t Ellie allow making http requests? <https://ellie-app.com/5tVr3SMzBqFa1>
2019-05-08T11:39:04.211400
Allyn
elmlang
general
<@Allyn> it’s trying to connect to `<http://httpbin.org>` rather than `<https://httpbin.org>`, if you change it to https it should work
2019-05-08T11:40:06.212000
Alicia
elmlang
general
looks better indeed
2019-05-08T11:40:40.212300
Allyn
elmlang
general
thanks!
2019-05-08T11:40:47.212700
Allyn
elmlang
general
Browsers don’t like mixed content
2019-05-08T11:40:50.213000
Huong
elmlang
general
Is there any workaround for this?
2019-05-08T11:41:09.213300
Allyn
elmlang
general
I doubt it - might be that there’s a flag hidden away somewhere, but security features tend to be hard to disable
2019-05-08T11:43:05.214400
Huong
elmlang
general
ok
2019-05-08T11:45:09.215100
Allyn
elmlang
general
There may be some proxies that can handle this, though - e.g. throwing `<https://jsonp.afeld.me/?url=>` in front of the url. Naturally, that means making that proxy a man in the middle, giving it access to all traffic you send through it
2019-05-08T11:49:19.215500
Huong
elmlang
general
It’s just for a workshop, so it wouldn’t be a serious issue. But before trying that i’ll see if can activate https, it would be a better solution
2019-05-08T11:51:39.215700
Allyn
elmlang
general
It worked :slightly_smiling_face:
2019-05-08T11:54:14.215900
Allyn
elmlang
general
Thanks again for your help, <@Huong>
2019-05-08T11:54:40.216100
Allyn
elmlang
general
I have been trying to test the accessiblity of some Elm pages using the Chromevox Chrome plugin. This plugin is made by Google and I believe is the standard screen reader on Chromebooks. Sometimes it works and sometimes it doesn't. For example, if you go to the elm-packages page then none of the links work if Chromevox...
2019-05-08T12:33:11.219900
Albina
elmlang
general
does that extension modify the dom? Elm (and any framework with a virtual dom) does not like others touching their dom nodes. This is a common problem with various browser plugins
2019-05-08T12:35:11.220900
Virgie
elmlang
general
Thanks <@Virgie>. It does. However, some Elm apps I've tried on the Made with Elm website do not seem to be affected by it so I wondered if anyone knew what particular feature of Elm causes the problem so it could be avoided. I want to make my Elm apps accessible and usable on Chromebooks so I'm going to have to figure...
2019-05-08T12:51:02.224200
Albina
elmlang
general
it might be the program type. If elm just takes over an element on a page, then the extension might just not modify it, but if elm is responsible for the whole body then any modification will be a problem
2019-05-08T12:52:52.225500
Virgie
elmlang
general
a common pattern in extensions is that they add a child to &lt;body&gt;, so if you make sure that is allowed you're probably good
2019-05-08T12:53:32.226200
Virgie
elmlang
general
Ok. Thanks for the tip. I'll investigate that.
2019-05-08T12:54:11.226900
Albina
elmlang
general
Hi, sorry, but is this code <https://github.com/elm/browser/blob/1.0.0/examples/wasd.elm> using 1.0.0 as it claims? It must be, but then is the documentation up to date or am I looking at the wrong place?
2019-05-08T13:43:38.228100
Maxwell
elmlang
general
<https://package.elm-lang.org/packages/elm/browser/latest/Browser-Events>
2019-05-08T13:43:38.228200
Maxwell
elmlang
general
For example, the code uses `Keyboard.downs`, `Keyboard.ups`, etc., but the documentation says `onKeyDown`, `onKeyUp`.
2019-05-08T13:45:30.228700
Maxwell
elmlang
general
You’re looking at the right place, the docs haven’t been updated yet, there is an open pr for this. Here is the updated version <https://github.com/elm/browser/blob/aeb21bc2cdaa542d63cb0ad65f4cde6f7ecbce6d/examples/wasd.elm>
2019-05-08T14:29:23.228800
Lea
elmlang
general
could anyone point me to the `elm-assets-loader` successor?
2019-05-08T21:41:11.229800
Shelli
elmlang
general
<https://elmlang.slack.com/archives/C0MU81TEC/p1557373933022500>
2019-05-08T23:52:20.230200
Lashawnda
elmlang
general
Hey gu... almost slipped there ... people! I just started looking into elm-community/graph. anyone here know it? I’m thinking about NodeContexts. Don’t they mean that edges will be duplicated in the Graph as the incoming Edge of one Node will be the outgoing Edge of another?
2019-05-09T01:39:35.235200
Genevieve
elmlang
general
Oh, thanks! Do you understand what `Browser.Events.onVisibilityChange (always Blur)` there is for? If I remove it and re-compile, nothing appears to change.
2019-05-09T01:42:37.235300
Maxwell
elmlang
general
I need some help navigating the documentation. I often don't know if I'm looking at 0.19 stuff or older. For example, what's the difference between `elm-lang/animation-frame` and `elm/browser/onAnimationFrame`? What's up with `elm` and `elm-lang`?
2019-05-09T02:08:33.237400
Maxwell
elmlang
general
<@Maxwell> all `elm-lang` packages are 0.18 packages
2019-05-09T02:10:15.237800
Earlean
elmlang
general
And `elm` is the up-to-date stuff? :+1:
2019-05-09T02:10:45.238600
Maxwell
elmlang
general
if you only search for packages from the index of <https://package.elm-lang.org> you'll only see results for 0.19 packages
2019-05-09T02:10:59.239000
Earlean
elmlang
general
Great, thank you!
2019-05-09T02:11:10.239300
Maxwell
elmlang
general
Did you see the docs <https://package.elm-lang.org/packages/elm/browser/latest/Browser-Events#onVisibilityChange> ?
2019-05-09T03:02:51.239400
Lea
elmlang
general
A bullet-proof way to see the Elm version package was built for is to browse its source and check `elm.json` (for 0.19). If there is `elm-package.json` the package is definitely for 0.18 or lower.
2019-05-09T04:30:15.239700
Lynne
elmlang
general
Is it possible to install both Elm versions 0.18 and 0.19 on the same development PC (running under Windows)? If so, how would I switch between them so that the elm-? commands still work correctly?
2019-05-09T04:43:57.241100
Clarissa
elmlang
general
I usually use `npm` for that, with `elm` as a dev dependency. You can then run the local version via `npx elm make`.
2019-05-09T04:45:50.242400
Jin
elmlang
general
in different folder, npm install elm@0.18.0
2019-05-09T05:10:16.243200
Cindie
elmlang
general
I have a question about event handling. Is it possible for a Msg to somehow accidentally be triggered multiple times at once, and if so how would this be handled by the runtime?
2019-05-09T06:00:16.244100
Gertrude
elmlang
general
I can imagine an accidental double click on a button with an `onClick` handler which will lead to two successive messages sent into your `update` function
2019-05-09T06:02:09.244800
Lynne
elmlang
general
I think it is no different from any other JS framework
2019-05-09T06:03:10.245400
Lynne
elmlang
general
Yes, it's the window's onfocus and onblur, but I was wondering why was it used in that example at all. I'm also having trouble understanding the difference between AnimationFrame and AnimationFrameDelta. We could do the same with just AnimationFrame, how extra useful is AnimationFrameDelta?
2019-05-09T06:44:43.246200
Maxwell
elmlang
general
Ah, good idea, thank you.
2019-05-09T06:45:05.246400
Maxwell
elmlang
general
Update: About onfocus, onblur, I got it. Thanks :slightly_smiling_face:
2019-05-09T06:45:51.246600
Maxwell
elmlang
general
If you have any info on my question about AnimationFrame/Delta, share it my way please! :pray:
2019-05-09T06:46:23.246800
Maxwell
elmlang
general
hey folks - I have my backend api which returns an `image/png` (byte array) and I want to download it as a File and show it as preview image. How do i do this in Elm
2019-05-09T06:55:41.247200
Mirtha
elmlang
general
just insert it as a source of the img tag: ``` &lt;img src="data:image/png;base64,[ENCODED STRING GOES HERE]"&gt; ```
2019-05-09T07:07:34.247300
Allison
elmlang
general
What does the Float value in an Http.request timeout indicate? Seconds, milliseconds?
2019-05-09T08:29:12.248300
Gertrude
elmlang
general
It is in milliseconds
2019-05-09T08:35:28.248400
Kenya
elmlang
general
It's being explained after the PUT example
2019-05-09T08:36:10.248700
Kenya
elmlang
general
It’s just an error checker right now. Output goes to /dev/null.
2019-05-09T09:04:31.249900
Carl
elmlang
general
so It means we must compile using the command line (with elm-live by example)
2019-05-09T09:06:43.250100
Allyn
elmlang
general
Correct. In the future I’d like to improve this so that it can be totally standalone
2019-05-09T09:16:32.251000
Carl
elmlang
general
Thanks <@Jin> and <@Cindie>. I've settled on workspace installations of Elm (dev) with npm script aliases configured for various tasks. Elm 19 is a little nicer as I can run the Elm.exe directly for one-off commands but with Elm 18 I have to save a script alias first and run it with npm run. Overall it works ok and I c...
2019-05-09T09:32:10.255600
Clarissa
elmlang
general
<@Clarissa> Generally what I have done is leave Elm strictly as an NPM dependency in projects, but another thing you could try is using `nvm` and setting up two environments, one for 0.18, and one for 0.19.
2019-05-09T09:37:35.257200
Gertrude
elmlang
general
nvm... ?
2019-05-09T09:38:04.257400
Clarissa
elmlang
general
<https://github.com/nvm-sh/nvm>
2019-05-09T09:38:23.257600
Gertrude
elmlang
general
Ah. interesting. :+1:
2019-05-09T09:38:56.258100
Clarissa
elmlang
general
it's sort of akin to tools like `pyenv/virtualenv` but for Node.
2019-05-09T09:39:11.258400
Gertrude
elmlang
general
For some reason it's the only way I could get Elm working at all on my Ubuntu dev box.
2019-05-09T09:39:26.258800
Gertrude
elmlang
general
I always use nvm on linux
2019-05-09T09:50:22.259300
Danika
elmlang
general
<@Lynne> <@Rochell> As I understand from reading this. Instead of ``` Time.now |&gt; Task.perform TimeMsg ``` I should ``` Process.sleep 1 |&gt; Task.andThen (always Time.now) |&gt; Task.perform TimeMsg ``` Something like this?
2019-05-09T10:41:08.259600
Inger
elmlang
general
Yep, something like this
2019-05-09T10:41:54.259800
Lynne
elmlang
general
thanks!
2019-05-09T10:42:13.260100
Inger
elmlang
general
i just found a strange compiler error. not sure if i should post this in the elm-dev channel. Anyway... ``` ERROR in ./src/elm/Main.elm Module build failed (from ./node_modules/elm-webpack-loader/index.js): Error: Compiler process exited with error Compilation failed Success! Compiled 1 module. elm: Map.!: given key is...
2019-05-09T10:54:40.261900
Lilli
elmlang
general
Yeah, it’s the most common 0.19 compiler error. For what it’s worth, <#C13L7S5GR|elm-dev> is only for ongoing collaboration :slightly_smiling_face: Are you by any chance passing the `--debug` flag?
2019-05-09T10:56:11.262000
Huong
elmlang
general
i started migrating from 0.18 to 0.19 last monday, about 7k LOC left and yes, i'm using the debug flag
2019-05-09T10:58:39.262200
Lilli
elmlang
general
i was reading the issues/1802 on GH, but it's marked as closed
2019-05-09T10:59:30.262400
Lilli
elmlang
general
Right, this is _mosty likely_ related to the debugger. A proper fix is in progress, and as it is being batched with some performance-issues due to laziness it will take a little while before it’s actually released.
2019-05-09T11:00:12.262600
Huong
elmlang
general
I started using version managers with `rbenv` for ruby, so now I’m using `nodenv` for node, `exenv` for elixir, `pyenv` for python, etc. It’s nice having identical APIs for different version managers
2019-05-09T11:08:17.262900
Alleen
elmlang
general
Ah! thanks for the info. This will probably mean we will delay the migration though
2019-05-09T11:08:47.263100
Lilli