# Conflicts with changes made locally and remotely

**URL:** <https://discourse.psychopy.org/t/conflicts-with-changes-made-locally-and-remotely/19803>\
**Category:** Online experiments\
**Created:** [January 21, 2021, 4:51am UTC](https://discourse.psychopy.org/t/conflicts-with-changes-made-locally-and-remotely/19803 "2021-01-21T04:51:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![2clarkmoore2](https://avatars.discourse-cdn.com/v4/letter/2/7ab992/32.png) [@2clarkmoore2](https://discourse.psychopy.org/u/2clarkmoore2)\
**Post date:** [January 21, 2021, 4:51am UTC](https://discourse.psychopy.org/t/conflicts-with-changes-made-locally-and-remotely/19803/1 "2021-01-21T04:51:11Z")

</div>

Description of the problem:  
I manually edited an experiment in gitlab. I need to change the JS in a few places in order to accomplish some specific things. After editing, I realized there were some things in my experiment that needed to be changed. So in psychopy I went and changed them, and pushed the changes assuming they would overwrite the JS edit I did. It seems that although in Gitlab the files were overwritten as expected, when I go to pilot or run the experiment it will only run the version that had the JS changes. Any ideas as to why this is and what I can do to solve it?  
I have tried changing the status of the experiment and have certainly double checked that the files being pushed have synced.

Thanks in advance for your help,

Clark

---

<div class="post-metadata">

**Author:** ![2clarkmoore2](https://avatars.discourse-cdn.com/v4/letter/2/7ab992/32.png) [@2clarkmoore2](https://discourse.psychopy.org/u/2clarkmoore2)\
**Post date:** [January 21, 2021, 4:53am UTC](https://discourse.psychopy.org/t/conflicts-with-changes-made-locally-and-remotely/19803/2 "2021-01-21T04:53:42Z")

</div>

I could probably fix the issue by starting over and saving the project elsewhere and thus creating a new repository, however I will need to make these JS edits again for when I publish the experiment. If I need to tweak anything down the road, then I wouldn’t want to create a new repo every time.

---

<div class="post-metadata">

**Author:** ![jon](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.psychopy.org/jon/32/22_2.png) [@jon](https://discourse.psychopy.org/u/jon)\
**Post date:** [January 21, 2021, 4:11pm UTC](https://discourse.psychopy.org/t/conflicts-with-changes-made-locally-and-remotely/19803/3 "2021-01-21T16:11:34Z")

</div>

Regarding the first confusion, when you did the sync that pushed the local changes it should have _merged_ the edits rather than _overwrite_ them unless you make an additional edit to the same lines (eg. an incompatible edit to the same component of the experiment). The way this works on a technical level (in git terms) is that it:

1. git commit: creates a “commit” that tracks your local changes
2. git pull: then fetches the changes on the server and attempts to merge those locally
3. git push: then pushes those merged changes to the server

Regarding the issue of why these aren’t reflected in the running experiment, it’s hard to know exactly what happened. If a merge conflict arises somewhere (because of conflicting changes to the same file) then Pavlovia currently sticks with what it has but I’m not clear why a merge conflict would have arisen.

I think you might resolve the issue on Pavlovia side by making the study INACTIVE and then RUNNING again.

---

<div class="post-metadata">

**Author:** ![2clarkmoore2](https://avatars.discourse-cdn.com/v4/letter/2/7ab992/32.png) [@2clarkmoore2](https://discourse.psychopy.org/u/2clarkmoore2)\
**Post date:** [January 21, 2021, 8:10pm UTC](https://discourse.psychopy.org/t/conflicts-with-changes-made-locally-and-remotely/19803/4 "2021-01-21T20:10:13Z")

</div>

Thank you for your reply Jon.

I had tried to make the study inactive and then running yesterday and although that did not solve the issue yesterday, it seems to have fixed itself today.

I will note that my manual git code was overwritten (however that is okay with me). I am going to make the manual edits again and if I have to change anything in psychopy I will see whether the code gets merged like you described or overwritten. When that happens I will post here for you or other psychopy user’s references.

Best  
-Clark

---

<div class="post-metadata">

**Author:** ![2clarkmoore2](https://avatars.discourse-cdn.com/v4/letter/2/7ab992/32.png) [@2clarkmoore2](https://discourse.psychopy.org/u/2clarkmoore2)\
**Post date:** [January 21, 2021, 8:22pm UTC](https://discourse.psychopy.org/t/conflicts-with-changes-made-locally-and-remotely/19803/5 "2021-01-21T20:22:43Z")

</div>

Actually just tested it and it worked okay. Thank you
