ArchiveOrangemail archive

user.couchdb.apache.org


(List home) (Recent threads) (2 other Apache CouchDB lists)

Subscription Options

  • RSS or Atom: Read-only subscription using a browser or aggregator. This is the recommended way if you don't need to send messages to the list. You can learn more about feed syndication and clients here.
  • Conventional: All messages are delivered to your mail address, and you can reply. To subscribe, send an email to the list's subscribe address with "subscribe" in the subject line, or visit the list's homepage here.
  • Low traffic list: less than 3 messages per day
  • This list contains about 25,217 messages, beginning Dec 2008
  • 0 messages added yesterday
Report the Spam
This button sends a spam report to the moderator. Please use it sparingly. For other removal requests, read this.
Are you sure? yes no

Breaking changes 1.1.0

Ad
Patrick Barnes 1307501245Wed, 08 Jun 2011 02:47:25 +0000 (UTC)
Having just updated to 1.1.0, I think I've been caught by the one 
breaking change listed;

* Document id's are now validated during PUT. This means that some PUT 
requests will fail that previously succeeded.

The user object I'm trying to store is:|{
||"|_id|": |"org.couchdb.user:test_appdata_user"||
|"|salt|": |"91ae270048fae61ebcff7730e5014150a529d082"|,"|password_sha|": |"968091cd9ce21a0fca52232b85f9971c925801bd"|,
"|name|": |"test_appdata_user"|,
"|type|": |"user"|,
"|roles|": |[|"cgm_view"|,
|"cgm_store_appdata"|]|,
}|and it fails equally in Futon or my own code.
||In Futon the dialog is:|Error: unknown_error|
|function_clause|
||
||The breaking changes info wasn't helpful as to what was happening, orwhy...
What is happening here?

-Patrick


Logs are:

[Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] 'PUT' 
/_users/org.couchdb.user%3Atest_appdata_user {1,1} from "127.0.0.1"
Headers: [{'Accept',"application/json,text/html,text/plain,*/*"},
           {'Authorization',"Basic YWRtaW46bWluaW9u"},
           {'Content-Length',"234"},
           {'Content-Type',"application/json"},
           {'Host',"localhost:5984"}]
[Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] OAuth Params: []
[Wed, 08 Jun 2011 02:27:48 GMT] [error] [<0.761.0>] function_clause 
error in HTTP request
[Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] Stacktrace: 
[{mochiweb_request,get,
                                  [scheme,
                                   {mochiweb_request,#Port<0.2316>,'PUT',
                                    
"/_users/org.couchdb.user%3Atest_appdata_user",
                                    {1,1},
                                    {5,
                                     {"authorization",
                                      {'Authorization',
                                       "Basic YWRtaW46bWluaW9u"},
                                      {"accept",
                                       {'Accept',
                                        
"application/json,text/html,text/plain,*/*"},
                                       nil,nil},
                                      {"host",
                                       {'Host',"localhost:5984"},
                                       {"content-type",
                                        {'Content-Type',"application/json"},
                                        {"content-length",
                                         {'Content-Length',"234"},
                                         nil,nil},
                                        nil},
                                       nil}}}}]},
                                 {couch_httpd,absolute_uri,2},
                                 {couch_httpd_db,db_doc_req,3},
                                 {couch_httpd_db,do_db_req,2},
                                 {couch_httpd,handle_request_int,5},
                                 {mochiweb_http,headers,5},
                                 {proc_lib,init_p_do_apply,3}]
[Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] 127.0.0.1 - - 'PUT' 
/_users/org.couchdb.user%3Atest_appdata_user 500
[Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] httpd 500 error 
response:
  {"error":"unknown_error","reason":"function_clause"}
Robert Newson 1307523108Wed, 08 Jun 2011 08:51:48 +0000 (UTC)
The id you are using looks valid to me.

Did you install CouchDB 1.1.0 over the top of an existing CouchDB
installation? If so, you have mingled two conflicting versions of our
modules together, which is going to cause function_clause errors all
over the place.

B.On 8 June 2011 03:46, Patrick Barnes  wrote:
> Having just updated to 1.1.0, I think I've been caught by the one breaking
> change listed;
>
> * Document id's are now validated during PUT. This means that some PUT
> requests will fail that previously succeeded.
>
> The user object I'm trying to store is:
> |{
> ||"|_id|": |"org.couchdb.user:test_appdata_user"||
> |"|salt|": |"91ae270048fae61ebcff7730e5014150a529d082"|,
> "|password_sha|": |"968091cd9ce21a0fca52232b85f9971c925801bd"|,
> "|name|": |"test_appdata_user"|,
> "|type|": |"user"|,
> "|roles|": |[
> |"cgm_view"|,
> |"cgm_store_appdata"|
> ]|,
> }
>
> |and it fails equally in Futon or my own code.
> ||
> In Futon the dialog is:
> |Error: unknown_error|
> |function_clause|
> ||
> ||The breaking changes info wasn't helpful as to what was happening, or
> why...
> What is happening here?
>
> -Patrick
>
>
> Logs are:
>
> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] 'PUT'
> /_users/org.couchdb.user%3Atest_appdata_user {1,1} from "127.0.0.1"
> Headers: [{'Accept',"application/json,text/html,text/plain,*/*"},
>          {'Authorization',"Basic YWRtaW46bWluaW9u"},
>          {'Content-Length',"234"},
>          {'Content-Type',"application/json"},
>          {'Host',"localhost:5984"}]
> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] OAuth Params: []
> [Wed, 08 Jun 2011 02:27:48 GMT] [error] [<0.761.0>] function_clause error in
> HTTP request
> [Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] Stacktrace:
> [{mochiweb_request,get,
>                                 [scheme,
>                                  {mochiweb_request,#Port<0.2316>,'PUT',
>
> "/_users/org.couchdb.user%3Atest_appdata_user",
>                                   {1,1},
>                                   {5,
>                                    {"authorization",
>                                     {'Authorization',
>                                      "Basic YWRtaW46bWluaW9u"},
>                                     {"accept",
>                                      {'Accept',
>
> "application/json,text/html,text/plain,*/*"},
>                                      nil,nil},
>                                     {"host",
>                                      {'Host',"localhost:5984"},
>                                      {"content-type",
>                                       {'Content-Type',"application/json"},
>                                       {"content-length",
>                                        {'Content-Length',"234"},
>                                        nil,nil},
>                                       nil},
>                                      nil}}}}]},
>                                {couch_httpd,absolute_uri,2},
>                                {couch_httpd_db,db_doc_req,3},
>                                {couch_httpd_db,do_db_req,2},
>                                {couch_httpd,handle_request_int,5},
>                                {mochiweb_http,headers,5},
>                                {proc_lib,init_p_do_apply,3}]
> [Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] 127.0.0.1 - - 'PUT'
> /_users/org.couchdb.user%3Atest_appdata_user 500
> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] httpd 500 error
> response:
>  {"error":"unknown_error","reason":"function_clause"}
>
Patrick Barnes 1307537074Wed, 08 Jun 2011 12:44:34 +0000 (UTC)
Bother, I have done exactly that.

