You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Used Zammad version: stable 5.1 as of 4pm UTC, 8th April
Installation method (source, package, ..): any
Operating system: any
Database + version: any
Elasticsearch version: any
Browser + version: any
Ticket: #10103590
Note: As this is our sequencer involved, it might also affect other sequencer based Migrators.
Expected behavior:
If the migration source does not have any Organisations ("Company" for freshdesk) configured, Zammad will quietly skip the synchronization and finish successfully.
Actual behavior:
If you do not have any Companies configured within Freshdesk, Zammad will die during Contact import as it tries to reference non existing organizations.
E, [2022-04-08T18:13:01.181090 #22474-191100] ERROR -- : ImportJob 'Import::Freshdesk' failed: undefined method `[]' for nil:NilClass
E, [2022-04-08T18:13:01.181210 #22474-191100] ERROR -- : undefined method `[]' for nil:NilClass (NoMethodError)
lib/sequencer/unit/import/freshdesk/contact/mapping.rb:32:in `organization_id'
lib/sequencer/unit/import/freshdesk/contact/mapping.rb:18:in `block in process'
lib/sequencer/unit/import/common/mapping/mixin/provide_mapped.rb:28:in `block in provide_mapped'
lib/sequencer/state.rb:44:in `provide'
lib/sequencer/unit/import/common/mapping/mixin/provide_mapped.rb:27:in `provide_mapped'
lib/sequencer/unit/import/freshdesk/contact/mapping.rb:14:in `process'
lib/sequencer/unit/base.rb:249:in `process'
lib/sequencer.rb:76:in `block (4 levels) in process'
lib/mixin/start_finish_logger.rb:9:in `log_start_finish'
lib/sequencer.rb:75:in `block (3 levels) in process'
lib/sequencer/state.rb:152:in `process'
lib/sequencer.rb:73:in `block (2 levels) in process'
lib/sequencer/units.rb:28:in `block in each'
lib/sequencer/units.rb:27:in `each'
lib/sequencer/units.rb:27:in `each'
lib/sequencer.rb:71:in `each_with_index'
lib/sequencer.rb:71:in `block in process'
lib/mixin/start_finish_logger.rb:9:in `log_start_finish'
lib/sequencer.rb:69:in `process'
lib/sequencer.rb:24:in `process'
lib/sequencer/unit/import/freshdesk/perform.rb:16:in `block in process'
lib/sequencer/unit/import/freshdesk/perform.rb:15:in `each'
lib/sequencer/unit/import/freshdesk/perform.rb:15:in `process'
lib/sequencer/unit/import/common/model/mixin/skip/action.rb:49:in `process'
lib/sequencer/unit/base.rb:249:in `process'
lib/sequencer.rb:76:in `block (4 levels) in process'
lib/mixin/start_finish_logger.rb:9:in `log_start_finish'
lib/sequencer.rb:75:in `block (3 levels) in process'
lib/sequencer/state.rb:152:in `process'
lib/sequencer.rb:73:in `block (2 levels) in process'
lib/sequencer/units.rb:28:in `block in each'
lib/sequencer/units.rb:27:in `each'
lib/sequencer/units.rb:27:in `each'
lib/sequencer.rb:71:in `each_with_index'
lib/sequencer.rb:71:in `block in process'
lib/mixin/start_finish_logger.rb:9:in `log_start_finish'
lib/sequencer.rb:69:in `process'
lib/sequencer.rb:24:in `process'
lib/sequencer/unit/import/freshdesk/sub_sequence/generic.rb:19:in `block in process'
lib/sequencer/unit/import/freshdesk/sub_sequence/generic.rb:17:in `loop'
lib/sequencer/unit/import/freshdesk/sub_sequence/generic.rb:17:in `each_with_index'
lib/sequencer/unit/import/freshdesk/sub_sequence/generic.rb:17:in `process'
lib/sequencer/unit/base.rb:249:in `process'
lib/sequencer.rb:76:in `block (4 levels) in process'
lib/mixin/start_finish_logger.rb:9:in `log_start_finish'
lib/sequencer.rb:75:in `block (3 levels) in process'
lib/sequencer/state.rb:152:in `process'
lib/sequencer.rb:73:in `block (2 levels) in process'
lib/sequencer/units.rb:28:in `block in each'
lib/sequencer/units.rb:27:in `each'
lib/sequencer/units.rb:27:in `each'
lib/sequencer.rb:71:in `each_with_index'
lib/sequencer.rb:71:in `block in process'
lib/mixin/start_finish_logger.rb:9:in `log_start_finish'
lib/sequencer.rb:69:in `process'
lib/sequencer.rb:24:in `process'
lib/import/mixin/sequence.rb:17:in `process'
lib/import/freshdesk.rb:8:in `start'
app/models/import_job.rb:24:in `start'
app/models/import_job.rb:105:in `start'
app/models/import_job.rb:95:in `start_registered'
(eval):1:in `_start_job'
app/models/scheduler.rb:291:in `eval'
app/models/scheduler.rb:291:in `_start_job'
app/models/scheduler.rb:262:in `block in start_job'
I, [2022-04-08T18:13:01.186359 #22474-191100] INFO -- : ended ImportJob.start_registered took: 4.426772218 seconds.
E, [2022-04-08T18:13:01.592937 #22474-187000] ERROR -- : ImportJob 'Import::Freshdesk' failed: undefined method `[]' for nil:NilClass
Infos:
Expected behavior:
If the migration source does not have any Organisations ("Company" for freshdesk) configured, Zammad will quietly skip the synchronization and finish successfully.
Actual behavior:
If you do not have any Companies configured within Freshdesk, Zammad will die during Contact import as it tries to reference non existing organizations.
A dirty workaround is to remove the following line, the migration then continues.
https://github.com/zammad/zammad/blob/develop/lib/sequencer/unit/import/freshdesk/contact/mapping.rb#L18
Steps to reproduce the behavior:
Yes I'm sure this is a bug and no feature request or a general question.
The text was updated successfully, but these errors were encountered: