Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Supporting Forge on Parse.com #218

Closed
adonoho opened this issue Feb 19, 2015 · 2 comments
Closed

Supporting Forge on Parse.com #218

adonoho opened this issue Feb 19, 2015 · 2 comments

Comments

@adonoho
Copy link

adonoho commented Feb 19, 2015

Gentlefolk,

I am a mobile developer using Parse.com as my backend server. They implement a Node.js-like V8 powered environment. Unfortunately for me, they did not fully implement the Node.js crypto environment.

After surveying the various options, Forge looks like the right library for me to choose. It appears to have an active community and is well maintained.

Parse supports the CommonJS requires mechanism. Hence, I was hoping that I could just take the folder out of an installed node-forge module and be off to the races. Alas, I am not racing today.

I get the following error message from parse while trying to instantiate Forge:

Update failed with Could not load triggers.  The error was Error: Module ./aes not found
    at forge/forge.js:31:14
    at Array.map (native)
    at module.exports (forge/forge.js:30:21)
    at defineFunc (forge/forge.js:47:10)
    at forge/forge.js:90:14
    at define (forge/forge.js:15:7)
    at define (forge/forge.js:54:22)
    at forge/forge.js:59:1
    at forge/forge.js:92:3
    at main.js:2:13

The line in my code is:

var forge = require('cloud/forge/forge.js');

The above seems straightforward enough. Clearly, the system has a different notion of a path on Parse than it does on Node. If forge.js executes, then the file aes.js is also present. I've tried replacing the ./ with forge/.

Not being a web or node developer, I am at a loss of which steps to take moving forward. Any debugging tips?

Anon,
Andrew

@dlongley
Copy link
Member

Sorry for the slow response! I don't have any experience running Parse.com. I think it would just take some poking around with that system to figure out what's going wrong with the paths. Perhaps you can change the pwd to resolve the issue, I don't know. Anyone else have some insight into this issue?

@dlongley
Copy link
Member

dlongley commented Oct 5, 2016

Closing as potentially resolved, can be reopened if necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants