Code Monkey home page Code Monkey logo

couchapp's People

Contributors

benoitc avatar jchris avatar jhs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

couchapp's Issues

problem pushing a couchapp with extjs lib

hi,

i got an Error while pushing a fresh couchapp with a ExtJs lib as attachment to my couch.

couchapp: Couchapp (version 0.7.1)
couchdb: Apache CouchDB 1.0.1
ubuntu: ubuntu: 10.10, 2.6.35-22-generic
python: Python 2.6.6
ExtJS:

  • Standard Extjs 3.3.0 - unzipped
  • path in couchapp _attachments/js/ext-3.3.0

sry, i habe no experience with python/couchapp, so i have no starting point to fix this problem, i tried it a few days ago at work with a couchapp-eclipse plugin, it had a similar Problem, i avoided it, by splitting the extjs package in smaller pieces. I suppose, the ext lib has too much args for couchapp.
I hope it will help you.
Great work!

so long tom

PS: Error log:
2010-11-22 20:25:55 [CRITICAL] unknown error [[Errno 111] Connection refused]

Traceback (most recent call last):
File "/usr/local/lib/python2.6/dist-packages/couchapp/dispatch.py", line 48, in dispatch
return _dispatch(args)
File "/usr/local/lib/python2.6/dist-packages/couchapp/dispatch.py", line 92, in _dispatch
return fun(conf, conf.app_dir, _args, *_opts)
File "/usr/local/lib/python2.6/dist-packages/couchapp/commands.py", line 77, in push
doc.push(dbs, noatomic, browse, force)
File "/usr/local/lib/python2.6/dist-packages/couchapp/localdoc.py", line 102, in push
db.save_doc(doc, force_update=True)
File "/usr/local/lib/python2.6/dist-packages/couchapp/client.py", line 281, in save_doc
resp = self.res.put(docid, payload=json.dumps(doc), *_params)
File "/usr/local/lib/python2.6/dist-packages/restkit/resource.py", line 179, in put
headers=headers, params_dict=params_dict, *_params)
File "/usr/local/lib/python2.6/dist-packages/couchapp/client.py", line 130, in request
raise RequestFailed("unknown error [%s]" % str(e))
RequestFailed: unknown error [[Errno 111] Connection refused]

adding coffeescript (*.coffee) preprocessor

would be nice to add handling *.coffee scripts instead of .js, and then pass out to coffeescript compiler before uploading to database.

Who is interested to handle coffeescript ? :)

Regards,
Andrzej

Add this to the docs

In OSX you must do the following to actually install...

sudo env ARCHFLAGS="-arch i386 -arch x86_64 -Wno-error=unused-command-line-argument-hard-error-in-future" pip install couchapp

That stupid -Wno-error=unused-command-line-argument-hard-error-in-future was a big problem to find. Hah.

Wrong in couchapp --help

The help states:
couchapp generate [appdir]

However in reality the arguments are reversed as such that one have to write
couchapp generate [appdir]

!json directive not working as expected

Hi.

I have two .js files in /lists/ and two .html files in /templates/
Both list functions are like this:
function(head, req) {
// !json templates
}

