Skip to content

Conversation

@timrid
Copy link

@timrid timrid commented Mar 17, 2025

As described here, the app_packages should be added via site.addsitedir() so that .pth files are executed correctly.

I tested it using a manually created .pth file that executed a .py file with a print. The output of the print was visible in the console with briefcase run windows app.

I also added pywin32 as a dependency in my application and tested it with the following code:

import win32ui
win32ui.MessageBox("I am working now", "Hello pywin32")

Should fix beeware/briefcase#2195, beeware/briefcase#835, beeware/briefcase#669 and beeware/briefcase#381 for "windows app".

PR Checklist:

  • All new features have been tested
  • All new features have been documented
  • I have read the CONTRIBUTING.md file
  • I will abide by the code of conduct

@freakboy3742
Copy link
Member

Thanks for the contribution. Unfortunately, while this does work, it's not the best approach for a fix, so I'm going to close this PR. See beeware/briefcase-windows-VisualStudio-template#52 for more discussion of the reasons why.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Use site-packages folder instead of app and app_packages

2 participants