[jira] [Commented] (COUCHDB-987) use view functions to emit changes

2012-05-02 Thread Michael Reuss (JIRA)
documents to the _view filter or do I miss something in the intended use? Thanks, Micha. use view functions to emit changes -- Key: COUCHDB-987 URL: https://issues.apache.org/jira/browse/COUCHDB-987

[jira] Closed: (COUCHDB-987) use view functions to emit changes

2010-12-27 Thread Benoit Chesneau (JIRA)
in trunk. use view functions to emit changes -- Key: COUCHDB-987 URL: https://issues.apache.org/jira/browse/COUCHDB-987 Project: CouchDB Issue Type: New Feature Affects Versions: 1.2 Reporter

Re: use view functions to emit changes

2010-12-14 Thread Benoit Chesneau
Back on this, have been distracted by flu. On Mon, Dec 6, 2010 at 1:10 PM, Filipe David Manana fdman...@apache.org wrote: Sorry for the delay Benoît. Comments: 1) At https://github.com/benoitc/couchdb/compare/master...view_changes#L1R40 you're also changing the emit of the regular sandbpox

Re: use view functions to emit changes

2010-12-14 Thread Filipe David Manana
On Tue, Dec 14, 2010 at 12:42 PM, Benoit Chesneau bchesn...@gmail.com wrote: Back on this, have been distracted by flu. 4) Perhaps here: https://github.com/benoitc/couchdb/compare/master...view_changes#L4R235 the name of the command sent to the view server should be something like

[jira] Created: (COUCHDB-987) use view functions to emit changes

2010-12-14 Thread Benoit Chesneau (JIRA)
use view functions to emit changes -- Key: COUCHDB-987 URL: https://issues.apache.org/jira/browse/COUCHDB-987 Project: CouchDB Issue Type: New Feature Affects Versions: 1.2 Reporter: Benoit

[jira] Updated: (COUCHDB-987) use view functions to emit changes

2010-12-14 Thread Benoit Chesneau (JIRA)
[ https://issues.apache.org/jira/browse/COUCHDB-987?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Benoit Chesneau updated COUCHDB-987: Attachment: view_changes.patch use view functions to emit changes

Re: use view functions to emit changes

2010-12-14 Thread Benoit Chesneau
On Tue, Dec 14, 2010 at 2:03 PM, Filipe David Manana fdman...@apache.org wrote: On Tue, Dec 14, 2010 at 12:42 PM, Benoit Chesneau bchesn...@gmail.com wrote: Back on this, have been distracted by flu. 4) Perhaps here: https://github.com/benoitc/couchdb/compare/master...view_changes#L4R235 the

[jira] Commented: (COUCHDB-987) use view functions to emit changes

2010-12-14 Thread Filipe Manana (JIRA)
functions to emit changes -- Key: COUCHDB-987 URL: https://issues.apache.org/jira/browse/COUCHDB-987 Project: CouchDB Issue Type: New Feature Affects Versions: 1.2 Reporter: Benoit Chesneau

Re: use view functions to emit changes

2010-12-06 Thread Benoit Chesneau
bump. On Tuesday, November 30, 2010, Benoit Chesneau bchesn...@gmail.com wrote: On Tue, Nov 30, 2010 at 4:44 PM, Filipe David Manana fdman...@apache.org wrote: Here is an updated patch. It now use a filter sandbox instead of patching the function and it fixes whitespaces. Why a separate

Re: use view functions to emit changes

2010-12-06 Thread Filipe David Manana
Sorry for the delay Benoît. Comments: 1) At https://github.com/benoitc/couchdb/compare/master...view_changes#L1R40 you're also changing the emit of the regular sandbpox (don't forget, in the previous statement you're copying a reference, not a value): E.g.: $ ./couchjs - c1 = evalcx(''); c1.foo

Re: use view functions to emit changes