When pushed to couchdb none of the directives is translated to var templates = { ...

MacOsx - CouchDb - CouchApp Problems

Hi there,

I'm quite new to CouchDb, and I've discovered CouchApp recently. I've setup the version 0.9.1 of CouchDb on my Intel Mac.
It was working quqite well (view creation/Filtering, request etC....)
After all I setup CouchApp, but I got an odd error Message :(can anyone tell me if you have faced this problem ?

{"error":"{bad_return_value,{os_process_error,"OS process timed out."}}","reason":"{gen_server,call,\n [<0.23365.2>,\n {prompt,[<<"list_tail">>,\n {[{<<"info">>,\n {[{db_name,<<"sofa">>},\n {doc_count,1},\n {doc_del_count,0},\n {update_seq,14},\n {purge_seq,0},\n {compact_running,false},\n {disk_size,2006555},\n {instance_start_time,<<"1250206253086256">>}]}},\n {<<"verb">>,'GET'},\n {<<"path">>,\n [<<"sofa">>,<<"design">>,<<"sofa">>,<<"list">>,\n <<"index">>,<<"recent-posts">>]},\n {<<"query">>,\n {[{<<"descending">>,<<"true">>},\n {<<"limit">>,<<"5">>}]}},\n {<<"headers">>,\n {[{<<"Accept">>,\n <<"text/html,application/xhtml+xml,application/xml;q=0.9,/;q=0.8">>},\n {<<"Accept-Charset">>,\n <<"ISO-8859-1,utf-8;q=0.7,*;q=0.7">>},\n {<<"Accept-Encoding">>,<<"gzip,deflate">>},\n {<<"Accept-Language">>,\n <<"fr,fr-fr;q=0.8,en-us;q=0.5,en;q=0.3">>},\n {<<"Connection">>,<<"keep-alive">>},\n {<<"Host">>,<<"localhost:5984">>},\n {<<"Keep-Alive">>,<<"300">>},\n {<<"User-Agent">>,\n <<"Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; fr; rv:1.9.0.11) Gecko/2009060214 Firefox/3.0.11">>}]}},\n {<<"body">>,undefined},\n {<<"form">>,{[]}},\n {<<"cookie">>,{[]}}]}]},\n infinity]}"}

JSON docs not supporting comments

It is admittedly not part of the JSON spec, but I would suggest that .json files be permitted to contain comments in the javascript style.

couchapp generate test - FAILS

PROBLEM:
C:\stux> couchapp generate test
Traceback (most recent call last):
File "C:\dev\RAD\Tools\Python25\Scripts\couchapp-script.py", line 8, in
load_entry_point('couchapp==0.3.1', 'console_scripts', 'couchapp')()
File "c:\dev\rad\tools\python25\lib\site-packages\couchapp-0.3.1-py2.5.egg\couchapp\bin\couchapp_cli.py", line 125, in main
cli = CouchappCli(options.verbose)
File "c:\dev\rad\tools\python25\lib\site-packages\couchapp-0.3.1-py2.5.egg\couchapp\bin\couchapp_cli.py", line 37, in init
self.ui = UI(verbose=verbose, logging_handler=console)
File "c:\dev\rad\tools\python25\lib\site-packages\couchapp-0.3.1-py2.5.egg\couchapp\ui.py", line 42, in init
self.readconfig(rcpath())
File "c:\dev\rad\tools\python25\lib\site-packages\couchapp-0.3.1-py2.5.egg\couchapp\utils.py", line 76, in rcpath
_rcpath = user_rcpath()
File "c:\dev\rad\tools\python25\lib\site-packages\couchapp-0.3.1-py2.5.egg\couchapp\utils.py", line 52, in user_rcpath
path.append(os.path.join(userprofile, '.couchapprc'))
AttributeError: 'str' object has no attribute 'append'

C:\stux>

ENVIRONMENT:
C:\stux>python
Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.

SOLUTION:
Here's the patch that works for me:

*** couchapp\utils.py   Wed Jun 10 09:29:17 2009
--- couchapp\utils.py.changed   Wed Jun 10 09:30:26 2009
***************
*** 49,55 ****
              path = os.path.join(home, '.couchapprc')
          userprofile = [os.environ.get('USERPROFILE')]
          if userprofile:
!             path.append(os.path.join(userprofile, '.couchapprc'))
          return path
  else:
      def user_rcpath():
--- 49,55 ----
              path = os.path.join(home, '.couchapprc')
          userprofile = [os.environ.get('USERPROFILE')]
          if userprofile:
!             path = os.path.join(userprofile, '.couchapprc')
          return path
  else:
      def user_rcpath():

[CRITICAL] 'unicode' object has no attribute 'update'

i had a problem with pushing my app, cause i have such files in app root:
couchapp.json
and
couchapp.json~

just put

for name in os.listdir(current_dir):
    name = name.rstrip("~")
    ...

at the begining of dir_to_fields in locadoc.py

CouchApp not validating JSON docs before push.

If a document ending in .json is loaded using !json, it should be validated as being valid JSON markup.

I had a large object that had one instance of ; instead of : ... and couchdb silently loaded the markup as a string value.

pip install couchapp - syntax error

Installing on Debian Lenny getting syntax error

File "/usr/src/Python-2.7.3/build/couchapp/setup.py", line 149
with open(os.path.join(os.path.dirname(file), 'README.rst')) as f:
^
SyntaxError: invalid syntax
Complete output from command python setup.py egg_info:
/usr/src/Python-2.7.3/build/couchapp/setup.py:149: Warning: 'with' will become a reserved keyword in Python 2.6

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.