-
Notifications
You must be signed in to change notification settings - Fork 235
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pyktx (Python bindings for libktx) #698
Conversation
- Create Python project - Setup CFFI for C bindings - Write glue code in C for some property getters and calling native functions - KtxTexture, KtxTexture1, KtxTexture2 Python classes calling into glue code and directly into library - Other data classes & enums from libktx in Python code
Pass in C_INCLUDE_PATH, LDFLAGS when building
Hi Mark, sorry for the delay. I was flying back home yesterday for the holidays. I also turned 21 today! Here's what you have to put in the workflow:
For more details: https://github.blog/changelog/2021-11-10-github-actions-input-types-for-manual-workflows/ |
Hi @ShukantPal, I Hope you have a great holiday season and I belated wish you Happy Birthday. Thanks for the example workflow. I have some related questions:
Khronos is working on setting up an organization account on pypi.org. Currently we are awaiting a response from pypi.org. And I have more questions:
|
I figured out the tar file name and now have one source tar deployed into the draft release. I have just now realized that the version number used in the pyktx files is missing the modifier, |
@ShukantPal, This is now on the critical path to getting the beta release out so please answer my questions quickly. I just tried to build the package target but still no dist directory. |
I was looking in the source directory not the build directory for the |
I now see where the version is being set. I need your advice. My concern is if I upload the beta packages labelled as 4.3.0 to PyPI then when I later overwrite them with true 4.3.0 release packages how would pip users be able to upgrade to the new packages. Won't pip and PyPI consider them the same? Therefore I think we need to include the tweak, |
You can use expression syntax for this:
You need to run the publish workflow again, but this time without toggling the test input to true.
Make sure you are running CMake with
I am not sure, but I would suggest using a glob -
Please read about PyPI versioning schemes You can append |
Thanks for your answers.
This did not answer my question. Where would I do this check of
How do I remove the packages from test once published to the real registry? I'll read about the version schemes. |
I changed the byproducts and LIBKTX_VERSION setting in the custom commands to use LIBKTX_VERSION_FULL. The build now produces files with version |
Since the actual byproducts use the normalized name as mentioned, I expect they will be built every time a build is run as the CMake custom command will be looking for the unnormalized name. Is there a way to access the normalization function in the Python build system to use it to normalize the byproduct names given to CMake? |
You may want to do the normalization within CMake using string operations like https://cmake.org/cmake/help/latest/command/string.html#replace Then, pass that into the Python build directly and use it to find the output. |
You can use the following snippet:
here
|
@ShukantPal you have a |
@MarkCallow I have deleted my published pyktx project on Test PyPI. You should be able to publish it with your account now. |
@ShukantPal, I'm still waiting for various permissions and account set up for publishing to PyPI. I've gone ahead and made v4.3.0-beta1 release without it. Will fix later. The pyktx assets are deployed in Releases for download. The pyktx docs are deployed at https://github.khronos.org/KTX-Software/pyktx/index.html. But there is a problem. Anything in the various directories named with I've created issue #825 to track this. |
I'm trying to get publishing working. I made changes to the action file to ready it for using trusted publishing and renamed it
What is wrong? Look at .github/workflows/publish-pyktx.yml The error message has not changed since my first attempt where I used I will not be able to work on this for nearly a month. I am very disappointed that I could not get this working before going on my break. There is no rush but please investigate while this message is still in your mind. |
I figured it out. I was not selecting the correct branch when I was dispatching the action. Stupid. How it gets all the way to attempting to deploy but I get
Please figure out why the .whl file is not apparently a zip file. See here for the build log with the python traceback. |
pypa/gh-action-pypi-publish#148 I posted a question in the issue thread. |
I resolved the 'not a zip file' issue. The curl command for downloading the assets did not enable redirects so the downloaded files all had zero bytes. I now have the following issues which appear to be with the packages we are creating. Please fix.
|
@ShukantPal please submit your fixes as a PR against the I have created scripts to retrieve the release metadata and download assets I think that functionality may be more generally useful. The drawback is that publish_pyktx now has to check out the repo. The scripts and updated .yml are now in the branch. I deleted most of the older logs. Look at this current log to see the errors shown in my previous comment. |
@ShukantPal this is now on the critical path to releasing 4.3.0. Please provide fixes for the descriptions as soon as possible. |
…iption in pyktx setup.py (#844) @MarkCallow #698 (comment)
…iption in pyktx setup.py (#844) @MarkCallow #698 (comment)
…iption in pyktx setup.py (#844) @MarkCallow #698 (comment)
Add Python bindings, documentation and tests. Add to CI. Adds a manual Publish step for publishing to PyPl. See KhronosGroup#663 for details. Fixes KhronosGroup#663. Co-authored-by: Mark Callow <[email protected]>
Add Python bindings, documentation and tests. Add to CI. Adds a manual Publish step for publishing to PyPl. See KhronosGroup#663 for details. Fixes KhronosGroup#663. Co-authored-by: Mark Callow <[email protected]>
Add Python bindings, documentation and tests. Add to CI. Adds a manual Publish step for publishing to PyPl. See KhronosGroup#663 for details. Fixes KhronosGroup#663. Co-authored-by: Mark Callow <[email protected]>
Add Python bindings, documentation and tests. Add to CI. Adds a manual Publish step for publishing to PyPl. See KhronosGroup#663 for details. Fixes KhronosGroup#663. Co-authored-by: Mark Callow <[email protected]>
Add Python bindings, documentation and tests. Add to CI. Adds a manual Publish step for publishing to PyPl. See KhronosGroup#663 for details. Fixes KhronosGroup#663. Co-authored-by: Mark Callow <[email protected]>
Sorry re-opening #665 after I force pushed & accidentally deleted that PR. The history hasn't been changed