mauroc / squiddio_pi

squiddio_pi
3 stars 13 forks source link

Windows version does not deploy to cloudsmith after PR #50 #61

Closed mauroc closed 4 years ago

mauroc commented 4 years ago

things work great after merging @jongough's PR#50, except that the Windows version does not deploy to Cloudsmith : Here's the relevant message in the appveyor log

bash ../ci/appveyor-upload.sh
fatal: ref HEAD is not a symbolic ref
Not on master branch, skipping deployment.

This build/deploy was triggered by a push on the master branch, so not sure what's going on. ...

rgleason commented 4 years ago

The message on the failure is different now,

No output has been received in the last 10m0s, this potentially indicates a stalled build or something wrong with the build itself.

Check the details on how to adjust your build configuration on: https://docs.travis-ci.com/user/common-build-problems/#Build-times-out-because-no-output-was-received
The build has been terminated

Possibly the build was terminated due to more recent builds starting?
Perhaps a setting in circleci that saves on unnecessary labor.

mauroc commented 4 years ago

the issue I reported affects Appveyor -> Cloudsmith Your message appears to relate to Travis. I have noticed the OSX build on Travis stalls at times, and/or can take more than 10 minutes. Not sure about the comment on circleci. My circleci builds all deploy successfully.

rgleason commented 4 years ago

Sorry, missed that. Is it possible that you have not given a necessary security key?

From Cloudsmith API User > Settings > API Keys (number)

From Github mauroc> Settings> Developer Settings> Personal Access Settings> appveyor_auth_token_squiddio (number)

Is there something else needed? I will need to know this too.

leamas commented 4 years ago

This is most likely caused by appveyor for some reason checking out a detached head branch. The culprit is the branch=$(git symbolic-ref --short HEAD line in appveyor-upload.sh, part of the new test for being on master branch or not.

I'll try to take a look later.

leamas commented 4 years ago

Here is an untested patch if anyone cares to test it...

0001-ci-appveyor-upload-Fix-missing-git-HEAD-61.patch.gz

In haste...

rgleason commented 4 years ago

I downloaded it. Now I expand it into my current local dir reset35-rg? Yes I think so. No, I need to read about use of patch. I think I should bring my master branch current to mauro and apply the patch though.

rgleason commented 4 years ago

from (current mauroc) master checked out a new branch leamas-patch-win-deploy Moved the patch into a subdirectory "patch" and expanded the gz

C:\Users\Rick\Documents\GitHub\squiddio_pi>git am patches/0001-ci-appveyor-upload-Fix-missing-git-HEAD-61.patch
Applying: ci: appveyor-upload: Fix missing git HEAD (#61)

It builds locally. Considering the issues to git push -u origin leamas-patch-deploy-win

  1. This might deploy all the way up to circleci.
  2. What will happen when I delete this branch and remove it from my public repository?

I am a bit chicken.

rgleason commented 4 years ago

Ok, I guess that patch worked! Thank you Alec. https://github.com/rgleason/squiddio_pi/runs/266850915 using a new branch https://github.com/rgleason/squiddio_pi/commits/leamas-patch-win-deploy

Now what will happen when I remove/delete the branch locally and in rgleason/squiddio_pi? Something's going to happen in circleci I think.

rgleason commented 4 years ago

Well, actually it did not deploy because it was not on the master branch.

#!/bin/bash -eo pipefail
ci/circleci-upload.sh
Not on master branch, skipping deployment.

https://circleci.com/gh/rgleason/squiddio_pi/17?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-checks-link

but it looks to me like it will work on mauro's master

rgleason commented 4 years ago

I don't want to try this on my master branch because, I would like to keep it identical to mauro's master. Also if I commit something and it gets run by circleci and uploaded to cloudsmith, and then I revert that commit or rewrite history, what happens inthe cloudsmith and circleci services?

leamas commented 4 years ago

I don't want to try this on my master branch because, I would like to keep it identical to mauro's master.

You should make a pull request. See for example https://www.digitalocean.com/community/tutorials/how-to-create-a-pull-request-on-github

what happens in cloudsmith

Nothing, you can't deploy anything since only ·@mauroc has the deployment key

and circleci services?

ci servers don't care about the history. They just build whatever you push.

rgleason commented 4 years ago

You should make a pull request. See for example https://www.digitalocean.com/community/tutorials/how-to-create-a-pull-request-on-github

Nice resource, wish I had that when I got started years ago. (Later: Still learning certainly...)

Nothing, you can't deploy anything since only ·@mauroc has the deployment key

Really? So for all the orphaned, intermittent and occasional Plugin Authors, we are going to rely on them to deploy? We would be stuck back at v5.0 without many plugins if that is the case. I have made this clear before.

I assume you are saying I can't deploy to his Cloudsmith directory, because of the way it's been set up.

ci servers don't care about the history. They just build whatever you push.

Yes, I guess that is true, because Cloudsmith and CircleCI are not keeping track of "Commits" like Github does. This is both an asset and a liability. What it means is I can delete/remove a test branch that has been deployed to my Cloudsmith account through CircleCI and not have any bad things happen, provided nobody else is reliant on it.

rgleason commented 4 years ago

Note: I removed this branch last night, trying to clean up. /github.com/rgleason/squiddio_pi/commits/leamas-patch-win-deploy

leamas commented 4 years ago

oops... Rebased to current master.