Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SystemStackError (stack level too deep) при совместной работе с плангином clipboard_image_paste #5

Open
pragmaton opened this issue Jul 27, 2015 · 1 comment

Comments

@pragmaton
Copy link
Contributor

Для простоты свел условия к минимум.
Чистый Redmine 2.6.1
Устанавливаем ваш плагин и https://github.com/peclik/clipboard_image_paste В котором так же есть патч Issue

Пытаемся отредактировать любое поле тикета. При сохранение получаем Internal error
если смотреть в дев консоль, то видим

Completed 500 Internal Server Error in 110.2ms
SystemStackError (stack level too deep):
  actionpack (3.2.21) lib/action_dispatch/middleware/reloader.rb:70

К сожалению, я не очень силен рельсах и redmine. Как мне кажется проблема связана с тем что патч подгружается несколько раз, не смотря на вашу проверку.
Моих навыков не хватило, что бы глубоко понять проблему, но на базе http://stackoverflow.com/a/11295999 сделал патч, который вроде как решает проблему. Но мне кажется он кривоват...

Подробная выдача дев консоли

Started PUT "/issues/1" for 127.0.0.1 at 2015-07-27 15:30:37 +0700
Processing by IssuesController#update as HTML
  Parameters: {"utf8"=>"✓", "authenticity_token"=>"cCqcTtighmlTpzK1TZGHilwhqMr4JQjEYfiM4EtzM9Q=", "issue"=>{"is_private"=>"0", "tracker_id"=>"2", "subject"=>"ti", "description"=>"", "status_id"=>"3", "priority_id"=>"1", "assigned_to_id"=>"1", "parent_issue_id"=>"", "start_date"=>"2015-07-26", "due_date"=>"", "estimated_hours"=>"", "done_ratio"=>"0", "notes"=>"", "private_notes"=>"0", "lock_version"=>"17"}, "time_entry"=>{"hours"=>"", "activity_id"=>"", "comments"=>""}, "last_journal_id"=>"26", "commit"=>"Submit", "id"=>"1"}
   (0.2ms)  SELECT MAX(`settings`.`updated_on`) AS max_id FROM `settings` 
  User Load (0.2ms)  SELECT `users`.* FROM `users` WHERE `users`.`type` IN ('User', 'AnonymousUser') AND `users`.`status` = 1 AND `users`.`id` = 1 LIMIT 1
  Current user: admin (id=1)
  Issue Load (0.2ms)  SELECT `issues`.* FROM `issues` WHERE `issues`.`id` = 1 LIMIT 1
  Project Load (0.2ms)  SELECT `projects`.* FROM `projects` WHERE `projects`.`id` = 1 LIMIT 1
  SQL (0.2ms)  SELECT `enabled_modules`.`name` FROM `enabled_modules` WHERE `enabled_modules`.`project_id` = 1
  TimeEntryActivity Load (0.3ms)  SELECT `enumerations`.* FROM `enumerations` WHERE `enumerations`.`type` IN ('TimeEntryActivity') AND `enumerations`.`is_default` = 1 ORDER BY enumerations.position ASC LIMIT 1
  Tracker Load (0.2ms)  SELECT `trackers`.* FROM `trackers` WHERE `trackers`.`id` = 2 LIMIT 1
  IssueCustomField Load (0.3ms)  SELECT `custom_fields`.* FROM `custom_fields` WHERE `custom_fields`.`type` IN ('IssueCustomField') AND (is_for_all = 1 OR id IN (SELECT DISTINCT cfp.custom_field_id FROM custom_fields_projects cfp WHERE cfp.project_id = 1)) ORDER BY custom_fields.position ASC
  IssueCustomField Load (0.2ms)  SELECT `custom_fields`.* FROM `custom_fields` INNER JOIN `custom_fields_trackers` ON `custom_fields`.`id` = `custom_fields_trackers`.`custom_field_id` WHERE `custom_fields`.`type` IN ('IssueCustomField') AND `custom_fields_trackers`.`tracker_id` = 2
   (0.3ms)  SELECT COUNT(*) FROM `projects` WHERE (projects.status = 1 AND projects.id IN (SELECT em.project_id FROM enabled_modules em WHERE em.name='issue_tracking'))
  IssueStatus Load (0.2ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 6 LIMIT 1
  Role Load (0.1ms)  SELECT `roles`.* FROM `roles` 
  User Load (0.2ms)  SELECT `users`.* FROM `users` WHERE `users`.`type` IN ('User', 'AnonymousUser') AND `users`.`id` = 1 LIMIT 1
  WorkflowTransition Load (0.4ms)  SELECT `workflows`.* FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowTransition') AND `workflows`.`old_status_id` = 6 AND (role_id IN (1,2,3,4,5) AND tracker_id = 2 AND ((author = 0 AND assignee = 0) OR author = 1 OR assignee = 1))
  IssueStatus Load (0.2ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` IN (1, 2, 3, 4, 5)
  IssueRelation Load (0.2ms)  SELECT `issue_relations`.* FROM `issue_relations` WHERE `issue_relations`.`issue_to_id` = 1
  CACHE (0.0ms)  SELECT COUNT(*) FROM `projects` WHERE (projects.status = 1 AND projects.id IN (SELECT em.project_id FROM enabled_modules em WHERE em.name='issue_tracking'))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 6 LIMIT 1
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
  CACHE (0.0ms)  SELECT `workflows`.* FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowTransition') AND `workflows`.`old_status_id` = 6 AND (role_id IN (1,2,3,4,5) AND tracker_id = 2 AND ((author = 0 AND assignee = 0) OR author = 1 OR assignee = 1))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
   (0.4ms)  SELECT COUNT(*) FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowPermission') AND `workflows`.`tracker_id` = 2 AND `workflows`.`old_status_id` = 6 AND `workflows`.`role_id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT `trackers`.* FROM `trackers` WHERE `trackers`.`id` = 2 LIMIT 1
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
  CACHE (0.0ms)  SELECT COUNT(*) FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowPermission') AND `workflows`.`tracker_id` = 2 AND `workflows`.`old_status_id` = 6 AND `workflows`.`role_id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 6 LIMIT 1
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
  CACHE (0.0ms)  SELECT `workflows`.* FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowTransition') AND `workflows`.`old_status_id` = 6 AND (role_id IN (1,2,3,4,5) AND tracker_id = 2 AND ((author = 0 AND assignee = 0) OR author = 1 OR assignee = 1))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT COUNT(*) FROM `projects` WHERE (projects.status = 1 AND projects.id IN (SELECT em.project_id FROM enabled_modules em WHERE em.name='issue_tracking'))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 6 LIMIT 1
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
  CACHE (0.0ms)  SELECT `workflows`.* FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowTransition') AND `workflows`.`old_status_id` = 6 AND (role_id IN (1,2,3,4,5) AND tracker_id = 2 AND ((author = 0 AND assignee = 0) OR author = 1 OR assignee = 1))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT COUNT(*) FROM `projects` WHERE (projects.status = 1 AND projects.id IN (SELECT em.project_id FROM enabled_modules em WHERE em.name='issue_tracking'))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 6 LIMIT 1
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
  CACHE (0.0ms)  SELECT `workflows`.* FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowTransition') AND `workflows`.`old_status_id` = 6 AND (role_id IN (1,2,3,4,5) AND tracker_id = 2 AND ((author = 0 AND assignee = 0) OR author = 1 OR assignee = 1))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
   (0.3ms)  SELECT COUNT(*) FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowPermission') AND `workflows`.`tracker_id` = 2 AND `workflows`.`old_status_id` = 3 AND `workflows`.`role_id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 6 LIMIT 1
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
  CACHE (0.0ms)  SELECT `workflows`.* FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowTransition') AND `workflows`.`old_status_id` = 6 AND (role_id IN (1,2,3,4,5) AND tracker_id = 2 AND ((author = 0 AND assignee = 0) OR author = 1 OR assignee = 1))
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` IN (1, 2, 3, 4, 5)
   (0.1ms)  BEGIN
  IssuePriority Load (0.2ms)  SELECT `enumerations`.* FROM `enumerations` WHERE `enumerations`.`type` IN ('IssuePriority') AND `enumerations`.`id` = 1 ORDER BY enumerations.position ASC LIMIT 1
  IssueStatus Load (0.1ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 3 LIMIT 1
  CACHE (0.0ms)  SELECT `roles`.* FROM `roles` 
  CACHE (0.0ms)  SELECT COUNT(*) FROM `workflows` WHERE `workflows`.`type` IN ('WorkflowPermission') AND `workflows`.`tracker_id` = 2 AND `workflows`.`old_status_id` = 3 AND `workflows`.`role_id` IN (1, 2, 3, 4, 5)
  CACHE (0.0ms)  SELECT `issue_statuses`.* FROM `issue_statuses` WHERE `issue_statuses`.`id` = 6 LIMIT 1
   (0.2ms)  UPDATE `issues` SET `status_id` = 3, `updated_on` = '2015-07-27 15:30:37', `lock_version` = 18 WHERE (`issues`.`id` = 1 AND `issues`.`lock_version` = 17)
  IssueCustomField Load (0.2ms)  SELECT `custom_fields`.* FROM `custom_fields` INNER JOIN `custom_fields_trackers` ON `custom_fields`.`id` = `custom_fields_trackers`.`custom_field_id` WHERE `custom_fields`.`type` IN ('IssueCustomField') AND `custom_fields_trackers`.`tracker_id` = 2
  SQL (0.4ms)  SELECT `custom_values`.`id` AS t0_r0, `custom_values`.`customized_type` AS t0_r1, `custom_values`.`customized_id` AS t0_r2, `custom_values`.`custom_field_id` AS t0_r3, `custom_values`.`value` AS t0_r4, `custom_fields`.`id` AS t1_r0, `custom_fields`.`type` AS t1_r1, `custom_fields`.`name` AS t1_r2, `custom_fields`.`field_format` AS t1_r3, `custom_fields`.`possible_values` AS t1_r4, `custom_fields`.`regexp` AS t1_r5, `custom_fields`.`min_length` AS t1_r6, `custom_fields`.`max_length` AS t1_r7, `custom_fields`.`is_required` AS t1_r8, `custom_fields`.`is_for_all` AS t1_r9, `custom_fields`.`is_filter` AS t1_r10, `custom_fields`.`position` AS t1_r11, `custom_fields`.`searchable` AS t1_r12, `custom_fields`.`default_value` AS t1_r13, `custom_fields`.`editable` AS t1_r14, `custom_fields`.`visible` AS t1_r15, `custom_fields`.`multiple` AS t1_r16, `custom_fields`.`format_store` AS t1_r17, `custom_fields`.`description` AS t1_r18 FROM `custom_values` LEFT OUTER JOIN `custom_fields` ON `custom_fields`.`id` = `custom_values`.`custom_field_id` WHERE `custom_values`.`customized_id` = 1 AND `custom_values`.`customized_type` = 'Issue' ORDER BY custom_fields.position
  SQL (0.1ms)  INSERT INTO `journals` (`created_on`, `journalized_id`, `journalized_type`, `notes`, `private_notes`, `user_id`) VALUES ('2015-07-27 15:30:37', 1, 'Issue', '', 0, 1)
  SQL (0.1ms)  INSERT INTO `journal_details` (`journal_id`, `old_value`, `prop_key`, `property`, `value`) VALUES (27, 6, 'status_id', 'attr', 3)
  Setting Load (0.1ms)  SELECT `settings`.* FROM `settings` WHERE `settings`.`name` = 'notified_events' LIMIT 1
   (5.6ms)  ROLLBACK
Completed 500 Internal Server Error in 110.2ms

SystemStackError (stack level too deep):
  actionpack (3.2.21) lib/action_dispatch/middleware/reloader.rb:70

Info страница redmine

Environment:
  Redmine version                2.6.1.stable
  Ruby version                   2.1.3-p242 (2014-09-19) [x86_64-linux-gnu]
  Rails version                  3.2.21
  Environment                    production
  Database adapter               Mysql2
SCM:
  Subversion                     1.8.13
  Cvs                            1.12.12
  Git                            2.1.4
  Filesystem                     
Redmine plugins:
  clipboard_image_paste          1.10
  redmine__select2               1.0.5
  redmine_digest                 1.0.9
@pragmaton
Copy link
Contributor Author

Пул тут #6

nodecarter added a commit that referenced this issue Jul 27, 2015
Попытка решить  #5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant