In Allura/allura/tasks/repo_tasks.py there are 3 emails sent for success/failure during clone(). The emails show the wrong destination project & mount point. They show the original project & mount point instead of the destination.
If init_as_clone or some other logic is changing the current c.app and c.project and not resetting it, it would be good to use the h.push_context context manager, so it is reset at the end. Another good option is to explicitly pass app & project as parameters, and not use the global c versions.
created #122: [#4556] Repo success/failure emails reference wrong project & mount point (1cp)
Related
Tickets:
#4556I found out that
clone()uses destination mount point (as needed) but source project.It happens because
clone()get called usingh.push_configcontext manager which explicitly sets upc.projectto source project.Calling
clone()withouth.push_configworks for me (c.projectpoints to destination project). I made the following changes:Is it suitable fix or I missed something?
If this is enough I'll push changes to the repo.
If that fixes the problem, it looks good to me. You can test the behavior by forking a repo and choosing to put it into a different project.
closed #122, the fix is in 42cc_4556 branch
milestone: forge-backlog --> forge-jul-27
labels: --> 42cc