imgui_bundle icon indicating copy to clipboard operation
imgui_bundle copied to clipboard

new release 1.5.2

Open dcnieho opened this issue 1 year ago • 29 comments

Hi Pascal,

I see you are preparing a new release. Would it be possible for you to update to the latest imgui release before doing so, since there is new useful API for shortcuts there? Or are you able to make more frequent releases again?

Just for discussion!

As always, thanks a lot for this great tool, i really enjoy using it :)

dcnieho avatar May 29 '24 08:05 dcnieho

Hi Diederick,

Yes, I will emit a new release in the next weeks. I will try to update ImGui in the process.

In the mean time,you can download wheels in the actions on github: https://github.com/pthom/imgui_bundle/actions/workflows/wheels.yml (They are compiled whenever I push new code).

Or are you able to make more frequent releases again?

I am limited by the project size limit on Pypi (10GB max). I did hit the size limit a few months ago (after which I had to remove several older releases). I just took the time to file a project size increase request to Pypi support's team. I hope they will accept it, but it might take a while.

In the meantime, I know that I can only release about 2 or 3 more versions before I hit the limit again. So I have to reduce the frequency

pthom avatar May 29 '24 11:05 pthom

Oof, i once had a request with them (for a name, not size), it took the better part of a year. Hope yours goes faster!

It specifically the 1.90.7 support for shortcuts that would be interesting to try out, so that wouldn't be in your wheels yet. I saw also that there is a breaking change in docking/viewports, by the way, hope that doesn't break your stuff

dcnieho avatar May 29 '24 13:05 dcnieho

See also my new posts in issue #80, in case you don't get notified because its closed (I can't reopen)

dcnieho avatar Jun 06 '24 13:06 dcnieho

Hi Diederick,

I did update ImGui to v1.90.7. It took me about half a day because I had to update also ImGui Test Engine, and also update the generator options due to new functions being overloaded.

Concerning your other question, see https://github.com/pthom/imgui_bundle/commit/905a805e4394f0bb5ece2c082f576ac0b4c4d659 where I tentatively set the deployment target to 10.14.

Please do test this with your user and keep me informed about the result, I cannot test that on my side; and I can only look at the CI results.

pthom avatar Jun 06 '24 17:06 pthom

Thanks for considering dropping the requirement to 10.14. I see the CI fails with the luckily informative message that std::filesystem::path was introduced in 10.15. Mind retrying with 10.15?

Thanks for the trouble!

dcnieho avatar Jun 06 '24 17:06 dcnieho

I change it to 1015. Please try it on your side . You can update your clone and push the CI should run on your side also.

pthom avatar Jun 06 '24 18:06 pthom

Thanks! That built successfully. I have asked my student to try and install the wheel generated by your action.

dcnieho avatar Jun 06 '24 18:06 dcnieho

The cp311 wheel installed successfully on the student's platform, but when they try to run imgui_bundle_demo, it errors:

% imgui_bundle_demo 
Traceback (most recent call last): 
  File "/opt/anaconda3/envs/test/bin/imgui_bundle_demo", line 5, in <module>
    from imgui_bundle.demos_python.demo_imgui_bundle import main 
  File "/opt/anaconda3/envs/test/lib/python3.11/site-packages/imgui_bundle/__init__,py", line 2, in <module>
    from imgui_bundle._imgui_bundle import imgui as imgui # type: ignore
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ImportError: dlopen(/opt/anaconda3/envs/test/lib/python3.11/site-packages/imgui_bundle/_imgui_bundle.cpython-311-darwin.so, 0x0002): symbol not found in flat namespace ' _BrotliDecoderDecompress'

I'm trying with 10.16 on my own fork now, will keep you updated.

dcnieho avatar Jun 09 '24 17:06 dcnieho

This brotli decoder may not be about the deployment target (may..), also doesn't work on 10.16, same error message. I thought maybe the user doesn't have this brotli available. However, both using pip install brotli and brew install brotli Did not resolve the import error. (Both installed the 1.1.0 version, which is also what the build script picked up according to the log)

