1.10.3: DirectOptionMenu Broken

DirectOptionMenus are broken in 1.10.3, In both the SDK and distributable versions, it seems.

I’ve opened an issue for this matter here.

This has me a little anxious, as it’s somewhat blocking me: I want to release a small test-program for my key-mapper module (different to the previous one), and furthermore am hoping to move towards releasing a demo of my main project soon.

I could probably work with 1.10.2, of course. But then I miss out on the various fixes of 1.10.3–including some gamepad fixes that I’m hoping might work with my own gamepad.

If that’s what’s called for, then fair enough.

However, as noted in the issue linked-to above, there does seem to be a fix for this issue, added via a recently-closed pull-request. Would it then be feasible for a big-fix version of 1.10.3 to be made, incorporating that fix?

Further if a new version is built, may I request that the following pull-requests be reviewed for it? They implement some changes to DirectOptionMenu that would be useful to me.

(If only one of the above were to be included, I think that I’d want it to be the first: without it, DirectOptionMenus can become inconsistent with the style of the rest of the UI as soon as their item-lists are changed.)

If such additions are infeasible for a bug-fix build, then that’s fair enough! They’d be useful to me, and it seems worth asking, but the lack of them doesn’t break functionality, as far as I’m aware.

If you are fine with “living on the edge” you can use development builds of Panda – which should have the fix – with the following requirements.txt file:

--dev --extra-index-url https://archive.panda3d.org/branches/master

That should be fine for the key-mapper test that I want to run soon, I do think. Thank you! :slight_smile:

However, for the demo of my main project I’d rather not use an unoptimised build…

As to the SDK, is there a way to install a similar dev-version via pip, and will that complicate matters when I want to switch back to the standard version once the fix makes it into that stream?

That requirements.txt should be enough to install a dev SDK via pip. You may need to uninstall your current Panda3D wheel so pip will use the development version:

pip uninstall panda3d
pip install -r requirements.txt

You can also update with:

pip install --dev --extra-index-url https://archive.panda3d.org/branches/master -U panda3d

Ah, I see–thank you!

However, I just attempted a build (using the command-line command “python3 setup.py bdist_apps”) and it failed, giving the following error:
__main__.py: error: no such option: --dev

My requirements.txt file currently contains only what you gave above; should I have applied those lines some other way?

Attempting to install the SDK via pip, using the “update” command-line that you gave above, produces the same response: “no such option: --dev”.

(In case it’s relevant, I’m using pip3, specifically.)

[edit 2]
I should perhaps mention that I’m running this under Ubuntu 18.04.2.

[edit 3]
Having done a little searching, I’ve only seen “–dev” mentioned with relation to “pipenv”, a tool that I’m unfamiliar with. Should I be using that? If so, is there anything that I should know about it? (E.g. licensing issues, or, well, anything that might be problematic.)

That said, I’ve found only a few references, so the correlation may well be coincidental.

Sorry, the flag should have been --pre and not --dev to get a pre-release build.

Ah, I see!

I can confirm that updating the SDK with “–pre” does seem to complete successfully, and that DirectOptionMenu seems to work in the pre-release build! Thank you for that. :slight_smile:

Sorry for the trouble–I’m not all that familiar with pip. ^^;

Using the “requirements.txt” that you gave above (with “–pre” replacing ("–dev") in order to build a distributable seems to still fail, however.

This appears to be the relevant error message:

requests.exceptions.HTTPError: 404 Client Error: Not Found for url: https://archive.panda3d.org/thirdparty/panda3d/

Given that a recent “deploy-ng” commit added a link to the thirdparty folder, I’m guessing that this is a bug, and will likely file an issue for it over on GitHub!

I’ve just created this page, but I’m not sure why this is being added.

I’d guess that it’s related to a recent-ish commit that added the URL to “pypi_extra_indexes”–but I don’t know enough about this to guess as to why that might have this effect. :/

By the way, I can confirm that commenting out the “thirdparty” URL on line 243 of “commands.py” seems to allow a simple app, at least, to build successfully. Presumably this is a potential issue for apps using third-party packages stored at that URL, but it at least enables some builds in the meanwhile.

Are you saying that my fix (to add the URL to the server) didn’t work? What’s the new error message?

Ah, I think that I misunderstood your previous post–I didn’t realise that it was a fix. Sorry about that!

It looks like your fix does indeed work, I’m glad to say! :slight_smile: