Users posting a resource are automatically subscribed ('following') the Discourse topics on their page

“npm i dcs-client” does not work

in local host?

if so DCS related code won’t work as that relies on communicating with a Discourse forum

the only way to test DCS related stuff is to create a PR and i’ll push it to the live site, or if @zofrex can set you up on the testing server he’s been building this weekend

I’ve just tried on my side and it seems to be working fine. Would you please post the error message here?

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! bcrypt@2.0.1 install: node-pre-gyp install --fallback-to-build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bcrypt@2.0.1 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

@green-loutre can I just check. Is this an error you are getting trying to set up a local Dev environment, or have I missed something?

No juste installing dcs-client to add the code in the your projetct

although i’m not a lot of help from the technical side it would help if you could explain it like i’m 5 to help me get a picture of where you are so i can try to support as best i can. i expect Syl already understands this and his imput is more useful.

so, you have a local dev env up and this is the error message you get in it when putting the code in?

I don’t have any dev env. I’m just in the project (fl-maps) and tried to add the pluggin dcs-client so I can import it in the file NewEvent

@syl can you advise. I didn’t think we needed the dcs-client plugin as we had that in our Discourse forum

I had issues with bcrypt too when I was building locally. I think I either had to downgrade to an older node (I matched the one in .travis.yml) or if I had to upgrade the bcrypt dependency. Basically, older bcrypt npm libs won’t install on newer systems.

1 Like

@tmcnulty @zofrex it would be really helpful if you guys could chat with @green-loutre here and help them work out whats going on

@green-loutre what version of NPM do you have installed?

1 Like

version 6.9.0.

1 Like

Hey folks, sorry I’m late to the party

Do you have the compiler and build dependencies installed for bcrypt? (as it’s a native/compiled dependency, not just JS code)

Depending on your OS, you’ll find them listed here: Installation Instructions · kelektiv/node.bcrypt.js Wiki · GitHub

1 Like

Hi, I can take a look at this if someone isnt working on it already…

1 Like

yes please @Zahra and thank you for joining the build!

i suggest reading the comments above as we were guiding someone through setting this up last weekend but they hit a wall, we think due to their OS. This thread should give a good idea what needs to be done and where. also tag @syl for any technical questions relating to the code.

@zofrex bob just pointed out that we are coding on the wrong branch now i think. Whats the correct workflow to get the changes pushed to BTM and PHM?

@syl @zofrex is going to be working on this tomorrow afternoon GMT. Will you be around to guide them in what they need to do?

@ArtyS if you happen to be online and can keep an eye and offer advice i’m sure that would be a great help too :slight_smile:

Pulling important info out from above messages:

  1. it needs to be added in the JavaScript code (client-side): when the user creates a new events, the corresponding Docuss tags (in your case “photos”, “videos” and “stories”) have to be created right away

  2. @syl says: the code should be called whenever someone creates a new event.
    Please tell me when you found the location in the app code and I will check how the Docuss API should be called.

  3. @green-loutre believes it should be here:

    callNewEvent = model => {
    Meteor.call(‘Events.newEvent’, model, (err, res) => {
    if (!err) {
    this.setState({ currentStep: 0 }) // return to first step
    window.__recentEvent = { …model, _id: res }
    this.props.history.push(’/thank-you’)
    }
    window.NProgress.done()
    if (Meteor.isDevelopment) { console.log(err) }
    })
    }

  4. Andy defines expected behaviour: When a user posts something on the map three new Discourse threads are created. This code will subscribe the poster to those threads meaning that they get notified if anyone comments on their post

  5. @Zahra says: Looks like its this one where the code needs to be added: https://github.com/focallocal/fl-maps/blob/deploy-btm/imports/client/ui/pages/NewEvent/index.js