I am now trying to use the macos-13 instead of macos-latest runner, lets see...

dcnieho avatar Jun 09 '24 19:06 dcnieho

Note (also for myself), brotli is pulled in by freetype in hello_imgui. Pulling it in can be disabled, using FT_DISABLE_BROTLI, which is marked as "Disable support of compressed WOFF2 fonts." But this may well not be brotli specific, just the first thing that fails.

dcnieho avatar Jun 09 '24 19:06 dcnieho

Trying to build on an earlier runner fails:

  + delocate-wheel --require-archs x86_64 -w /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/cibw-run-etc8ssvh/cp311-macosx_x86_64/repaired_wheel -v /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/cibw-run-etc8ssvh/cp311-macosx_x86_64/built_wheel/imgui_bundle-1.5.0-cp311-cp311-macosx_10_15_x86_64.whl
  INFO:delocate.delocating:Copying library /usr/local/Cellar/libpng/1.6.43/lib/libpng16.16.dylib to imgui_bundle/.dylibs/libpng16.16.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/harfbuzz/8.4.0/lib/libharfbuzz.0.dylib to imgui_bundle/.dylibs/libharfbuzz.0.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/brotli/1.1.0/lib/libbrotlidec.1.1.0.dylib to imgui_bundle/.dylibs/libbrotlidec.1.1.0.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/freetype/2.13.2/lib/libfreetype.6.dylib to imgui_bundle/.dylibs/libfreetype.6.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/glib/2.80.2/lib/libglib-2.0.0.dylib to imgui_bundle/.dylibs/libglib-2.0.0.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/gettext/0.22.5/lib/libintl.8.dylib to imgui_bundle/.dylibs/libintl.8.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/graphite2/1.3.14/lib/libgraphite2.3.2.1.dylib to imgui_bundle/.dylibs/libgraphite2.3.2.1.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/pcre2/10.43/lib/libpcre2-8.0.dylib to imgui_bundle/.dylibs/libpcre2-8.0.dylib
  INFO:delocate.delocating:Copying library /usr/local/Cellar/brotli/1.1.0/lib/libbrotlicommon.1.1.0.dylib to imgui_bundle/.dylibs/libbrotlicommon.1.1.0.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libharfbuzz.0.dylib from /usr/local/opt/glib/lib/libglib-2.0.0.dylib to @loader_path/libglib-2.0.0.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/_imgui_bundle.cpython-311-darwin.so from /usr/local/opt/harfbuzz/lib/libharfbuzz.0.dylib to @loader_path/.dylibs/libharfbuzz.0.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libharfbuzz.0.dylib from /usr/local/opt/graphite2/lib/libgraphite2.3.dylib to @loader_path/libgraphite2.3.2.1.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/_imgui_bundle.cpython-311-darwin.so from /usr/local/opt/libpng/lib/libpng16.16.dylib to @loader_path/.dylibs/libpng16.16.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libfreetype.6.dylib from /usr/local/opt/libpng/lib/libpng16.16.dylib to @loader_path/libpng16.16.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/_imgui_bundle.cpython-311-darwin.so from @rpath/libglfw.3.dylib to @loader_path/libglfw.3.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libharfbuzz.0.dylib from /usr/local/opt/gettext/lib/libintl.8.dylib to @loader_path/libintl.8.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libglib-2.0.0.dylib from /usr/local/opt/gettext/lib/libintl.8.dylib to @loader_path/libintl.8.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libbrotlidec.1.1.0.dylib from /usr/local/Cellar/brotli/1.1.0/lib/libbrotlicommon.1.dylib to @loader_path/libbrotlicommon.1.1.0.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libharfbuzz.0.dylib from /usr/local/opt/freetype/lib/libfreetype.6.dylib to @loader_path/libfreetype.6.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/.dylibs/libglib-2.0.0.dylib from /usr/local/opt/pcre2/lib/libpcre2-8.0.dylib to @loader_path/libpcre2-8.0.dylib
  INFO:delocate.delocating:Modifying install name in imgui_bundle/_imgui_bundle.cpython-311-darwin.so from /usr/local/opt/brotli/lib/libbrotlidec.1.dylib to @loader_path/.dylibs/libbrotlidec.1.1.0.dylib
  Fixing: /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/cibw-run-etc8ssvh/cp311-macosx_x86_64/built_wheel/imgui_bundle-1.5.0-cp311-cp311-macosx_10_15_x86_64.whl
  Traceback (most recent call last):
    File "/private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/cibw-run-etc8ssvh/cp311-macosx_x86_64/build/venv/bin/delocate-wheel", line 8, in <module>
      sys.exit(main())
               ^^^^^^
    File "/private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/cibw-run-etc8ssvh/cp311-macosx_x86_64/build/venv/lib/python3.11/site-packages/delocate/cmd/delocate_wheel.py", line 110, in main
      copied = delocate_wheel(
               ^^^^^^^^^^^^^^^
    File "/private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/cibw-run-etc8ssvh/cp311-macosx_x86_64/build/venv/lib/python3.11/site-packages/delocate/delocating.py", line 1004, in delocate_wheel
      out_wheel_fixed = _check_and_update_wheel_name(
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/cibw-run-etc8ssvh/cp311-macosx_x86_64/build/venv/lib/python3.11/site-packages/delocate/delocating.py", line 839, in _check_and_update_wheel_name
      raise DelocationError(
  delocate.libsana.DelocationError: Library dependencies do not satisfy target MacOS version 10.15:
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libpcre2-8.0.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libgraphite2.3.2.1.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libintl.8.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libglib-2.0.0.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libpng16.16.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libbrotlicommon.1.1.0.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libbrotlidec.1.1.0.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libfreetype.6.dylib has a minimum target of 13.0
  /private/var/folders/vy/h7r6h43j203gstfh6fj9_tyh0000gn/T/tmp1s2vh1j3/wheel/imgui_bundle/.dylibs/libharfbuzz.0.dylib has a minimum target of 13.0

So i guess that means were stuck unless one would build all these libraries yourself. The cibuildwheel docs say: Since delocate 0.11.0 there is added verification that the library binary dependencies match the target macOS version. This is to prevent the situation where a wheel platform tag is lower than the actual minimum macOS version required by the library. To resolve this error you need to build the library to the same macOS version as the target wheel (for example using MACOSX_DEPLOYMENT_TARGET environment variable). Alternatively, you could set MACOSX_DEPLOYMENT_TARGET in CIBW_ENVIRONMENT to correctly label the wheel as incompatible with older macOS versions.

This error may happen when you install a library using a package manager like Homebrew, which compiles the library for the macOS version of the build machine. This is not suitable for wheels, as the library will only work on the same macOS version as the build machine. You should compile the library yourself, or use a precompiled binary that matches the target macOS version.

dcnieho avatar Jun 09 '24 19:06 dcnieho

The strange thing perhaps is that the user is on 13.4, but the compatible targets declared by python go no higher than 10.16.

dcnieho avatar Jun 09 '24 19:06 dcnieho

Ok, this seems to be a bug in pip/packaging. See for instance here: https://github.com/spinalcordtoolbox/spinalcordtoolbox/pull/4359, or here: https://github.com/microsoft/onnxruntime/issues/19371#issuecomment-1924720936 So the solutions are to have a new enough pip (and thereby a new enough packaging package, >=22.0), or to set the SYSTEM_VERSION_COMPAT=0 environment flag when trying to install imgui_bundle.

I have asked my user to check.

dcnieho avatar Jun 09 '24 20:06 dcnieho

AFAIK, OS updates are free on Mac. Is there a compelling reason why those students cannot update their version of macOS?

pthom avatar Jun 09 '24 22:06 pthom

I hear from MacOS users that upgrades are likely to bring new problems and compatibility issues as much as new features. So they ten to upgrade once a year, if even that (don't change a working setup). But yeah, users shouldn't need to be forced to update MacOS to be able to install imgui_bundle. If this turns out to be running into a pip/packaging bug, then I guess the solution is a small addition to the docs. Will let you know/send pull request.

dcnieho avatar Jun 10 '24 05:06 dcnieho

Reading pip changelogs, i see that the fixed version of the packaging package still isn't vendored by latest pip, so that did nothing.

But asking the user to run SYSTEM_VERSION_COMPAT=0 pip install --only-binary=:all: imgui_bundle got stuff installed, and it ran! I'll send you a pull request with a doc update, if i find a nice place (and to revert the target version stuff in the build scripts)

Thanks for going down this road with me!

dcnieho avatar Jun 10 '24 07:06 dcnieho

Thanks for going down this road with me!

You're welcome. I just merged you PR. Thanks a lot

pthom avatar Jun 11 '24 11:06 pthom

Most welcome, glad we figured this out!

dcnieho avatar Jun 11 '24 11:06 dcnieho

Hi @pthom: I see you made the 1.5.0 release, nice! However, i wonder about two things:

  1. is it correct that Python 3.10 support has been dropped? I hope it is possible to keep also releasing wheels for 3.10, as thats what i am using and for the applications i develop, i would not want to force my users to update.
  2. it seems the release did not make it to pypi: https://pypi.org/project/imgui-bundle/ only lists 1.3.0, did something go wrong?
  3. small note: the release notes say its imgui v1.90.5, but you wrote above you updated to v1.90.7, which is correct?

Cheers, Dee

dcnieho avatar Jul 07 '24 09:07 dcnieho

Hello Dee,

I'm trying to release this version, and I will have to change it to 1.5.1 (because of a failed previous attempt, pypi wont let me re-release this version)

But I have to fight on several fronts, And I'm fighting since about a good 12 hours:

  • On macOS: wheels won't work with macOS 11.0. they work if I remove freetype => I would have to make a version specific for 14.0. and perhaps also release a version for 11.0 without freetype

  • On windows, the build for OpenCV is broken. I have to investigate.

Is it correct that Python 3.10 support has been dropped:

No, the support for Python 3.10 is still Ok, I do not produce binary wheels for it although, for reason of space in pypi. Python 3.10 is the minimum required version.

Maintaining so many versions by OS / OS version / Architecture / Python version has become very difficult and too much time consuming.

pthom avatar Jul 07 '24 10:07 pthom

So you mean 3.11 is the minimum required version? Ok, then i update. I understand the problem of having so many versions.

Annoying about the macos versioning! I hope you can solve it and can make both builds so it doesn't become too restrictive. In the meantime i have found a 3.10 build of 1.5.1 in one of your latest actions, so will test a bit with that.

dcnieho avatar Jul 07 '24 10:07 dcnieho

Hi Dee,

Thanks for reporting the full screen issue. It is solved. I also just updated imgui to v1.90.9. this will be in the release.

Did you see other issues?

pthom avatar Jul 07 '24 19:07 pthom

Hi Pascal,

No, i didn't see other issues, but am only able to test my relatively simple application from location. If there would be something, I'm sure its super minor, and possibly due to me doing something hacky. But i'll report.

Cool you're staying so up to date :)

Hope you managed to slay the release dragons.

dcnieho avatar Jul 07 '24 19:07 dcnieho

Say, your wheels CI actions still builds for 3.10, the pip one does not. Is that intended? As said, I (and probably more users) would be happy to have a 3.10 package available too).

dcnieho avatar Jul 07 '24 19:07 dcnieho

I reenabled python 3.10 in the pip CI. I had disabled because it was failing on linux GitHub Runners for a while. GitHub sometimes pushes instable update to their runners.

pthom avatar Jul 07 '24 20:07 pthom

Ah, glad this started working again!

dcnieho avatar Jul 07 '24 21:07 dcnieho

v1.5.2 is out!

I will close this issue if you have more remarks about it please open another issue concerning this particular release.

Thanks!

pthom avatar Jul 07 '24 22:07 pthom

After a bit of pondering, I'll leave this issue open for a while.

pthom avatar Jul 08 '24 10:07 pthom

Already using it (on Windows), seems to be working well :)

dcnieho avatar Jul 08 '24 11:07 dcnieho