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

new post does not work with couchdb trunk #4

Open
astraw opened this issue Feb 16, 2010 · 9 comments
Open

new post does not work with couchdb trunk #4

astraw opened this issue Feb 16, 2010 · 9 comments

Comments

@astraw
Copy link

astraw commented Feb 16, 2010

I installed couchdb r910054 and all the tests pass. Then I installed sofa with "couchapp push . http://astraw:[email protected]:5984/blogdb". Navigating to the "Visit your CouchApp here:" URL, I attempted to create a new post at http://127.0.0.1:5984/blogdb/_design/sofa/_show/edit by filling in the fields.

Finally, when clicking "save ->", I got the JSON: {"error":"not_found","reason":"missing function"}

The couchdb log shows:
[error] [<0.979.0>] OS Process Error <0.1190.0> :: {not_found,<<"missing function">>}
[info] [<0.979.0>] 127.0.0.1 - - 'POST' /blogdb/_design/sofa/_show/new.html 404

@cKleinhuis
Copy link

i got the same, and i am wondering if it is because i have no default admin user ... :(?

@anowi
Copy link

anowi commented May 14, 2010

I have the same issue.
I tried it with and with out the admin user, it made no difference :(
But I noticed that the shows/ directory only has edit.js and post.js
Shouldn't this directory include something like new.js?

Since I am new to couchdb I don't feel that comfortable in debugging it.
I hope I find some answers on the forums.

@furtivefelon
Copy link

not sure if this ever gets to anyone, but i have similar problems, when i click save (both when i logged in as per _utils or not), it never prompts me to login, and after saving, it gives me this page: http://pastie.in:5984/sofa/_design/sofa/new.html (that's a real address, though i'm not sure if it won't change in the future), and then the browser complains that it's not found.

If anyone have any suggestions, it would be much appreciated!

@sn88
Copy link

sn88 commented Jul 25, 2010

having exactly the same problem with couchDb1.0 and the trunk version of sofa.

Is that supposed to work somehow?
actually it seems there is no listener for the SAVE action somehow. Its not even creating the post in the Database.

Any suggestion to solve that very welcome

@michaelkirk
Copy link

ditto.

When I visit: sofa/_show/edit
I get this error in my firefox error console:
"$.couch.app is not a function"

@michaelkirk
Copy link

I think the "$.couch.app is not a function" is a different issue, but I fixed that with this:

diff --git a/templates/partials/scripts.html b/templates/partials/scripts.html
index 9bfb2f1..5d6f0a3 100644
--- a/templates/partials/scripts.html
+++ b/templates/partials/scripts.html
@@ -2,9 +2,9 @@
 <script src="/_utils/script/jquery.js"></script>
 <script src="/_utils/script/jquery.couch.js"></script>
 <script src="/_utils/script/sha1.js"></script>
-<script src="../../vendor/couchapp/jquery.couch.app.js"></script>
-<script src="../../vendor/couchapp/jquery.couch.app.util.js"></script>
-<script src="../../vendor/couchapp/jquery.evently.js"></script>
-<script src="../../vendor/couchapp/jquery.mustache.js"></script>
-<script src="../../script/app.js"></script>
-<script src="../../script/md5.js"></script>
\ No newline at end of file
+<script src="../vendor/couchapp/jquery.couch.app.js"></script>
+<script src="../vendor/couchapp/jquery.couch.app.util.js"></script>
+<script src="../vendor/couchapp/jquery.evently.js"></script>
+<script src="../vendor/couchapp/jquery.mustache.js"></script>
+<script src="../script/app.js"></script>
+<script src="../script/md5.js"></script>

@ido-ran
Copy link

ido-ran commented Sep 5, 2010

I think the problem is that the app.docForm function has been deprecated but I know too little to fix it.
This is what I found in jquery.coucha.app.js:
function docForm() { alert("docForm has been moved to vendor/couchapp/lib/docForm.js, use app.require to load") };

Any help will be great.

Ido

@rayleyva
Copy link

As to the alert I have a patched edition I forked tonight. Not saying it's the solution, but it's a solution that works. Now can someone please point out the best / approved / authorized / sanctioned / proper way to submit patch / pull requests ? I'd really appreciate if I could figure out the process to have a code / doc review.

Is there a proper path to helping out on this project?

@astraw
Copy link
Author

astraw commented Sep 26, 2010

I can confirm your commit allows me to save new posts with a fresh install of CouchDB 1.0.1. Thank you!

As to the proper path for helping -- I think you already have. Hopefully jchris will merge your commit.

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

8 participants