One codebase, two different deployment results?

hey there,

i had a chance to speak with another support engineer about this, and he confirmed my initial hunch that while indeed the repo may be the same one, there is likely some setting in the UI (and the toml file that those settings generate) that is different from site to site. This would mean that the sites are identical in content, but not necessarily the same in how they are displayed, as these settings are not saved or coming from the git repo.

here is one thing we found that could be the culprit:

> Site.find_by_subdomain("choruslondon").repo.node_version
"16"
> Site.find_by_subdomain("chorus-app").repo.node_version
"12.18.0"

(hats some output from our internal console)

it could be something else, but i would try making both node versions the same. If it works better on the older version, than thats the one you should enforce for the short term,. that said, version 12 is pretty old and you’ll want to get things working on a newer version for security and performance reasons for sure.

info on that here:

more general info here:

your secondary issue with having two sites is something we can address after we get them both working the same. we’ll need to get you talking to a support engineer and do some verifications and lever pulling - as you mentioned, we don’t just delete sites for obvious reasons, but we can see if we can help you out.

let me know if this fix, setting the node versions, works.

Hi Perry

I’d thought the Node version number could have been an issue previously, however the toml file was setting the Node version to 14 so I’m surprised to see this discrepancy.

I’ve removed the version number from the toml file and set a NODE_VERSION environment variable in the Netlify dashboard. This seems to have successfully set the version number to 12.18.0 (according to our build logs), but I’m still getting the same issue unfortunately. Could there be something else perhaps?

With regards to the second issue, happy to provide any verification you need from us. Would we potentially be able to provide the verification to have the site transferred over to our Netlify account from Michael’s instead (to save having to debug this further)? No worries if that’s not a possibility.

Thanks

Hi, @ChorusAgency. I noticed the two sites are using different version of our build image (one is using xenial and the other focal). You might try changing those to match as well.

You might also just try making a new site with the repo on your existing team to see if you can reproduce the error that way. That way you will have a working and non-working version on the same team without needing to transfer.

I say this because the node dependencies install tools (both npm and yarn) are famously non-deterministic in their behavior. Just because two developers are using the same package.json file in no way means both developers’ dependencies are perfectly matched. In other words, simply creating a new site linked to the repo may help you to reproduce the error as it may only show up with a fresh npm install. (The repo is private, though, so this is just a guess.)

