BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
8d552700
Commit
8d552700
authored
Dec 08, 2015
by
Stan Hu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Provide better diagnostic message upon project creation errors
Prevents an Error 500 when project fails to create due to invalid parameters. See #3937
parent
3cf40548
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
+5
-2
CHANGELOG
CHANGELOG
+1
-0
create_service.rb
app/services/projects/create_service.rb
+4
-2
No files found.
CHANGELOG
View file @
8d552700
...
@@ -2,6 +2,7 @@ Please view this file on the master branch, on stable branches it's out of date.
...
@@ -2,6 +2,7 @@ Please view this file on the master branch, on stable branches it's out of date.
v 8.3.0 (unreleased)
v 8.3.0 (unreleased)
- Merge when build succeeds (Zeger-Jan van de Weg)
- Merge when build succeeds (Zeger-Jan van de Weg)
- Provide better diagnostic message upon project creation errors (Stan Hu)
- Bump gollum-lib to 4.1.0 (Stan Hu)
- Bump gollum-lib to 4.1.0 (Stan Hu)
- Fix broken group avatar upload under "New group" (Stan Hu)
- Fix broken group avatar upload under "New group" (Stan Hu)
- Update project repositorize size and commit count during import:repos task (Stan Hu)
- Update project repositorize size and commit count during import:repos task (Stan Hu)
...
...
app/services/projects/create_service.rb
View file @
8d552700
...
@@ -64,8 +64,10 @@ module Projects
...
@@ -64,8 +64,10 @@ module Projects
after_create_actions
if
@project
.
persisted?
after_create_actions
if
@project
.
persisted?
@project
@project
rescue
rescue
=>
e
@project
.
errors
.
add
(
:base
,
"Can't save project. Please try again later"
)
message
=
"Unable to save project:
#{
e
.
message
}
"
Rails
.
logger
.
error
(
message
)
@project
.
errors
.
add
(
:base
,
message
)
if
@project
@project
@project
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment