{"action":"created","issue":{"url":"https://api.github.com/repos/cms-sw/cmssw/issues/13194","repository_url":"https://api.github.com/repos/cms-sw/cmssw","labels_url":"https://api.github.com/repos/cms-sw/cmssw/issues/13194/labels{/name}","comments_url":"https://api.github.com/repos/cms-sw/cmssw/issues/13194/comments","events_url":"https://api.github.com/repos/cms-sw/cmssw/issues/13194/events","html_url":"https://github.com/cms-sw/cmssw/issues/13194","id":131387592,"number":13194,"title":"Discuss adding a clear method to Sequence","user":{"login":"Dr15Jones","id":3757616,"avatar_url":"https://avatars.githubusercontent.com/u/3757616?v=3","gravatar_id":"","url":"https://api.github.com/users/Dr15Jones","html_url":"https://github.com/Dr15Jones","followers_url":"https://api.github.com/users/Dr15Jones/followers","following_url":"https://api.github.com/users/Dr15Jones/following{/other_user}","gists_url":"https://api.github.com/users/Dr15Jones/gists{/gist_id}","starred_url":"https://api.github.com/users/Dr15Jones/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Dr15Jones/subscriptions","organizations_url":"https://api.github.com/users/Dr15Jones/orgs","repos_url":"https://api.github.com/users/Dr15Jones/repos","events_url":"https://api.github.com/users/Dr15Jones/events{/privacy}","received_events_url":"https://api.github.com/users/Dr15Jones/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/cms-sw/cmssw/labels/core-pending","name":"core-pending","color":"fbca04"},{"url":"https://api.github.com/repos/cms-sw/cmssw/labels/pending-signatures","name":"pending-signatures","color":"eb6420"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2016-02-04T15:45:39Z","updated_at":"2016-02-04T20:18:11Z","closed_at":null,"body":"A request has been made to add a `clear()` method to the python Sequence class."},"comment":{"url":"https://api.github.com/repos/cms-sw/cmssw/issues/comments/180031104","html_url":"https://github.com/cms-sw/cmssw/issues/13194#issuecomment-180031104","issue_url":"https://api.github.com/repos/cms-sw/cmssw/issues/13194","id":180031104,"user":{"login":"makortel","id":33993,"avatar_url":"https://avatars.githubusercontent.com/u/33993?v=3","gravatar_id":"","url":"https://api.github.com/users/makortel","html_url":"https://github.com/makortel","followers_url":"https://api.github.com/users/makortel/followers","following_url":"https://api.github.com/users/makortel/following{/other_user}","gists_url":"https://api.github.com/users/makortel/gists{/gist_id}","starred_url":"https://api.github.com/users/makortel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/makortel/subscriptions","organizations_url":"https://api.github.com/users/makortel/orgs","repos_url":"https://api.github.com/users/makortel/repos","events_url":"https://api.github.com/users/makortel/events{/privacy}","received_events_url":"https://api.github.com/users/makortel/received_events","type":"User","site_admin":false},"created_at":"2016-02-04T20:18:10Z","updated_at":"2016-02-04T20:18:10Z","body":"I understood your suggestion such that instead of wrapping `preDuplicateMergingGeneralTracks` to a sequence and modifying the sequence, I should do\r\n```\r\n# in preDuplicateMergingGeneralTracks_cfi.py\r\ndef _modifyForPhase1(process):\r\n    from RecoTracker.FinalTrackSelectors.Phase1PU70_preDuplicateMergingGeneralTracks_cfi import preDuplicateMergingGeneralTracks as _phase1PU70Version\r\n    process.preDuplicateMergingGeneralTracks = _phase1PU70Version\r\n... = eras.phase1Pixel.makeProcessModifier(_modifyForPhase1)\r\n\r\n# in iterativeTk_cff.py\r\niterTracking = cms.Sequence(... + preDuplicateMergingGeneralTracks + ...)\r\n\r\ndef _modifyForPhase1(process):\r\n    process.iterTracking = cms.Sequence()\r\n    ...\r\n    process.iterTracking += (... + process.preDuplicateMergingGeneralTracks + ...)\r\n```\r\nI tried that, and but the `++` is still there, and also the `process.reconstruction` still contains sequences from the original `iterTracking`. (I also tried to apply the same recipe to `earlyGeneralTracks_cfi`, but no luck).\r\n\r\nCould it be that replacing `process.iterTracking` as a new sequence object makes `process.reconstruction` to expand the old `iterTracking`, and then when I load the Phase1PU70 version of `TobTecStep` the `++` appears (such that it gets triggered only when something imported by `iterativeTk_cff` has ProcessModifiers)? It is exactly `TobTecStep` that is missing in there."}}