2010-12-06 Thread Gabriel Farrell
On Tue, Nov 30, 2010 at 8:32 AM, Benoit Chesneau bchesn...@gmail.com wrote: On Tue, Nov 30, 2010 at 1:50 PM, Jan Lehnardt j...@apache.org wrote: On 30 Nov 2010, at 13:05, Benoit Chesneau wrote: About the 2 spaces in js, imo we should go to a 4 spaces indentations, which is a way more readable

Re: use view functions to emit changes

2010-12-06 Thread Volker Mische
On 06.12.2010 18:05, Gabriel Farrell wrote: On Tue, Nov 30, 2010 at 8:32 AM, Benoit Chesneaubchesn...@gmail.com wrote: On Tue, Nov 30, 2010 at 1:50 PM, Jan Lehnardtj...@apache.org wrote: On 30 Nov 2010, at 13:05, Benoit Chesneau wrote: About the 2 spaces in js, imo we should go to a 4

Re: use view functions to emit changes

2010-12-06 Thread Filipe David Manana
Crockford, JavaScript's ChuckNorris: http://javascript.crockford.com/code.html On Mon, Dec 6, 2010 at 5:10 PM, Volker Mische volker.mis...@gmail.com wrote: On 06.12.2010 18:05, Gabriel Farrell wrote: On Tue, Nov 30, 2010 at 8:32 AM, Benoit Chesneaubchesn...@gmail.com  wrote: On Tue, Nov

Re: use view functions to emit changes

2010-12-06 Thread Benoit Chesneau
On Mon, Dec 6, 2010 at 6:05 PM, Gabriel Farrell gsf...@gmail.com wrote: On Tue, Nov 30, 2010 at 8:32 AM, Benoit Chesneau bchesn...@gmail.com wrote: On Tue, Nov 30, 2010 at 1:50 PM, Jan Lehnardt j...@apache.org wrote: On 30 Nov 2010, at 13:05, Benoit Chesneau wrote: About the 2 spaces in js,

Re: use view functions to emit changes

2010-12-06 Thread Mikeal Rogers
Every style guide, and every linter, has a different notion about spacing. All of them use spaces of course but the actual indentation varies. 2 spaces is fairly standard and damn near the entire world uses it. There are other variations, like 4 spaces for multi-line var which closure-lint

Re: use view functions to emit changes

2010-12-06 Thread Benoit Chesneau
On Mon, Dec 6, 2010 at 6:57 PM, Mikeal Rogers mikeal.rog...@gmail.com wrote: But for the record, nobody except people who wish they were writing Python use 4 space indentation everywhere. It's the part of crockford's style guide that is most often ignored. except maybe BSD developers, Erlang

Re: use view functions to emit changes

2010-12-06 Thread Mikeal Rogers
4 space is standard in a lot of language but most programmers vary style between languages. Python people are pretty opinionated about syntax and style and tend to be more resistant especially when writing JavaScript because the languages are so similar.

Re: use view functions to emit changes

2010-12-06 Thread Filipe David Manana
What about moving this long indentation discussion to a separate thread? On Mon, Dec 6, 2010 at 6:06 PM, Mikeal Rogers mikeal.rog...@gmail.com wrote: 4 space is standard in a lot of language but most programmers vary style between languages. Python people are pretty opinionated about syntax and

Re: use view functions to emit changes

2010-12-06 Thread Benoit Chesneau
On Mon, Dec 6, 2010 at 1:10 PM, Filipe David Manana fdman...@apache.org wrote: Sorry for the delay Benoît. Comments: 1) At https://github.com/benoitc/couchdb/compare/master...view_changes#L1R40 you're also changing the emit of the regular sandbpox (don't forget, in the previous statement

Re: use view functions to emit changes

2010-12-06 Thread Mikeal Rogers
The indentation thread is a little too indented :)

Re: use view functions to emit changes

2010-12-06 Thread Benoit Chesneau
On Mon, Dec 6, 2010 at 7:10 PM, Filipe David Manana fdman...@apache.org wrote: What about moving this long indentation discussion to a separate thread? I'm not sure it worth a thread, I'm pretty sure i'm the only one that find it hard to read a 2 chars indented line ;) - benoit

