These are chat archives for reactioncommerce/reaction

17th
May 2018
Patrick Newell
@pnewell4_twitter
May 17 2018 01:34
what is the best practice for testing whether a user is logged in? I see !Reaction.hasPermission("anonymous") in practice, but I'm not confident that is the best way
Guus Huizen
@iAmGuus
May 17 2018 05:05
@zenweasel yeah the local one, never installed another one on this machine
Sean
@JungleCatSW
May 17 2018 07:09
Hello, is there a way that I can use an environment variable to allow access to the graphiql client when running the reactioncommerce/reaction docker image ?
srividjax
@srividjax
May 17 2018 07:32
Hello Reaction, is there a way to add digital downloadable products??
William Moss
@willmoss1000
May 17 2018 08:55
Has anyone else seen an issue whereby if you sign-in at checkout, additional items are added to your cart? Items that you added when you were signed in previously?
William Moss
@willmoss1000
May 17 2018 09:29
@zenweasel do you know what the desired behaviour is for user sign-in at checkout? I would assume the cart they had before signing in should overwrite the stored? I am finding they add to one another. And, since on the checkout page users can't see what they've got in the cart they don't realise it has happened.
Loan Laux
@loanlaux
May 17 2018 09:40
@willmoss1000 Never seen this but it seems like a pretty major issue
Screen Shot 2018-05-17 at 11.38.53.png
William Moss
@willmoss1000
May 17 2018 09:41
@loanlaux yes, it is! I guess it only happens when the carts don't match?
Loan Laux
@loanlaux
May 17 2018 09:42
Does anyone have an idea why the Validation Error red dot shows up on this variant? All the fields are filled in and I have no idea what's wrong. This is on a merchant shop. Project is on 1.11. Would appreciate any insight!
William Moss
@willmoss1000
May 17 2018 09:42
But whatever happens, the old cart should be overwritten with whatever they added prior to checkout. I haven't figure out exactly how to reproduce it
Loan Laux
@loanlaux
May 17 2018 09:43
@pnewell4_twitter I usually use Reaction.hasPermission("account/profile")
William Moss
@willmoss1000
May 17 2018 09:43
@loanlaux yes, I've seen that before many times. Can't say I know the cause.
Patrick Newell
@pnewell4_twitter
May 17 2018 09:44
thanks @loanlaux
Loan Laux
@loanlaux
May 17 2018 09:44
not sure it's the recommended way either, though
Loan Laux
@loanlaux
May 17 2018 09:51
So I added an Origin Country to that product and it did nothing. Right after, I played around with the template selector (going back and forth between one and two columns) and it removed the Validation Error badge.
Anyone's got an explanation for this? My client's marketplace is catering to non tech-savvy merchants so I'll need a precise yet simple way to explain what they have to do to get their products accepted.
William Moss
@willmoss1000
May 17 2018 09:53
I think the validation error shows sometimes when there isn't an issue?
Loan Laux
@loanlaux
May 17 2018 09:53
Also it's pretty uncool that there's no error message other than "Validation Error." When the product title is missing, the field turns red and displays a little helper saying that it has to be filled. But I have a feeling this is not the case for all fields? Or maybe this isn't related to missing fields at all?
@willmoss1000 To be honest I have absolutely no idea what's going on with this issue, but it seems that you're right
William Moss
@willmoss1000
May 17 2018 09:56
I've not looked into, but from experience I've ignored the red-dot in the past and it's been fine. Yes, that's not the case for all fields - just shows up for titles because they are required to publish a product. I've gotten around this by setting a default-title in the past (I now also have an autovalue as my products fit nicely into categories)
Actually...I think there is potentiall something wrong with the defaultValue for originCountry from memory. I set this to a static value of "US". But it was a while ago
Loan Laux
@loanlaux
May 17 2018 09:57
Yeah I think my issue here is bigger than just the red dot showing up randomly. Even with it being gone, that product I just created isn't showing up anywhere
William Moss
@willmoss1000
May 17 2018 09:57
Aha. And the shop is set to active?
Loan Laux
@loanlaux
May 17 2018 09:58
Let me check
If that's not the case I'll seriously need to go brew some more coffee
William Moss
@willmoss1000
May 17 2018 09:58
It's weird in marketplace, I've had to change all that stuff. You can't see a product really unless shops are active.
Loan Laux
@loanlaux
May 17 2018 09:58
I've always ignored it too but it would be a friction point for these precise customers, who as I said aren't really techies
William Moss
@willmoss1000
May 17 2018 09:59
yep...i'm in the exact same spot!
Loan Laux
@loanlaux
May 17 2018 10:00
The shop is indeed active
And wait for it... I've got something even more grandiose
William Moss
@willmoss1000
May 17 2018 10:00
workflow.status set to active, not new
Loan Laux
@loanlaux
May 17 2018 10:00
Let me check in the DB, but it's set to active in the global marketplace admin panel
William Moss
@willmoss1000
May 17 2018 10:00
ah that's fine
yeh
same thing
weird!
Loan Laux
@loanlaux
May 17 2018 10:01
So yes, "workflow.status": "active"
Anyways let me show you something even weirder that just happened
William Moss
@willmoss1000
May 17 2018 10:01
Don't scare me
Loan Laux
@loanlaux
May 17 2018 10:02
Give me a second to black out the NDA-protected stuff
Screen Shot 2018-05-17 at 11.55.29.png
So here's the wonderful, beautiful, splendid homepage
Everything looking as it should
Notice that I'm not logged in
And then I click on one of the tags in the NavBar
Screen Shot 2018-05-17 at 11.55.42.png
And... wtf? No more tags? No products?
Not even a "No products found" message by the way
So yeah... That might be my custom plugin/theme code that's causing it, but I'm not overriding anything other than the homepage. Nothing really touches tags or the product grid.
William Moss
@willmoss1000
May 17 2018 10:06
Nothing in the console?
Weird!
Loan Laux
@loanlaux
May 17 2018 10:07
Oh yes, of course
William Moss
@willmoss1000
May 17 2018 10:07
Fortunately for me I don't use tags!
Loan Laux
@loanlaux
May 17 2018 10:07
Screen Shot 2018-05-17 at 12.07.13.png
So I guess this qualifies for a detailed bug report? I'm not even sure how to reproduce that but I will be sure to dig into it. I have no choice either way.
William Moss
@willmoss1000
May 17 2018 10:10
Well it's certainly serious, whatever it is! Looks like whatever is being mapped isn't defined - most likely the list of products? Best of luck!
Loan Laux
@loanlaux
May 17 2018 10:10
Definitely the list of products since it's in renderProductGrid
Anyways time for me to go try and solve this
srividjax
@srividjax
May 17 2018 10:37
hello reaction, anyone there?
Does reaction support adding 'Digital Products' or 'Downloadable Products'
Loan Laux
@loanlaux
May 17 2018 11:38
That's not supported out of the box, @srividjax. You'd have to customize the Product schema and the interface to allow this kind of functionnality. However, that shouldn't be a huge task since Reaction made it quite simple to extend schemas and override the UI.
Isaac Weber
@ikey2244
May 17 2018 14:11
Hello so I am going through the installation process of reaction and I followed the directions but I am getting a message after running reaction init "command not found: reaction"
Any help would be appreciated
Loan Laux
@loanlaux
May 17 2018 14:11
Are you sure you ran npm i -g reaction-cli @ikey2244?
Isaac Weber
@ikey2244
May 17 2018 14:11
yep
Loan Laux
@loanlaux
May 17 2018 14:12
That could be a $PATH issue related to NPM but I can't say for sure
Do you have other global CLIs installed through NPM that are working?
Isaac Weber
@ikey2244
May 17 2018 14:12
npm ERR! path /Users/iweber/.npm-global/lib/node_modules/reaction-cli
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall access
npm ERR! enoent ENOENT: no such file or directory, access '/Users/iweber/.npm-global/lib/node_modules/reaction-cli'
npm ERR! enoent This is related to npm not being able to find a file.
Loan Laux
@loanlaux
May 17 2018 14:13
Hmm... And you're not getting any error when installing reaction-cli?
Isaac Weber
@ikey2244
May 17 2018 14:14
after running npm i -g reaction-cli I get that error
I tried installing create-react-app globally using npm and that worked fine
Loan Laux
@loanlaux
May 17 2018 14:18
Okay that's weird
Not exactly sure what to do here
Isaac Weber
@ikey2244
May 17 2018 14:32
@loanlaux Hey so I just went to npm and searched for the reaction-cli and it looks like the build failed.
Loan Laux
@loanlaux
May 17 2018 14:33
Interesting... It would probably be best to ping someone from the core team like @jshimko
Isaac Weber
@ikey2244
May 17 2018 14:34
Okay thanks @loanlaux
Guus Huizen
@iAmGuus
May 17 2018 16:29
maybe a small psa for all the people (including me 24 hours ago): It's better to run your RC dev server on a vps like azure or aws. I am now using it and its way faster than running it locally (for me). Also METEOR_DISABLE_OPTIMISTIC_CACHING=1 works good.
William Moss
@willmoss1000
May 17 2018 16:47
FYI @loanlaux reactioncommerce/reaction#4252 this is what I was talking about earlier. Seems to work locally.
  • Ignore for now
