Files: 
CommentFileSizeAuthor
#17 user-convert_user_block_variables_to_cmi-1823348-17.patch6.73 KBwebflo
PASSED: [[SimpleTest]]: [MySQL] 46,909 pass(es).
[ View ]
#16 user-convert_user_block_variables_to_cmi-1823348-16.patch6.76 KBwebflo
PASSED: [[SimpleTest]]: [MySQL] 46,918 pass(es).
[ View ]
#15 user-convert_user_block_variables_to_cmi-1823348-15.patch10.22 KBwebflo
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch user-convert_user_block_variables_to_cmi-1823348-15.patch. Unable to apply patch. See the log in the details link for more information.
[ View ]
#15 user-convert_user_block_variables_to_cmi-1823348-15.interdiff.txt1.34 KBwebflo
#13 user-convert_user_block_variables_to_cmi-1823348-12.patch6.06 KBasaal
PASSED: [[SimpleTest]]: [MySQL] 46,590 pass(es).
[ View ]
#9 user-convert_user_block_variables_to_cmi-1823348-8.patch5.82 KBasaal
PASSED: [[SimpleTest]]: [MySQL] 46,426 pass(es).
[ View ]
#5 user-convert_user_block_variables_to_cmi-1823348-5.patch5.51 KBasaal
PASSED: [[SimpleTest]]: [MySQL] 46,506 pass(es).
[ View ]
user_block_cmi.patch5.04 KBAlbert Volkman
PASSED: [[SimpleTest]]: [MySQL] 46,227 pass(es).
[ View ]

Comments

Status:Active» Needs review

Status:Needs review» Needs work

+++ b/core/modules/user/config/user.settings.ymlundefined
@@ -12,3 +12,6 @@ notify:
+block_max_list_count: '10'
+block_seconds_online: '900'
+block_whois_new_count: '5'
diff --git a/core/modules/user/user.module b/core/modules/user/user.module

Group this in a block key. Like block.max_list_count and block.seconds_online

Assigned:Unassigned» asaal

The patch doesn't work on root system of drupal.

I checked out a new branch and apply the following line in command shell:

'git apply -v user_block_cmi.patch'

dlamp@dlamp-vm-server:~/workspace/drupal/drupal-8x-dev/htdocs$ git apply -v user_block_cmi.patch
Checking patch core/modules/user/config/user.settings.yml...
warning: core/modules/user/config/user.settings.yml has type 100755, expected 100644
error: while searching for:
register_pending_approval: '1'
register: visitors
signatures: '0'

error: patch failed: core/modules/user/config/user.settings.yml:12
error: core/modules/user/config/user.settings.yml: patch does not apply
Checking patch core/modules/user/user.module...
Hunk #1 succeeded at 722 (offset -41 lines).
Hunk #2 succeeded at 740 (offset -41 lines).
Hunk #3 succeeded at 805 (offset -41 lines).
Hunk #4 succeeded at 821 (offset -41 lines).
Hunk #5 succeeded at 835 (offset -41 lines).

but it doesn't work and the patch was not applied.

I make change manually from patch above and create new one.

Assigned:asaal» Unassigned
Status:Needs work» Needs review
StatusFileSize
new5.51 KB
PASSED: [[SimpleTest]]: [MySQL] 46,506 pass(es).
[ View ]

It is fixed and needs review.

Assigned:Unassigned» asaal

Status:Needs review» Needs work

Needs an upgrade path. See http://drupal.org/node/1667896#upgrade

Issue tags:+Needs upgrade path

Tagging accordingly.

Status:Needs work» Needs review
StatusFileSize
new5.82 KB
PASSED: [[SimpleTest]]: [MySQL] 46,426 pass(es).
[ View ]

I have add a upgrade path and new yml file for separate the user_block_* settings.

This patch works fine for me.
Variables are stored in config and the blocks work as they did before.

Status:Needs review» Reviewed & tested by the community

This patch works fine for me.
Variables are stored in config and the blocks work as they did before.

+        $count = config('user.block')->get('whois_new_count');
+        $interval = REQUEST_TIME - config('user.block')->get('seconds_online');
+        $max_users = config('user.block')->get('max_list_count');

Minor nitpick, these should probably use a common $config = config('user.block'); as in user_block_save().

Also, do we need tests for the upgrade path?

Status:Reviewed & tested by the community» Needs review
StatusFileSize
new6.06 KB
PASSED: [[SimpleTest]]: [MySQL] 46,590 pass(es).
[ View ]

Added the minor nitpick. ;-)

Status:Needs review» Reviewed & tested by the community

The new patch works as well as #9.
The points of #12 are fixed.

I think that tests are not needed, because the functionality doesn't change.

Status:Reviewed & tested by the community» Needs review
StatusFileSize
new1.34 KB
new10.22 KB
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch user-convert_user_block_variables_to_cmi-1823348-15.patch. Unable to apply patch. See the log in the details link for more information.
[ View ]

Reverted the changed file permissions from the patch in #13. I found one variable_get in the test and converted this to cmi.

StatusFileSize
new6.76 KB
PASSED: [[SimpleTest]]: [MySQL] 46,918 pass(es).
[ View ]

Ooops. Uploaded the wrong patch.

StatusFileSize
new6.73 KB
PASSED: [[SimpleTest]]: [MySQL] 46,909 pass(es).
[ View ]

Status:Needs review» Needs work
Issue tags:-Needs upgrade path

The last submitted patch, user-convert_user_block_variables_to_cmi-1823348-17.patch, failed testing.

Status:Needs work» Needs review

Status:Needs review» Needs work

The last submitted patch, user-convert_user_block_variables_to_cmi-1823348-17.patch, failed testing.

Status:Needs work» Needs review
Issue tags:+Needs upgrade path

Hi @webflo thanks for reviewing and changing the test case.

Status:Needs review» Reviewed & tested by the community

done!

Status:Reviewed & tested by the community» Fixed

Committed/pushed to 8.x, thanks!

fyi, this patch was kinda pointless, as this is all getting refactored: #1535868: Convert all blocks into plugins

oh well, no big.

Automatically closed -- issue fixed for 2 weeks with no activity.