How to fix it, then?
(My installations were to --[exec-]prefix=/, with 1.0.2 and 1.1.0 defaults
otherwise )-Patrick
On Jun 8, 2011 6:51 PM, "Robert Newson"  wrote:
> The id you are using looks valid to me.
>
> Did you install CouchDB 1.1.0 over the top of an existing CouchDB
> installation? If so, you have mingled two conflicting versions of our
> modules together, which is going to cause function_clause errors all
> over the place.
>
> B.
>
> On 8 June 2011 03:46, Patrick Barnes  wrote:
>> Having just updated to 1.1.0, I think I've been caught by the one> On 8 June 2011 03:46, Patrick Barnes  wrote:
>> Having just updated to 1.1.0, I think I've been caught by the one
breaking
>> change listed;
>>
>> * Document id's are now validated during PUT. This means that some PUT
>> requests will fail that previously succeeded.
>>
>> The user object I'm trying to store is:
>> |{
>> ||"|_id|": |"org.couchdb.user:test_appdata_user"||
>> |"|salt|": |"91ae270048fae61ebcff7730e5014150a529d082"|,
>> "|password_sha|": |"968091cd9ce21a0fca52232b85f9971c925801bd"|,
>> "|name|": |"test_appdata_user"|,
>> "|type|": |"user"|,
>> "|roles|": |[
>> |"cgm_view"|,
>> |"cgm_store_appdata"|
>> ]|,
>> }
>>
>> |and it fails equally in Futon or my own code.
>> ||
>> In Futon the dialog is:
>> |Error: unknown_error|
>> |function_clause|
>> ||
>> ||The breaking changes info wasn't helpful as to what was happening, or
>> why...
>> What is happening here?
>>
>> -Patrick
>>
>>
>> Logs are:
>>
>> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] 'PUT'
>> /_users/org.couchdb.user%3Atest_appdata_user {1,1} from "127.0.0.1"
>> Headers: [{'Accept',"application/json,text/html,text/plain,*/*"},
>>          {'Authorization',"Basic YWRtaW46bWluaW9u"},
>>          {'Content-Length',"234"},
>>          {'Content-Type',"application/json"},
>>          {'Host',"localhost:5984"}]
>> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] OAuth Params: []
>> [Wed, 08 Jun 2011 02:27:48 GMT] [error] [<0.761.0>] function_clause errorin>> HTTP request
>> [Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] Stacktrace:
>> [{mochiweb_request,get,
>>                                 [scheme,
>>                                  {mochiweb_request,#Port<0.2316>,'PUT',
>>
>> "/_users/org.couchdb.user%3Atest_appdata_user",
>>                                   {1,1},
>>                                   {5,
>>                                    {"authorization",
>>                                     {'Authorization',
>>                                      "Basic YWRtaW46bWluaW9u"},
>>                                     {"accept",
>>                                      {'Accept',
>>
>> "application/json,text/html,text/plain,*/*"},
>>                                      nil,nil},
>>                                     {"host",
>>                                      {'Host',"localhost:5984"},
>>                                      {"content-type",
>>{'Content-Type',"application/json"},>>                                       {"content-length",
>>                                        {'Content-Length',"234"},
>>                                        nil,nil},
>>                                       nil},
>>                                      nil}}}}]},
>>                                {couch_httpd,absolute_uri,2},
>>                                {couch_httpd_db,db_doc_req,3},
>>                                {couch_httpd_db,do_db_req,2},
>>                                {couch_httpd,handle_request_int,5},
>>                                {mochiweb_http,headers,5},
>>                                {proc_lib,init_p_do_apply,3}]
>> [Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] 127.0.0.1 - - 'PUT'
>> /_users/org.couchdb.user%3Atest_appdata_user 500
>> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] httpd 500 error
>> response:
>>  {"error":"unknown_error","reason":"function_clause"}
>>
Robert Newson 1307542746Wed, 08 Jun 2011 14:19:06 +0000 (UTC)
I'd remove the existing .beam files (or move them aside, if you
prefer) and do 'make install' again, which will copy just the .beam
files you need back in there.

