Commit Graph
2654 Commits
Author SHA1 Message Date
Robert Speicher 6ae39c2cd1 Remove alert_type attribute from BroadcastMessage 2016-01-13 11:34:57 -05:00
Douwe Maan c7d9e7806a Merge branch 'fix/reference_filter_uri_decode_error_for_master' into 'master'
Fix #9963 reference_filter "Encoding::CompatibilityError" bug with some complex URL;

https://github.com/gitlabhq/gitlabhq/pull/9964

@DouweM

See merge request !2383
2016-01-13 14:21:32 +00:00
Dmitriy Zaporozhets 73e0754070 Merge branch 'rs-block-user-before-removal' into 'master'
Block the reported user before destroying the record

This is intended to prevent the user from creating new objects while the
transaction that removes them is being run, resulting in objects with
nil authors which can then not be edited.

See https://gitlab.com/gitlab-org/gitlab-ce/issues/7117

See merge request !2402
2016-01-13 09:14:30 +00:00
Robert Speicher da40274fdc Block the reported user before destroying the record
This is intended to prevent the user from creating new objects while the
transaction that removes them is being run, resulting in objects with
nil authors which can then not be edited.

See https://gitlab.com/gitlab-org/gitlab-ce/issues/7117
2016-01-12 20:59:55 -05:00
Landon 4819de1e70 Mention channel/key bug in irkerd docs
Per this issue: https://gitlab.com/esr/irker/issues/2