If you do decide to move the two sites to the same team to troubleshoot, please ask the owner of the team where the site to be moved is currently to request the transfer with our support team. To do so, please have them email support@netlify.com from their team owner email address (as found at https://app.netlify.com/account/members/) and let us know the following:

  • the site subdomain (or site API ID) for any sites to be transfer (like choruslondon.netlify.app)
  • if there are DNS zones attached, tell us if we should transfer those as well or not
  • the owner email address for the team where the sites should be transferred to

For example, I might write in from name@netlify.com and say this:

Hello Netlify Support Team,

Would you transfer my site example.netlify.app to the team owned by you@chorusagency.tld (or whatever your email address is)?

We will reply back to ask for confirmation and if they confirm we’ll transfer the site or sites.

Hi Luke

Thanks for getting back to me about this.

I tried updating the build image to xenial and rebuilt the site but that has not worked either.

Just to clarify, our existing (working) website is https://chorus-app.netlify.app.

The reason we have set up a new Netlify account and build the website on a new domain name (https://choruslondon.netlify.app) is because the old website is under our previous freelance developer’s (Michael’s) Netlify account.

Michael has not worked for us for a while now, we’ve tried to contact him many times over the past few weeks to ask him to give us access to the Netlify control panel or transfer ownership over to us but we are not getting a response from him.

Given that we don’t have access to the first website, I think much of the info in the second half of your response is not applicable.

We’d be very happy to have that repo transferred over from Michael’s account, to our own new account. If that was possible, it would negate the need to keep new site and debug this issue we’re having with the project page. But from what I understand you’ll need Michael to contact you to arrange that. I’m afraid we cannot get in touch with Michael to ask him to do that given the circumstances.

Is there any other way around this? We’re happy to provide any proof that would help establish that we are the rightful owners of the site.

Thanks

Hi @luke just wondering if there’s any update on this? Thanks

Hi, @ChorusAgency. We can transfer sites between team but we usually recommend unlinking the repo from the site before transferring to the current site. We then ask the new site owner to link a repo they do control to the site.

In other words, the repo isn’t controlled by Netlify. We can transfer the site to your control but not the repo as we have no way to do this.

As far as proving you own the site, at Netlify that is done by having the email address and password required to login. If you don’t have that you don’t own the site.

If someone has uploaded copyrighted content that you own you can make a DMCA takedown report and we can suspend the site but we don’t transfer it to your control. We can only do transfer with an email from the current site owner.

I’m showing the two sites are now linked to two different repos now and it appears your site is building successfully. Do you still want us to email the current site owner and ask them for permission to transfer the site?

I also see there is a custom domain assigned to this site. We can remove the custom domain from the existing site if a verification DNS record is created:

​Please let us know if you would prefer to do a DNS verification or if we should email the site owner. If there are further questions about this, please let us know.

Hi @luke

I explained in a previous post when discussing this issue with Perry that we own the repo and that the two repos for the two different Netlify sites are the same repo - please see this post for more info which includes a video showing that https://github.com/michaelpumo/Chorus redirects to https://github.com/ChorusAgency/Chorus:
One codebase, two different deployment results? - #7 by ChorusAgency

With that being the case, is it required to unlink the repo before transferring it or can we try transferring while the repo is still linked? I’m cautious of doing anything that may disrupt the working site.

It would be great if you could email the current site owner on our behalf. As I mentioned, we’ve not been able to get in contact with him ourselves on multiple occasions.

If we can’t get in touch with him, we’re going to have to dig deeper into the issue and try and figure out what’s going on, but I must say I’m not an expert with npm. I still can’t understand how two Netlify builds from the exact same GitHub repo can have different results, especially when they’ve both had rebuilds triggered recently so we know they’re both up to date. Any idea where I should even begin to look with this?

Morning @luke, is there any further update on this please?

Thanks

Hi @ChorusAgency :wave:

Thanks for your patience here. I want to assure you we have not forgotten about your case here! A member of the support team will follow up shortly.

Hiya @ChorusAgency and sorry to hear this trouble persists!

What we usually say to folks in your situation is that “you’ve built something differently; you should debug how what you’ve built now is different than what you build before.” I understand that without access to the old site, this will be hard for you, but it’s still our guidance - we can’t really help you debug problems with your source code (we don’t know it well enough to know what could be different). I know that this manifests as “it works differently on Netlify than this other site that should be identical” and indeed, I can see very deployments at the old and new site - for instance, there is a different number of files generated in each deploy (99 vs 98), which generally indicates that something more substantial than a change in your site settings or a change in “how we are serving the site”.

Since we can’t transfer the old site to you, I wonder how we can help you do this. I suppose that the old site is public, so I could export a copy of it for you, and then you could compare with a copy you’ve built, and debug from there, so that’s what I’ll propose for now. If that appeals, let me know and we’ll get you a copy shortly! If not, I don’t really have any more suggestions as to what could be happening.

Hi @fool

I think you’ve misunderstood the situation. I’ve mentioned this 3 or 4 times now in the thread, but to clarify again…

There are two Netlify sites:
Site A - chorus-app.netlify.app. This is the site in Michael Pumo’s Netlify account which is working as expected
Site B - choruslondon.netlify.app. This is the site in Chorus London’s Netlify account which is not working as expected

There are two GitHub repo links we’ve been discussing:
GitHub A - github/michaelpumo/Chorus. This is the repo from which Site A is built.
GitHub B - github/ChorusAgency/Chorus. This is the repo from which Site B is built.

The point I’ve made numerous times in this thread, which doesn’t appear to be acknowledged/believed by you or your colleagues, is that GitHub A is the same repo as GitHub B.

But why are there two different links?

Michael developed the site for us initially. As a result, it was built and pushed to his own GitHub account, github/michaelpumo. Michael also set up the hosting of the site on Netlify while the repo was still under his own GitHub account. This is why when you go into Michael’s dashboard and look at Site A, you see the current repository as this link - github/michaelpumo/Chorus.

After Michael finished with the project, he transferred the GitHub repo from his own account, to our account, github/ChorusAgency. When he did that, the repo moved from github/michaelpumo/Chorus to github/ChorusAgency/Chorus.

Want proof? You guys can’t see this since the repo is private, but I recorded a screencast proving that visiting the url for GitHub A results in a redirect to GitHub B. See the Loom video linked in this post - One codebase, two different deployment results? - #7 by ChorusAgency.

The reason this redirect is happening is because it’s the same repo, just with a new url because it was moved. Even though the url is different, the repo is the same.

You mentioned that one of the sites has 98 vs 99 files. There’s a reason for this…

We have a webhook from our headless CMS (Prismic) set up on Site B. We do not have a webhook for our headless CMS set up on Site A. What this means is, if there is a change to the content in Prismic, Site B is automatically rebuilt with the changed Prismic content incorporated. Site A is not automatically rebuilt.

Could this be the cause of the issue then? No. The issue was still there last time we pushed a change to the GitHub repo, which in turn caused Netlify to rebuild both Site A and Site B. This put the content in a state of exact alignment, but the problem was still there.

As I’m sure you can understand, there’s been 23 days since this topic was first opened, so of course there have been changes in the Prismic repo. I can push a change to the GitHub repo to align the content of Site A and Site B again if you want, just to prove the point to you that this is not the source of the issue?

So given the above points, the assertion that you’re making (which is that they’re different codebases, and this explains the difference in behaviour) is entirely wrong.

Given all of the above, I still don’t see this issue as resolved as you continue to insinuate that the difference between Site A and Site B is caused by differences in the codebase, which it’s patently not. I thought @luke may have been along the right lines when he pointed out that there were differences in the Netlify settings between Site A and Site B (specifically the build image), but aligning the build images didn’t fix the issue.

Again, I cannot understand how two sites being built from an identical codebase can be having different outcomes here, and no one else seems to be able to offer a proper explanation for it.

This issue is now over 3 weeks old, is there any way to escalate it? I don’t think dealing with multiple people is helping as whenever someone new responds they don’t seem to have read and fully understood the context of the issue.

For some reason, the loom link in the previous post appears to have been flagged? Here’s the link - Loom | Free Screen & Video Recording Software | Loom

Could this please be investigated as a matter of urgency? A further 9 days have now passed with no response. It’s over a month since the thread was initially opened now

@ChorusAgency As Netlify have indicated diplomatically a few times, it’s unfortunately not really their place to debug your project, as they’re primarily a “self-service hosting environment”.

As @fool mentioned, it can look like the difference only occurs on Netlify, but it’s significantly more likely that there is a difference in the installation/execution of the codebase, or the configuration, than it is an actual “Netlify problem” that their staff would need to assist you with.

If you’re able to provide access to your repository, even privately, then I can take a look and see if I can spot what’s going on.

Hi @nathanmartin

I still don’t understand how the problem could lie anywhere other than Netlify though. If the exact same codebase is being used, presumably the only difference in the entire stack could be the way Netlify is deploying the site in each instance?

Hey there, @ChorusAgency :wave:

We acknowledge that you are seeing different things between the two sites-- I do not believe that we have misunderstood this. Unfortunately, debugging the specific code between the two sites is beyond the scope of support, which I am linking here: Netlify Scope of Support.

To double check that we believe this is code based, we took a quick look at the repos, and one difference is that you are using different functions directories. While this may not be causing two entirely different views, I do believe it is evidence that there may be more repo based differences that you can look into. Here are links where you can see this:

Site A Functions (default) - Netlify App
Site B (customized, sym) - Netlify App

Additionally, here are a few more resources for your debugging process:
Assuming you forked the original repo, so here’s a doc on how to compare forks: Comparing commits - GitHub Docs

Here is documentation on how to compare commits (you can compare the 1st copy of the original codebase and any changes that have been made): Comparing commits - GitHub Docs

Lastly, here is documentation on how to view differences between commit views (you may not be seeing everything that’s changed depending on your view) - Differences between commit views - GitHub Docs

Again, further debugging of your code is outside the scope of our Support. I know this is not the news you are looking for, and I hope that the above information is enough to get you on the right track.

I don’t think it matters too much.

Surely the most important thing is just that you get the new copy of the site operating how you want?

@hillary

You’re saying “Assuming you forked the repo”. Did you miss/ignore the previous posts where I explained that both sites use the same repo multiple times? If the repos are not the same, how come one repo url redirects to another? Video evidence here - Loom | Free Screen & Video Recording Software | Loom

There are three scenarios where a GitHub repo would be redirected (according to GitHub - source):

  • When you rename a repository.
  • When you rename your user or organization account.
  • When you transfer a repository from one user or organization to another.

Note that none of these answers is “When your repository is forked”. I have provided video evidence that the url is redirecting, which is therefore irrefutable evidence that the repo is not forked and that it’s the same repo, yet you continue to question this.

I believe there is an effort here to try and discredit what I am saying in order to be able to say “further debugging of your code is outside the scope of our Support” and therefore avoid having to dig into the issue deeper and provide actual support.

A direct question that I’d like you to answer please - If the repo is indeed the same, do you accept that the issue lies with how the Netlify platform is deploying the two sites differently?

You said that “one difference is that you are using different functions directories”. A couple of issues with this:

  • I only have access to ‘Site B’, but from what I can see on my end, there is not a custom directory. The ./functions directory is being used
  • There are no serverless functions in this repository, therefore surely any difference in how the functions directory is set up is a reflection on Netlify’s defauly configuration and indicates that the Netlify platform is handling the sites differently and potentially causing this issue?

@nathanmartin

I think it matters a lot.

The same codebase is being used for both sites. One site is working as intended, the other is not. How could it be a code issue that needs debugging when it is working as intended on one of the Netlify builds?

All I’m asking is for Netlify to deploy the site in the exact same way in both instances, but for some reason their platform is deploying differently for the same identical codebase.

@ChrousAgency What matters most is “how it builds”, which is to say that if you can get it to build correctly locally, and confirm the configuration required, then you can easily replicate that to build it correctly remotely.

Netlify don’t manage the site instances for customers, (presumably unless you’re on an enterprise plan), so since you’re likely self-service then it’s up to you (or your developer/s) to know what configuration your codebase requires and to understand why it executes the way that it does.

My offer stands, I’m a developer and long time Netlify user.
I might be able to help, I might not, but either way I wouldn’t charge you.
I’m just interested in finding out what’s ultimately going on and can see you’ve been struggling with this for some time.