B.On 8 June 2011 13:44, Patrick Barnes  wrote:
> Bother, I have done exactly that.
>
> How to fix it, then?
> (My installations were to --[exec-]prefix=/, with 1.0.2 and 1.1.0 defaults
> otherwise )
>
> -Patrick
> On Jun 8, 2011 6:51 PM, "Robert Newson"  wrote:
>> The id you are using looks valid to me.
>>
>> Did you install CouchDB 1.1.0 over the top of an existing CouchDB
>> installation? If so, you have mingled two conflicting versions of our
>> modules together, which is going to cause function_clause errors all
>> over the place.
>>
>> B.
>>
>> On 8 June 2011 03:46, Patrick Barnes  wrote:
>>> Having just updated to 1.1.0, I think I've been caught by the one
> breaking
>>> change listed;
>>>
>>> * Document id's are now validated during PUT. This means that some PUT
>>> requests will fail that previously succeeded.
>>>
>>> The user object I'm trying to store is:
>>> |{
>>> ||"|_id|": |"org.couchdb.user:test_appdata_user"||
>>> |"|salt|": |"91ae270048fae61ebcff7730e5014150a529d082"|,
>>> "|password_sha|": |"968091cd9ce21a0fca52232b85f9971c925801bd"|,
>>> "|name|": |"test_appdata_user"|,
>>> "|type|": |"user"|,
>>> "|roles|": |[
>>> |"cgm_view"|,
>>> |"cgm_store_appdata"|
>>> ]|,
>>> }
>>>
>>> |and it fails equally in Futon or my own code.
>>> ||
>>> In Futon the dialog is:
>>> |Error: unknown_error|
>>> |function_clause|
>>> ||
>>> ||The breaking changes info wasn't helpful as to what was happening, or
>>> why...
>>> What is happening here?
>>>
>>> -Patrick
>>>
>>>
>>> Logs are:
>>>
>>> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] 'PUT'
>>> /_users/org.couchdb.user%3Atest_appdata_user {1,1} from "127.0.0.1"
>>> Headers: [{'Accept',"application/json,text/html,text/plain,*/*"},
>>>          {'Authorization',"Basic YWRtaW46bWluaW9u"},
>>>          {'Content-Length',"234"},
>>>          {'Content-Type',"application/json"},
>>>          {'Host',"localhost:5984"}]
>>> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] OAuth Params: []
>>> [Wed, 08 Jun 2011 02:27:48 GMT] [error] [<0.761.0>] function_clause error
> in
>>> HTTP request
>>> [Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] Stacktrace:
>>> [{mochiweb_request,get,
>>>                                 [scheme,
>>>                                  {mochiweb_request,#Port<0.2316>,'PUT',
>>>
>>> "/_users/org.couchdb.user%3Atest_appdata_user",
>>>                                   {1,1},
>>>                                   {5,
>>>                                    {"authorization",
>>>                                     {'Authorization',
>>>                                      "Basic YWRtaW46bWluaW9u"},
>>>                                     {"accept",
>>>                                      {'Accept',
>>>
>>> "application/json,text/html,text/plain,*/*"},
>>>                                      nil,nil},
>>>                                     {"host",
>>>                                      {'Host',"localhost:5984"},
>>>                                      {"content-type",
>>>
> {'Content-Type',"application/json"},
>>>                                       {"content-length",
>>>                                        {'Content-Length',"234"},
>>>                                        nil,nil},
>>>                                       nil},
>>>                                      nil}}}}]},
>>>                                {couch_httpd,absolute_uri,2},
>>>                                {couch_httpd_db,db_doc_req,3},
>>>                                {couch_httpd_db,do_db_req,2},
>>>                                {couch_httpd,handle_request_int,5},
>>>                                {mochiweb_http,headers,5},
>>>                                {proc_lib,init_p_do_apply,3}]
>>> [Wed, 08 Jun 2011 02:27:48 GMT] [info] [<0.761.0>] 127.0.0.1 - - 'PUT'
>>> /_users/org.couchdb.user%3Atest_appdata_user 500
>>> [Wed, 08 Jun 2011 02:27:48 GMT] [debug] [<0.761.0>] httpd 500 error
>>> response:
>>>  {"error":"unknown_error","reason":"function_clause"}
>>>
>
Home | About | Privacy