These are chat archives for reactioncommerce/reaction

29th
Sep 2017
Cezary Madras
@czadras
Sep 29 2017 02:20
hi, quick question - is there a way to hid admin's toolbar and right-side nav bar?
Also, I created custom translation file and it is not being picked up (it is loaded when Reaction started, I checked using debug logging). When I added my translation to core translation, it worked. I followed documentation. Is there anything else I need to do?
Benjamin
@Benjaminshafa
Sep 29 2017 03:43
Hi everybody. I am super new to reaction. I am trying to run it in my windows 10 environment, but facing some difficulties. Is this room a right place to ask question in this regard?
Brian Kilrain
@bkilrain
Sep 29 2017 04:42
Has anyone made a payment service plugin for Square? Square injects their own form and I'm trying to get the payment/order creation captured correctly by reaction
tigman
@tigman
Sep 29 2017 07:36
Hello. I'm a novice when it comes to web app development and just started learning Meteor and React. I just want to clarify something. Reaction Commerce can be use without any fee to its developers right? That how I understand 'open source'. Thank you.
Brent Hoover
@zenweasel
Sep 29 2017 08:34
@tigman Yes, that’s correct
Benjamin
@Benjaminshafa
Sep 29 2017 08:48
when I try to run reactionCommerce for the first time, by typing "reaction" in command line, I get errors after => Started Proxy. It says "Unable to resolve some modules:
"babel-runtime/helpers/typeof"
Any idea?
Brent Hoover
@zenweasel
Sep 29 2017 08:48
try running meteor npm install and watching for any errors
Ashish
@ashishgokhale
Sep 29 2017 15:29

HI I am also getting similar error during simple update:

let updatedvariant = {
  title: variation.Name,
  price: variation.price,
  sku :  variation.sku,
};
let response;
response = Products.update({
  _id: variation._id
}, {
  $set: updatedvariant
}, {
  selector: {
    type: "variant"
  }
});

Below error I am getting on rest api creation

Error: Access Denied [403]
at adjustInventory (imports/plugins/included/inventory/server/methods/inventory.js💯11)
at [object Object].inventoryAdjust (imports/plugins/included/inventory/server/methods/inventory.js:158:5)
at packages/check.js:128:16
at [object Object].EVp.withValue (packages/meteor.js:1135:15)
at Object.exports.Match.failIfArgumentsAreNotAllChecked (packages/check.js:127:41)
at maybeAuditArgumentChecks (packages/ddp-server/livedata_server.js:1765:18)
at packages/ddp-server/livedata_server.js:1686:15
at [object Object].EVp.withValue (packages/meteor.js:1135:15)
at packages/ddp-server/livedata_server.js:1684:36
at [object Object]..extend.applyAsync (packages/ddp-server/livedata_server.js:1683:12)
at [object Object]..extend.apply (packages/ddp-server/livedata_server.js:1622:26)
at [object Object]..extend.call (packages/ddp-server/livedata_server.js:1604:17)
at Object. (imports/plugins/included/inventory/server/hooks/hooks.js:80:12)
at packages/matb33_collection-hooks.js:486:20
at Array.forEach (native)
at Function..each..forEach (packages/underscore.js:139:11)
=> awaited here:
at Promise.await (/Users/synsoftglobal/.meteor/packages/promise/.0.9.0.1911j66++os+web.browser+web.cordova/npm/node_modules/meteor-promise/promise_server.js:60:12)
at [object Object]..extend.apply (packages/ddp-server/livedata_server.js:1635:22)
at [object Object]..extend.call (packages/ddp-server/livedata_server.js:1604:17)
at Object. (imports/plugins/included/inventory/server/hooks/hooks.js:80:12)
at packages/matb33_collection-hooks.js:486:20
at Array.forEach (native)
at Function..each..forEach (packages/underscore.js:139:11)
at packages/matb33_collection-hooks.js:485:11
at Array.forEach (native)
at Function..each..forEach (packages/underscore.js:139:11)
at after (packages/matb33_collection-hooks.js:484:9)
at Object. (packages/matb33_collection-hooks.js:505:5)
at Object.collection.(anonymous function) [as update] (packages/matb33_collection-hooks.js:146:21)
at [object Object].update (packages/mongo/collection.js:550:29)
at [object Object].Mongo.Collection.(anonymous function) (packages/aldeed_collection2-core.js:232:19)
at [object Object].Mongo.Collection.(anonymous function) [as update] (packages/dispatch_run-as-user.js:325:19)

I have tried everything, need help, looking for a solution desperately !!!!!!!
Spencer Norman
@spencern
Sep 29 2017 15:31

Hi Ashish - you mention

Below error I am getting on rest api creation

Can you explain this more, Reaction does not support a rest API out of the box

Ashish
@ashishgokhale
Sep 29 2017 15:31
I have added simple rest
it is working fine with every query but just receiving Access denied when using update
Spencer Norman
@spencern
Sep 29 2017 15:32
specifically when updating products or when updating any collection?
Ashish
@ashishgokhale
Sep 29 2017 15:33
yes during update product collection
let updatedvariant = {
title: variation.Name,
price: variation.price,
sku : variation.sku,
};
let response;
response = Products.update({
_id: variation._id
}, {
$set: updatedvariant
}, {
selector: {
type: "variant"
}
});
Spencer Norman
@spencern
Sep 29 2017 15:33
I saw your code
does it happen when attempting to update other collections as well?
Ashish
@ashishgokhale
Sep 29 2017 15:35
My requirement is just to update product, One more thing I have created a product add api where I have to update price range, I can update properly there, but during update call, I dont know how inventroy error comes in action
does inventory have any link with just Products.update()
Spencer Norman
@spencern
Sep 29 2017 15:36
As I mentioned in the github ticket, I think this is a auth issue. I’ve not used simple-rest before, but Reaction will reject db updates that are from an unauthenticated or unauthorized user.
yes, the inventory runs on a hook that’s connected to Products.update()
Ashish
@ashishgokhale
Sep 29 2017 15:38
is there any way I can update some of data via api like title, price, sku etc without these hooks?
Spencer Norman
@spencern
Sep 29 2017 15:44

We’re working to update our plugins so that they can be enabled and disabled. Looking at the code for our inventory hooks right now, it doesn’t look like they are optional right now.

I’d be willing to look at a PR that adds functionality to toggle inventory on/off

machiko
@machikoyasuda
Sep 29 2017 15:55
@bkilrain Hi Brian - As far as I know, no one has made a payment service plugin for Square yet. Here's our payment provider tutorial: https://docs.reactioncommerce.com/reaction-docs/master/creating-a-payment-provider
machiko
@machikoyasuda
Sep 29 2017 16:04
@czadras Hi Cezary - On your first question, you could make a plugin that adds a button to hide/show the admin toolbar and right-side nav bar. That might be a good idea for me to make a tutorial on.
Sophie He
@sophiehe
Sep 29 2017 16:41
From October 1 to December 15, submit a pull request and earn exclusive prize packs, awards, and the chance to win a $500 Visa gift card. Learn more + check out some of our new swag: https://blog.reactioncommerce.com/introducing-the-reaction-hack-a-bug-a-thon/
Ashish
@ashishgokhale
Sep 29 2017 17:03
@spencern
How can I override a existing method?

Can I do this in plugin:

Meteor.publish( "inventory/adjust", function (product) {

});

I tried this but it is calling the core one, but what was I expecting is it will call one which is in custom plugin
Sijawusz Pur Rahnama
@Sija
Sep 29 2017 18:19
Hello everyone!
Josh Cox
@joshuacox
Sep 29 2017 22:18
ok I'm getting pretty consistent out of memory errors on reaction build --build-arg TOOL_NODE_FLAGS="--max-old-space-size=9096" mycustom
I've got 32 gigs of RAM with well over 20 of it free at the moment too
does that build-arg argument still exist?
zrisher
@zrisher
Sep 29 2017 23:48
@joshuacox I know that I consistently get OOM errors when simply running reaction on windows, even if running it directly through node using the --max-old-space-size arg set to many gigs
Not sure how that helps, but you might try commenting out parts of the process until you find out which functions specifically are putting you OOM
that was my plan
Josh Cox
@joshuacox
Sep 29 2017 23:49
I'm on arch linux here, and have verified on debian stretch as well, it seems to be very consistent on v1.4.3 and meteor 1.5.2.1
zrisher
@zrisher
Sep 29 2017 23:50
On a different note, does anyone know if Reaction.import is meant to support customers and transactions in the future? Per the docs I note that it currently does not.