function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Antonio Úbeda MonteroAntonio Úbeda Montero 

Empty repository clonning an app (project Heroku connect of trails)

Hi,

In the project "Prepare the App for Local Development" (Heroku connect) i have a message saying me that the repository is empty, after trying to clone the app. Code:

 heroku git:clone -a <APP_NAME> --> Replacing APP_NAME with my app name

After execute command:
You appear to have cloned an empty repository.. But the app actually exist and form is displayed when i navigate to it.

Can anyone help me with this slightly trouble?
 
Michael ShirrellMichael Shirrell
Antonio,

I opened a ticket with Heroku yesterday.  Here (https://help.heroku.com/tickets/355973) are the details of my back-and-forth with them.  It includes how to resolve the issue that you experienced (same that I did).  The short story is that there's an issue at Heroku that is causing the issue.  However, there is a work-around that should be implemented on the Trailhead course until the a solution is found by the Heroku dev team.

Michael
NahuelNahuel
Hi @Michael Shirrell. I am encountering this same issue, but the ticket you linked cannot be accessed. Would you mind letting me know how you worked around this?
Michael ShirrellMichael Shirrell
@Nahuel - I'm going to copy/paste my back-and-forth with the Heroku team below (with the exception of the original ticket that is the same as the info above).  It's in reverse order so you'll have to scroll to the bottom and read the messages from 1 through 9:

Reply 9
Michael Shirrell

Friday 15th April 2016
Hunter,

You're steps worked. I think I was expecting a different result based upon the poorly worded Trailhead project I was following. So, it was most likely just a misunderstanding by a noob (me) as to exactly what the outcome of the particular step in the project is/was specifically calling for.

I do have to give you and John credit for helping me out. I definitely would not have gotten things working if it wasn't for your assistance.

Thanks, again!

Michael

​----------------------------------------------
Reply 8
hunter@heroku.com
Hunter Loftis

Thursday 14th April 2016
Getting warnings on npm install is fine; npm is very verbose about the metadata they would prefer you to have in package.json. Once you've npm installed, it's also important to be sure you start the server with the PGSSLMODE and DATABASE_URL environment variables available.

Hunter

​----------------------------------------------
Reply 7
indymba@hotmail.com
Michael Shirrell

Thursday 14th April 2016
So, I've pulled the code done per your initial instructions (cloned from the original git repository into the newly created local folder/directory for my app users\username\thphoneapp [name of my original app]). I then cd into the directory. I had not done an "npm install" (this is mentioned but they do not explicitly state how/where). However, when I do it now in the command line I get two warnings stating "npm WARN package.json phone-change@0.0.0 No repository field" and "No license field".

I'm sure that this is something I'm doing or not doing.

​----------------------------------------------
Reply 6
hunter@heroku.com
Hunter Loftis

Thursday 14th April 2016
Hi Michael,

What steps are you using to run the app? I just did this locally and didn't run into any issues:

$ git clone https://github.com/jamesward/heroku-connect-phone-change.git
$ cd heroku-connect-phone-change/
$ npm install
$  PGSSLMODE=require DATABASE_URL=postgres://(redacted)@ec2-54-243-126-226.compute-1.amazonaws.com:5432/dckc3929i4p5ai npm start
Could you try to recreate that and let me know what happens? I'm wondering if perhaps the sample isn't fully Windows compatible.

Best,
Hunter
----------------------------------------------
Reply 5
johnb@heroku.com
John Beynon

Thursday 14th April 2016
So adding addons doesn't make changes to the app code - all they can do is add config variables that your app can reference from within code that has been deployed. So if nothing references the code then nothing will change.

In that instance you should definitely be able to follow my gist to get the 'button code' locally and be able to run it. The error you're getting there appears to be running the app locally - let me loop in our Node team who might be able to odder a suggestion here,

Regards,
John.
​-----------------------------------------------
Reply 4
indymba@hotmail.com
Michael Shirrell

Thursday 14th April 2016
Hopefully the debug log attached. I assumed that since I added some add-ons to the app in Heroku that these would not work with the initial code base that I pulled in. After I pulled the code down I attempted to test it locally following the instructions here: https://developer.salesforce.com/trailhead/project/quickstart-heroku-connect/qs-heroku-connect-4

However, when I get to this step I get the error in the log attached:
You can now test the change locally by using the app, changing a contact's phone number, and verifying in Salesforce that the three specified phone numbers were updated. After you've verified the change locally, you can redeploy the changes.

So, at this point I'm not sure where the issue resides.

npm-debug.log
​----------------------------------------------
Reply 3
johnb@heroku.com
John Beynon

Thursday 14th April 2016
Hey Michael,

I've spoken with the team and it's a recent thing (21st March) that's broken causing button deploys to not update the apps git repo. This app was created on 14th April so it's affected by this. I don't see that any updates have been made to this app. If changes have been made to the app then there must be a git repo so you'd be able to clone it - is there another app in question here?

Regards,
John.
​----------------------------------------------
Reply 2
indymba@hotmail.com
Michael Shirrell

Thursday 14th April 2016
John,

Thanks for the information! Everything worked to pull the code down. However, the downside to this is that pulling in the initial code with the app doesn't pull in any changes that were made in Heroku. This is causing some ripple effects down stream when I attempt to test the app locally. So, I'll probably just set this trailhead aside until some point in the future.

Thanks, again!

Michael
​----------------------------------------------
Reply 1
johnb@heroku.com
John Beynon

Thursday 14th April 2016
Hi Michael,

It's known. When you 'button deploy' the apps git repository isn't updated - so whilst a 'slug' exists with the code in, there's no actual git repo so when you clone it, you get the message about it being empty.

I did write a gist (https://gist.github.com/johnbeynon/f1f4f7aedb9361114cf8ad567a59f9fc) a few days ago in regards to Heroku Connect trailhead course which has you deploy via the button and then clone the app. This has been raised internally and we are working to get it resolved or the trail updated with steps.

Regards,
John.
NahuelNahuel
Thank you Michael :) !