A documentation update was added to irkerd (https://gitlab.com/esr/irker/commit/190808c37d4ab5f0f16fe35352ff36863c2732d5) but the bug is still there. Making a note of it here could save someone a lot of hassle. 

This could probably be worded better if someone else wants to take a stab at it.
2016-01-12 15:54:09 -07:00
Jason Lee 932a247f5f Use CGI.escape instead of URI.escape, because URI is obsoleted.
ref: https://github.com/ruby/ruby/commit/238b979f1789f95262a267d8df6239806f2859cc
2016-01-12 18:20:03 +08:00
Dmitriy Zaporozhets 5500f9159f Merge branch 'group-issues-sorting' into 'master'
Improve performance of getting issues on group level

For testing I used the URL http://localhost:3000/groups/gitlab-org/issues?milestone_title=8.1. Prior to these changes said URL would take about 10-12 seconds to load. By applying these changes the loading time has been reduced to roughly 2-3 seconds. 

There's still some stuff going on in some views that I have to look at, resolving those changes might reduce the loading time a bit more. I also still have to check if I didn't break too many tests.

Fixes: gitlab-org/gitlab-ce#3707 gitlab-org/gitlab-ce#4071 

See merge request !2318
2016-01-11 15:28:41 +00:00
Stan Hu b7aa13a0cf Before project save ensure that a runners_token exists 2016-01-10 18:12:47 -08:00
Stan Hu 4b4fdf58c7 Fix Error 500 when visiting build page of project with nil runners_token
Properly ensure that the token exists and add defensively check for a
non-nil value.

Closes #4294
2016-01-10 18:12:47 -08:00
Robert Speicher 4de89291a3 Merge branch 'fix_jira_shortterm' into 'master'
Do not call API if there is no API URL

Fixes #5878 

CE users may not be interested in the new JIRA features. In this case,
we should detect they haven't set an API URL and fallback to the
behavior pre-8.3. This patch does that very easily.

There are planned improvements to JIRA in future releases such as
gitlab-org/gitlab-ce#5541 which will make this more configurable.

See merge request !2341
2016-01-10 22:12:10 +00:00
Stan Hu 7403df6ca7 Merge branch 'suppress-allow-failure-builds' into 'master'
Suppress e-mails on failed builds if allow_failure is set

Every time I push to GitLab, I get > 2 emails saying a spec failed when I don't care about the benchmarks and others that have `allow_failure` set to `true`.

@ayufan mentioned creating a summary e-mail to prevent getting one e-mail per build, but the latter might actually be desirable. For example, I do want to know if Rubocop errors fail right away.

See merge request !2178
2016-01-08 17:31:35 +00:00
Achilleas Pipinellis 255a63564b Merge branch 'docs_project_services' into 'master'
Project services and JIRA documentation clean up

Closes https://gitlab.com/gitlab-org/gitlab-ee/issues/176

This was first aiming to fix the JIRA references to EE, but as I was going through it, I decided to revamp more.

@Haydn once merged here and then Valery merges CE into EE it should be fixed in doc.gitlab.com as well.

@dblessing the docs state that we support JIRA 6.x. I see that 7.x is out, should the docs be amended? Also we seem to have a place to document services (http://doc.gitlab.com/ce/project_services/project_services.html), but the JIRA doc is under integration :/ I'd like it to have it moved under `project_services/`, but I guess most customers know the current URL better.

See merge request !2345
2016-01-08 15:05:35 +00:00
Achilleas Pipinellis d09f1a4443 Remove useless assignment to variable 2016-01-08 15:22:42 +01:00
Achilleas Pipinellis fc7b14a534 Remove reference to EE from JIRA service model 2016-01-08 13:21:40 +01:00
Dmitriy Zaporozhets 08213ed4f5 Merge branch 'accept-2xx-status-codes-for-webhooks' into 'master'
Accept 2xx status codes for successful Web hook triggers

Closes https://github.com/gitlabhq/gitlabhq/issues/9956

See merge request !2332
2016-01-08 10:56:39 +00:00
Robert Speicher fa36749bce Add two custom Date/Time conversion formats 2016-01-07 20:01:08 -05:00
Drew Blessing f7fdcb95da Do not call API if there is no API URL 2016-01-07 16:23:42 -06:00
Robert Speicher 59305715e9 Remove stamp gem
Closes #5908
2016-01-07 16:28:33 -05:00
Robert Speicher 90510f0037 Merge branch 'milestone-ref' into 'master'
Link to milestone in "Milestone changed" system note

Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/4141

See merge request !2203
2016-01-07 19:22:43 +00:00
Stan Hu 69209612e1 Suppress e-mails on failed builds if allow_failure is set
Every time I push to GitLab, I get > 2 emails saying a spec failed when
I don't care about benchmarks and other specs that have `allow_failure` set to `true`.
2016-01-07 10:45:39 -08:00
Dmitriy Zaporozhets 3c93e588e9 Merge branch 'annotate-models-20160105' into 'master'
Annotate models

Time to refresh the comments via `annotate`.


See merge request !2311
2016-01-07 18:22:32 +00:00
Yorick Peterse 19a0db30ba Removed ORDER BY in "of_group" scopes
These scopes don't care about the order. Removing the explicit "ORDER
BY" can speed up the queries by a little bit.
2016-01-07 15:34:37 +01:00
Stan Hu 8386edafd1 Accept 2xx status codes for successful Web hook triggers
Closes https://github.com/gitlabhq/gitlabhq/issues/9956
2016-01-07 06:28:24 -08:00
Dmitriy Zaporozhets 4443a5f3c7 Add support for ref and path to commits filtering
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2016-01-07 15:16:11 +01:00
Yorick Peterse 0d0049c058 Don't pluck IDs when getting issues/MRs per group
This replaces plucking of IDs with a sub-query, saving the overhead of
loading the data in Ruby and then mapping the rows to an Array of IDs.
This also scales much better when dealing with a large amount of IDs
that would be involved.
2016-01-07 14:53:02 +01:00
Yorick Peterse 9dacc3bc56 Sort by ID when sorting using "Recently created"
Sorting by "id" has the same effect as sorting by created_at while
performing far better and without the need of an extra index (in case
one wanted to speed up sorting by "created_at").

Sorting by "Recently updated" still uses the physical "updated_at"
column as there's no way to use the "id" column for this instead.
2016-01-07 14:53:02 +01:00
Jacob Vosmaer 41b8a238ce Merge branch 'master' of github.com:gitlabhq/gitlabhq 2016-01-07 12:56:18 +01:00
Douwe Maan 539b41929b Milestone reference is a Markdown link 2016-01-07 12:26:05 +01:00
Robert Speicher b93744e300 Merge branch 'merge-when-build-succeeds-unchecked' into 'master'
Get "Merge when build succeeds" to work when commits were pushed to MR
target branch while builds were running

The Merge when build succeeds service only merges when the MR is
mergeable (open, not WIP, no conflicts).

When the target branch is updated, all affected MRs have their merge
status set to `unchecked`, and the conflicts check will only happen
when `check_if_can_be_merged` is called, which happens when the MR page
is viewed.

When someone enables the automatic merge, the target branch is updated,
no-one views the MR page again, and the build succeeds, the mergeability
check will fail and the MR will not in fact be merged.

This MR makes sure `check_if_can_be_merged` is always called when MR
mergeability is checked.

See merge request !2304
2016-01-06 18:58:10 +00:00
Robert Speicher 623fa2caf7 Merge branch 'fix-banzai-cache' into 'master'
Fix mentionable reference extraction caching.

Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/4130

Reverts https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/2120 and https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/2283

See merge request !2315
2016-01-06 18:11:46 +00:00
Stan Hu 79c0e7212a Annotate models 2016-01-06 13:09:55 +00:00
Douwe Maan 8b39b8cd54 Merge branch 'fix/project-destroy-callbacks' into 'master'
Fix project destroy callback

See gitlab-org/gitlab-ee!107.

See merge request !2307
2016-01-06 13:00:50 +00:00
Douwe Maan 37ce5f312e Fix mentionable reference extraction caching. 2016-01-06 13:33:11 +01:00
Douwe Maan 2474a5921f Merge branch 'master' into milestone-ref 2016-01-06 13:06:50 +01:00
Douwe Maan c0849101e6 Merge branch 'master' into merge-when-build-succeeds-unchecked 2016-01-06 13:06:01 +01:00
Robert Speicher d453b24aca Merge branch 'validate-readme-format' into 'master'
Validate README format

Take the first previewable README file as project's README, otherwise if
none file is available, or we can't preview any of them, we assume that
project doesn't have a README file.

Fixes #3978
2016-01-05 17:03:24 -05:00
Grzegorz Bizon db2d067eec Fix project destroy callback
See gitlab-org/gitlab-ee!107.
2016-01-05 20:49:31 +01:00
Douwe Maan 8de1f7159c Merge branch 'mikew1/gitlab-ce-better-asana-refs' into 'master'
Better support for referencing and closing issues in asana_service.rb (by @mikew1)



See merge request !2302
2016-01-05 16:10:16 +00:00
Douwe Maan 0b66151632 Remove icon from milestone reference. 2016-01-05 16:45:53 +01:00
Douwe Maan 07c39c9976 Merge branch 'brunsa2/gitlab-ce-diverging-branch-graphs' into 'master'
Add graphs of commits ahead/behind default branch (by @brunsa2)

Replaces https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/1716

See merge request !2301
2016-01-05 15:44:22 +00:00
Douwe Maan fd91b48f24 Merge branch 'master' into milestone-ref 2016-01-05 16:40:23 +01:00
Douwe Maan 097faeb481 Get "Merge when build succeeds" to work when commits were pushed to MR target branch while builds were running 2016-01-05 16:30:03 +01:00
Douglas Barbosa Alexandre 6ce01ca3ec Validate README format before displaying
Take the first previewable README file as project’s README, otherwise
if none file is available, or we can’t preview any of them, we assume
that project doesn’t have a README file.
2016-01-05 11:06:18 -02:00
Robert Speicher 46a220ae3c Add AbuseReport#notify
Tell, Don't Ask.
2016-01-04 18:59:42 -05:00
Dmitriy Zaporozhets e586492e48 Merge branch 'rs-issue-201' into 'master'
Prevent duplicate "username has already been taken" validation message

Closes #201 - two-year-old bug, woo! 💥 🎉

See merge request !2279
2016-01-04 17:20:38 +00:00
Stan Hu 561acdebf8 Merge branch 'extra-system-hooks' into 'master'
Added system hooks messages for renaming and transferring a project

This is work in progress but I wanted to get some feedback on it in case there is something I've missed or a better way to do it.

As the title says when a project is renamed or transferred to another group a system hook message is generated.

Currently adds a couple of extra properties to the standard project system hooks messages.

old_path_with_namespace - The old path of the project so we can see what has been renamed / transferred
changed_at - The time that change took place

My main concern is if there is a better way of doing this than passing the extra_data variable into the system hook.  Would it be better to extend the project model with these 2 items as transient properties as I doubt they would need to be saved to the database?  The other 

I've also seen, but can't find, someone talking about the emails sent when a project is renamed or transferred doesn't reference the original project path so if you have similarly named projects then you might not know what has been moved.  I think the extra_data (or however it is best to implement this) would allow the extra information to be sent in emails.

Closes [System hooks for project transfer and repository rename](http://feedback.gitlab.com/forums/176466-general/suggestions/6006233-system-hooks-for-project-transfer-and-repository-r)


See merge request !611
2016-01-04 15:39:52 +00:00
Mike Wyatt bb6b793c55 Don't log backtrace in Asana service 2016-01-04 11:19:39 -04:00
Valery Sizov 8b18449125 remove public field from namespace and refactoring 2016-01-04 16:00:29 +02:00
Steve Norman 79ec7f2897 Added system hooks messages for renaming and transferring a project 2016-01-04 13:48:00 +00:00
Robert Speicher fd178c1e7d Prevent duplicate "username has already been taken" validation message
Closes #201 - two-year-old bug, woo! 💥 🎉
2016-01-02 20:03:28 -05:00