Loan Laux
@loanlaux
May 17 2018 16:50
Awesome @willmoss1000. I also found reactioncommerce/reaction#4238 and reactioncommerce/reaction#4238 which would most likely solve my product issues.
William Moss
@willmoss1000
May 17 2018 16:54
Ah yes! Looking forward to revision control being removed!
Guus Huizen
@iAmGuus
May 17 2018 18:35
Could anybody help me out real quick? I am following the plugin tutorial on the docs but it's giving me an error: 'Uncaught Error: A name and component are required for registerComponent' at the end part 3. What do I need to do and why? Thanks :smile:
Loan Laux
@loanlaux
May 17 2018 18:49
@iAmGuus Can you post your call to registerComponent?
Loan Laux
@loanlaux
May 17 2018 19:25
@iAmGuus There's nothing in your code that should cause this error
Guus Huizen
@iAmGuus
May 17 2018 19:28
Yeah, thats what I thought but the error seems to have gone away for some reason. Thanks either way, I will return soon with new questions as I am new to RC.
Loan Laux
@loanlaux
May 17 2018 19:29
Probably your cache. Anyways, glad it's sorted out!
Guus Huizen
@iAmGuus
May 17 2018 19:30
Yeah, thanks. By the way, just wanted to say that I am trying to start my own business making e-commerce sites for people in my area just like you :) So you're pretty much like an inspiration to me.
Loan Laux
@loanlaux
May 17 2018 19:31
Humbled to hear that! Had you came accross my stuff before, or did you just check my GitHub after I replied to your question?
Guus Huizen
@iAmGuus
May 17 2018 20:15
No, I know you from Instagram :smile:
Loan Laux
@loanlaux
May 17 2018 20:16
Oh, awesome :clap:
Guus Huizen
@iAmGuus
May 17 2018 20:16
Yeah, I like it a lot more now that I can actually see the changes I do without having to wait 2 minutes for a rebuild haha. Thanks to Azure for the free vm :D