hildogjr / KiCost

Build cost spreadsheet for a KiCad project.
MIT License
494 stars 97 forks source link

Status of pypi.org #506

Closed romain145 closed 2 years ago

romain145 commented 2 years ago

https://pypi.org/project/kicost/

The latest release is 1.1.4 (2020-03-24). Images don't show, and the documentation link are broken: https://xesscorp.github.io/KiCost The links on readthedocs are even older: https://kicost.readthedocs.io/en/latest/

set-soft commented 2 years ago

Hi @romain145 !

Thanks for reporting. Lamentably PyPi can't be modified, you must add a new release.

The next release fixes the images: https://test.pypi.org/project/kicost/

The documentation issue is new, I think this got broken when @devbisme transferred the project to @hildogjr

We should ask Hildo where are the docs uploaded.

hildogjr commented 2 years ago

I fix some links, I will let this opened until complete check.

Still need to add the doc generation (or at least check) to .github/workflows.

hildogjr commented 2 years ago

@set-soft, I had try to release v1.1.6, marking as new tag on Git. I got the follow error on job https://github.com/hildogjr/KiCost/runs/3871380632

 /usr/bin/docker run --name antonyurchenkogitreleaselatest_37955c --label e1cc51 --workdir /github/workspace --rm -e GITHUB_TOKEN -e DRAFT_RELEASE -e PRE_RELEASE -e CHANGELOG_FILE -e ALLOW_TAG_PREFIX -e INPUT_ARGS -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RETENTION_DAYS -e GITHUB_RUN_ATTEMPT -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e GITHUB_ACTION_REPOSITORY -e GITHUB_ACTION_REF -e GITHUB_PATH -e GITHUB_ENV -e RUNNER_OS -e RUNNER_NAME -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/KiCost/KiCost":"/github/workspace" antonyurchenko/git-release:latest package/kicost_1.1.5-5_all.deb python3-validators_0.14.2-2_all.deb
package/python3-validators_0.14.2-2_all.deb
DEBUG git-release v4.1.1                           
FATAL 'ALLOW_TAG_PREFIX' was deprecated.
- in case your tag has a 'v' prefix, you can safely remove 'ALLOW_TAG_PREFIX' env.var
- if you have another prefix, provide a regex expression through 'TAG_PREFIX_REGEX' instead 
set-soft commented 2 years ago

@hildogjr I removed ALLOW_TAG_PREFIX try again. We are using v as prefix so we should be ok with:

- in case your tag has a 'v' prefix, you can safely remove 'ALLOW_TAG_PREFIX' env.var
hildogjr commented 2 years ago

Now I got the bellow errors. Do you think it is related with the kicost/__version__.py that have to be changed on release process? I will need to get used to GitHub actions language (I am more used to Gitlab CI/CD).

From deploy action:

HTTPError: 400 Client Error: File already exists. See https://pypi.org/help/#file-name-reuse for more information. for url: https://upload.pypi.org/legacy/
Error: Process completed with exit code 1.

From release:

 /usr/bin/docker run --name antonyurchenkogitreleaselatest_1ba6ef --label e1cc51 --workdir /github/workspace --rm -e GITHUB_TOKEN -e DRAFT_RELEASE -e PRE_RELEASE -e CHANGELOG_FILE -e INPUT_ARGS -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RETENTION_DAYS -e GITHUB_RUN_ATTEMPT -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e GITHUB_ACTION_REPOSITORY -e GITHUB_ACTION_REF -e GITHUB_PATH -e GITHUB_ENV -e RUNNER_OS -e RUNNER_NAME -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/KiCost/KiCost":"/github/workspace" antonyurchenko/git-release:latest package/kicost_1.1.5-5_all.deb python3-validators_0.14.2-2_all.deb
package/python3-validators_0.14.2-2_all.deb
DEBUG git-release v4.1.1                           
FATAL error reading changelog: changelog file does not contain version 1.1.7 
set-soft commented 2 years ago

Yes, version must be 1.1.6 in kicost/version.py or the setup.py will try to release a file with 1.1.5 (which already exists).

I defined KICOST_RELEASE so the setup.py marks the build as a release.

hildogjr commented 2 years ago

I made some cleanup od the old tags and re-create v1.1.6, updating version.py. Now I got:

Run docker://antonyurchenko/git-release:latest
/usr/bin/docker run --name antonyurchenkogitreleaselatest_861b50 --label e1cc51 --workdir /github/workspace --rm -e GITHUB_TOKEN -e DRAFT_RELEASE -e PRE_RELEASE -e CHANGELOG_FILE -e INPUT_ARGS -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RETENTION_DAYS -e GITHUB_RUN_ATTEMPT -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e GITHUB_ACTION_REPOSITORY -e GITHUB_ACTION_REF -e GITHUB_PATH -e GITHUB_ENV -e RUNNER_OS -e RUNNER_NAME -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/KiCost/KiCost":"/github/workspace" antonyurchenko/git-release:latest package/kicost_1.1.5-5_all.deb python3-validators_0.14.2-2_all.deb
package/python3-validators_0.14.2-2_all.deb
DEBUG git-release v4.1.1                           
FATAL error reading changelog: changelog file does not contain version 1.1.6 
set-soft commented 2 years ago

The file kicost/HISTORY.rst must be coherent with the release.

I changed it to mention 1.1.6.

If you take a look at https://pypi.org/project/kicost/ you'll see it says 1.1.5 (2021-05-??) and this is why you got an error. Preventing the 1.1.6 release at GitHub.

I moved the v1.1.6 tag and this produced a new release. I changed it from draft to final. So now GitHub and PyPi has 1.1.6 as last release.

You'll see that the upload to PyPi workflow failed, this is because we already have v1.1.6 and releases can't be modified at PyPi. Is not a big deal, just a HISTORY.rst error.

hildogjr commented 2 years ago

Tranks.

Since the links was fix, closing this.