Re: use view functions to emit changes

2010-12-06 Thread till
On Mon, Dec 6, 2010 at 7:04 PM, Benoit Chesneau bchesn...@gmail.com wrote: On Mon, Dec 6, 2010 at 6:57 PM, Mikeal Rogers mikeal.rog...@gmail.com wrote: But for the record, nobody except people who wish they were writing Python use 4 space indentation everywhere. It's the part of crockford's

Re: use view functions to emit changes

2010-11-30 Thread Filipe David Manana
Hi Benoît, It's a good idea I think. Good work. I have some comments regarding the patch: 1) Doing a regexp substitution of the view function's code string seems like a recipe for disaster to me. I think the safe and clean way to go here is to create another sandbox, with a different 'emit'

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 12:22 PM, Filipe David Manana fdman...@apache.org wrote: Hi Benoît, It's a good idea I think. Good work. I have some comments regarding the patch: 1) Doing a regexp substitution of the view function's code string seems like a recipe for disaster to me. I think the

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
And thanks for the review anyway! - benoît On Tue, Nov 30, 2010 at 1:05 PM, Benoit Chesneau bchesn...@gmail.com wrote: On Tue, Nov 30, 2010 at 12:22 PM, Filipe David Manana fdman...@apache.org wrote: Hi Benoît, It's a good idea I think. Good work. I have some comments regarding the patch:

Re: use view functions to emit changes

2010-11-30 Thread Filipe David Manana
On Tue, Nov 30, 2010 at 12:05 PM, Benoit Chesneau bchesn...@gmail.com wrote: about 2 3 can we add indent rules on top of our sources from now ? I think there is something common between vim and emacs for example. That should solve such errors. I don't want to change my config each time I'm

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 1:13 PM, Filipe David Manana fdman...@apache.org wrote: On Tue, Nov 30, 2010 at 12:05 PM, Benoit Chesneau bchesn...@gmail.com wrote: about 2 3 can we add indent rules on top of our sources from now ? I think there is something common between vim and emacs for example.

Re: use view functions to emit changes

2010-11-30 Thread Filipe David Manana
On Tue, Nov 30, 2010 at 12:22 PM, Benoit Chesneau bchesn...@gmail.com wrote: I don't know why whitespaces are introduced. One sure things is that's the only external code I edit where I have it, and I edit a lot of code. Having indentations rules force any editor to follow them (except weird

Re: use view functions to emit changes

2010-11-30 Thread Jan Lehnardt
On 30 Nov 2010, at 13:05, Benoit Chesneau wrote: On Tue, Nov 30, 2010 at 12:22 PM, Filipe David Manana fdman...@apache.org wrote: 3) Avoid the unnecessary white-space only changes: https://github.com/benoitc/couchdb/commit/651e29e1bb767fb493bf75497623dae89bf9a5ad#L2R396

Re: use view functions to emit changes

2010-11-30 Thread Jan Lehnardt
Hi Benoit, On 29 Nov 2010, at 23:05, Benoit Chesneau wrote: Hi all, Tonight i've written t quick patch that allows the user to use map view function to filter changes. Here is the patch : https://github.com/benoitc/couchdb/commit/651e29e1bb767fb493bf75497623dae89bf9a5ad thoughts ?

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 1:56 PM, Jan Lehnardt j...@apache.org wrote: Hi Benoit, On 29 Nov 2010, at 23:05, Benoit Chesneau wrote: Hi all, Tonight i've written t quick patch that allows the user to use map view function to filter changes. Here is the patch :

Re: use view functions to emit changes

