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
09a6d328
Commit
09a6d328
authored
Apr 19, 2017
by
Douglas Barbosa Alexandre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Keep track of import errors
parent
bd9e5c5d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
+10
-0
import.rb
lib/github/import.rb
+10
-0
No files found.
lib/github/import.rb
View file @
09a6d328
...
...
@@ -50,6 +50,7 @@ module Github
fetch_issues
fetch_wiki_repository
expire_repository_cache
track_errors
errors
end
...
...
@@ -369,6 +370,15 @@ module Github
repository
.
expire_content_cache
end
def
track_errors
return
unless
errors
.
any?
project
.
update_column
(
:import_error
,
{
message:
'The remote data could not be fully imported.'
,
errors:
errors
}.
to_json
)
end
def
error
(
type
,
url
,
message
)
errors
<<
{
type:
type
,
url:
Gitlab
::
UrlSanitizer
.
sanitize
(
url
),
error:
message
}
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