You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by jo...@apache.org on 2014/02/04 21:49:15 UTC

[1/2] git commit: [#7118] Fixed validation error handling on GitHub project importer

Updated Branches:
  refs/heads/master bfee3bc78 -> 9d3746113


[#7118] Fixed validation error handling on GitHub project importer

Signed-off-by: Cory Johns <cj...@slashdotmedia.com>


Project: http://git-wip-us.apache.org/repos/asf/incubator-allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-allura/commit/e3962915
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/e3962915
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/e3962915

Branch: refs/heads/master
Commit: e3962915951ba0f58d48f6d9571871365a489c48
Parents: bfee3bc
Author: Cory Johns <cj...@slashdotmedia.com>
Authored: Tue Feb 4 20:48:31 2014 +0000
Committer: Cory Johns <cj...@slashdotmedia.com>
Committed: Tue Feb 4 20:48:31 2014 +0000

----------------------------------------------------------------------
 ForgeImporters/forgeimporters/base.py           | 5 ++---
 ForgeImporters/forgeimporters/github/project.py | 6 +-----
 2 files changed, 3 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/e3962915/ForgeImporters/forgeimporters/base.py
----------------------------------------------------------------------
diff --git a/ForgeImporters/forgeimporters/base.py b/ForgeImporters/forgeimporters/base.py
index 848cb38..32f2ef3 100644
--- a/ForgeImporters/forgeimporters/base.py
+++ b/ForgeImporters/forgeimporters/base.py
@@ -305,10 +305,9 @@ class ProjectImporter(BaseController):
             redirect('.')
 
         self.after_project_create(c.project, **kw)
-        if isinstance(kw['tools'], basestring):
-            kw['tools'] = [kw['tools'], ]
+        tools = aslist(kw.get('tools'))
 
-        for importer_name in kw['tools']:
+        for importer_name in tools:
             ToolImporter.by_name(importer_name).post(**kw)
         M.AuditLog.log('import project from %s' % self.source)
 

http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/e3962915/ForgeImporters/forgeimporters/github/project.py
----------------------------------------------------------------------
diff --git a/ForgeImporters/forgeimporters/github/project.py b/ForgeImporters/forgeimporters/github/project.py
index 003adae..c4d8c61 100644
--- a/ForgeImporters/forgeimporters/github/project.py
+++ b/ForgeImporters/forgeimporters/github/project.py
@@ -17,8 +17,6 @@
 
 import logging
 
-from formencode import validators as fev
-
 from tg import expose, validate
 from tg.decorators import with_trailing_slash
 
@@ -58,10 +56,8 @@ class GitHubProjectImporter(base.ProjectImporter, GitHubOAuthMixin):
 
     @require_post()
     @expose()
-    @validate(process_validator)
+    @validate(process_validator, error_handler=index)
     def process(self, **kw):
-        if not type(kw['tools']) == list:
-            kw['tools'] = [kw['tools']]
         return super(self.__class__, self).process(**kw)
 
     @expose('json:')


[2/2] git commit: [#7081] Standardize on 'follow' with star icon

Posted by jo...@apache.org.
[#7081] Standardize on 'follow' with star icon

Signed-off-by: Tim Van Steenburgh <tv...@gmail.com>


Project: http://git-wip-us.apache.org/repos/asf/incubator-allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-allura/commit/9d374611
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/9d374611
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/9d374611

Branch: refs/heads/master
Commit: 9d37461135a1c8fd8a6e308d99cad55248fb4827
Parents: e396291
Author: Tim Van Steenburgh <tv...@gmail.com>
Authored: Fri Jan 31 14:52:12 2014 +0000
Committer: Cory Johns <cj...@slashdotmedia.com>
Committed: Tue Feb 4 20:49:01 2014 +0000

----------------------------------------------------------------------
 ForgeActivity/forgeactivity/widgets/follow.py | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/9d374611/ForgeActivity/forgeactivity/widgets/follow.py
----------------------------------------------------------------------
diff --git a/ForgeActivity/forgeactivity/widgets/follow.py b/ForgeActivity/forgeactivity/widgets/follow.py
index f5a15d7..1aed295 100644
--- a/ForgeActivity/forgeactivity/widgets/follow.py
+++ b/ForgeActivity/forgeactivity/widgets/follow.py
@@ -27,8 +27,8 @@ class FollowToggle(ew.SimpleForm):
         ew.SimpleForm.defaults,
         thing='project',
         action='follow',
-        action_label='watch',
-        icon='watch',
+        action_label='follow',
+        icon='star',
         following=False)
 
     class fields(ew_core.NameList):
@@ -42,8 +42,6 @@ class FollowToggle(ew.SimpleForm):
         if c.project.is_user_project:
             default_context.update(
                 thing=c.project.user_project_of.display_name,
-                action_label='follow',
-                icon='star',
             )
         else:
             default_context.update(thing=c.project.name)