2010-11-30 Thread Filipe David Manana
On Tue, Nov 30, 2010 at 1:16 PM, Benoit Chesneau bchesn...@gmail.com wrote: That's what we discussed the other day on irc. It doesn't do more than Not everyone is always on IRC, and when there not always paying attention to every conversation there :) use map view function to filter changes  

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 1:50 PM, Jan Lehnardt j...@apache.org wrote: On 30 Nov 2010, at 13:05, Benoit Chesneau wrote: On Tue, Nov 30, 2010 at 12:22 PM, Filipe David Manana fdman...@apache.org wrote: 3) Avoid the unnecessary white-space only changes:

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 2:30 PM, Filipe David Manana fdman...@apache.org wrote: On Tue, Nov 30, 2010 at 1:16 PM, Benoit Chesneau bchesn...@gmail.com wrote: That's what we discussed the other day on irc. It doesn't do more than Not everyone is always on IRC, and when there not always paying

Re: use view functions to emit changes

2010-11-30 Thread Robert Newson
Am I the only one that thinks our code is already indented to 4 spaces? :) B. On Tue, Nov 30, 2010 at 1:32 PM, Benoit Chesneau bchesn...@gmail.com wrote: On Tue, Nov 30, 2010 at 1:50 PM, Jan Lehnardt j...@apache.org wrote: On 30 Nov 2010, at 13:05, Benoit Chesneau wrote: On Tue, Nov 30,

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 2:34 PM, Robert Newson robert.new...@gmail.com wrote: Am I the only one that thinks our code is already indented to 4 spaces? :) not the js one ;) - benoît

Re: use view functions to emit changes

2010-11-30 Thread Jan Lehnardt
On 30 Nov 2010, at 14:16, Benoit Chesneau wrote: On Tue, Nov 30, 2010 at 1:56 PM, Jan Lehnardt j...@apache.org wrote: Hi Benoit, On 29 Nov 2010, at 23:05, Benoit Chesneau wrote: Hi all, Tonight i've written t quick patch that allows the user to use map view function to filter

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 2:58 PM, Jan Lehnardt j...@apache.org wrote: On 30 Nov 2010, at 14:16, Benoit Chesneau wrote: On Tue, Nov 30, 2010 at 1:56 PM, Jan Lehnardt j...@apache.org wrote: Hi Benoit, On 29 Nov 2010, at 23:05, Benoit Chesneau wrote: Hi all, Tonight i've written t quick

Re: use view functions to emit changes

2010-11-30 Thread Jan Lehnardt
On 30 Nov 2010, at 15:14, Benoit Chesneau wrote: On Tue, Nov 30, 2010 at 2:58 PM, Jan Lehnardt j...@apache.org wrote: On 30 Nov 2010, at 14:16, Benoit Chesneau wrote: On Tue, Nov 30, 2010 at 1:56 PM, Jan Lehnardt j...@apache.org wrote: Hi Benoit, On 29 Nov 2010, at 23:05, Benoit

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 12:22 PM, Filipe David Manana fdman...@apache.org wrote: Hi Benoît, It's a good idea I think. Good work. I have some comments regarding the patch: 1) Doing a regexp substitution of the view function's code string seems like a recipe for disaster to me. I think the

Re: use view functions to emit changes

2010-11-30 Thread Filipe David Manana
Here is an updated patch. It now use a filter sandbox instead of patching the function and it fixes whitespaces. Why a separate function to init the filter_sandbox? It can be done at the end of the existing init_sandbox() function (perhaps renaming it to init_sandboxes). I would rename

Re: use view functions to emit changes

2010-11-30 Thread Benoit Chesneau
On Tue, Nov 30, 2010 at 4:44 PM, Filipe David Manana fdman...@apache.org wrote: Here is an updated patch. It now use a filter sandbox instead of patching the function and it fixes whitespaces. Why a separate function to init the filter_sandbox? It can be done at the end of the existing

use view functions to emit changes

2010-11-29 Thread Benoit Chesneau
Hi all, Tonight i've written t quick patch that allows the user to use map view function to filter changes. Here is the patch : https://github.com/benoitc/couchdb/commit/651e29e1bb767fb493bf75497623dae89bf9a5ad thoughts ? - benoît