Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1757)

Issue 6330064: More cleanup on items module. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 11 months ago by xiaq
Modified:
11 years, 10 months ago
Reviewers:
thomas.j.waldmann, Reimar Bauer
Visibility:
Public.

Description

Closing.

Patch Set 1 #

Total comments: 20

Patch Set 2 : small fixes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+91 lines, -97 lines) Patch
M MoinMoin/apps/frontend/views.py View 3 chunks +3 lines, -2 lines 0 comments Download
M MoinMoin/items/__init__.py View 1 8 chunks +81 lines, -92 lines 0 comments Download
M MoinMoin/items/_tests/test_Item.py View 2 chunks +7 lines, -3 lines 0 comments Download

Messages

Total messages: 6
xiaq
This is actually a follow-up of my previous changeset (http://hg.moinmo.in/moin/2.0/rev/339668f8ad06). Notes: * Item methods are ...
11 years, 11 months ago (2012-06-26 16:28:27 UTC) #1
Reimar Bauer
some comments http://codereview.appspot.com/6330064/diff/1/MoinMoin/apps/frontend/views.py File MoinMoin/apps/frontend/views.py (right): http://codereview.appspot.com/6330064/diff/1/MoinMoin/apps/frontend/views.py#newcode697 MoinMoin/apps/frontend/views.py:697: revid, size = item.modify({}, data, contenttype_guessed=contenttype) is ...
11 years, 11 months ago (2012-06-26 20:21:23 UTC) #2
xiaq
http://codereview.appspot.com/6330064/diff/1/MoinMoin/apps/frontend/views.py File MoinMoin/apps/frontend/views.py (right): http://codereview.appspot.com/6330064/diff/1/MoinMoin/apps/frontend/views.py#newcode697 MoinMoin/apps/frontend/views.py:697: revid, size = item.modify({}, data, contenttype_guessed=contenttype) On 2012/06/26 20:21:23, ...
11 years, 10 months ago (2012-06-27 03:39:25 UTC) #3
Reimar Bauer
answered http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/_tests/test_Item.py File MoinMoin/items/_tests/test_Item.py (right): http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/_tests/test_Item.py#newcode293 MoinMoin/items/_tests/test_Item.py:293: another_data = 'another_test_data' On 2012/06/27 03:39:25, xiaq wrote: ...
11 years, 10 months ago (2012-06-27 06:07:54 UTC) #4
ThomasJWaldmann
looks ok, but see the minor comments. thanks for cleaning up there. http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/__init__.py File MoinMoin/items/__init__.py ...
11 years, 10 months ago (2012-06-28 16:41:08 UTC) #5
xiaq
11 years, 10 months ago (2012-06-29 03:56:20 UTC) #6
http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/__init__.py
File MoinMoin/items/__init__.py (right):

http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/__init__.py#newco...
MoinMoin/items/__init__.py:724: return redirect(url_for_item(self.name))
On 2012/06/28 16:41:09, ThomasJWaldmann wrote:
> at some other places that uses this pattern it is (IIRC) like this:
> 
> if POST:
>    form =
>    if form.validate():
>        ...
>        return ...
> # here comes the GET and non-valid POST code
> ...
> return render_template(...)

I followed the pattern of +revert, +delete and +destroy. The above pattern only
applies when there is no code specific to GET compared with an erroneous POST.

http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/__init__.py#newco...
MoinMoin/items/__init__.py:1121: self['data_text'] =
item.data_storage_to_internal(item.data)
On 2012/06/28 16:41:09, ThomasJWaldmann wrote:
> this is somehow a bit asymmetric.
> here it is storage -> internal used for filling form
> below is form -> internal -> storage used for reading the form.

Fixing in next patch set.

http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/__init__.py#newco...
MoinMoin/items/__init__.py:1303: # meta_text doesn't work
On 2012/06/28 16:41:09, ThomasJWaldmann wrote:
> file a bug please

Filed https://bitbucket.org/thomaswaldmann/moin-2.0/issue/204

http://codereview.appspot.com/6330064/diff/1/MoinMoin/items/__init__.py#newco...
MoinMoin/items/__init__.py:1387: Draw.ModifyForm._load(self, item)
On 2012/06/28 16:41:09, ThomasJWaldmann wrote:
> wut??

Fixing...
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b