473,748 Members | 2,217 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Distributing programs depending on third party modules.

Hi list,

Is there a preferred way to distribute programs that depends on third
party modules like PyQt, Beautifulsoup etc? I have used setuptools and
just having the setup script check for the existence of the required
modules. If they're not found I have it exit with a message that it need
this or that installed.

But this is not very convenient for the end user and I have got a few
complaints about it. Am I missing something in setuptools or is there a
better way to do it (except for bundling the modules in the package
which seem like a rather nasty workaround)?

Thanks
Tina
May 15 '07 #1
11 4015
Tina I a écrit :
Hi list,

Is there a preferred way to distribute programs that depends on third
party modules like PyQt, Beautifulsoup etc? I have used setuptools and
just having the setup script check for the existence of the required
modules. If they're not found I have it exit with a message that it need
this or that installed.

But this is not very convenient for the end user and I have got a few
complaints about it. Am I missing something in setuptools
EasyInstall, perhaps ?
http://peak.telecommunity.com/DevCenter/EasyInstall

HTH
May 15 '07 #2
Tina I wrote:
Hi list,

Is there a preferred way to distribute programs that depends on third
party modules like PyQt, Beautifulsoup etc? I have used setuptools and
just having the setup script check for the existence of the required
modules. If they're not found I have it exit with a message that it need
this or that installed.

But this is not very convenient for the end user and I have got a few
complaints about it. Am I missing something in setuptools or is there a
better way to do it (except for bundling the modules in the package
which seem like a rather nasty workaround)?

Thanks
Tina
What platform are you doing this on? On the Linux platform, "dependency
hell" of this sort is pretty much unavoidable, because there are so many
different packaging systems (apt, rpm, and so on): it's standard to let
the package manager handle these dependencies. And yes, it is
frustrating for end users.

On Windows and the Mac, bundling all the modules isn't a "nasty
workaround"; it's the standard behavior. End users on those platforms
expect complete application packages, including all supporting
libraries, to be provided by the developers. The standard tools for
doing this are py2exe for Windows (http://www.py2exe.org/) and py2app
for Mac (http://svn.pythonmac.org/py2app/py2a...oc/index.html).

There are other methods for distributing "frozen binaries," including
the freeze module that ships with Python itself, cx_freeze, and
PyInstaller: these three may work on Linux/Unix as well as Windows (they
are not supported on the Mac). But the methods above are generally the
ones most widely used.

--
Kevin Walzer
Code by Kevin
http://www.codebykevin.com
May 15 '07 #3
Kevin Walzer a écrit :
Tina I wrote:
>Hi list,

Is there a preferred way to distribute programs that depends on third
party modules like PyQt, Beautifulsoup etc? I have used setuptools and
just having the setup script check for the existence of the required
modules. If they're not found I have it exit with a message that it
need this or that installed.

But this is not very convenient for the end user and I have got a few
complaints about it. Am I missing something in setuptools or is there
a better way to do it (except for bundling the modules in the package
which seem like a rather nasty workaround)?

Thanks
Tina


What platform are you doing this on? On the Linux platform, "dependency
hell" of this sort is pretty much unavoidable,
Yes it is. EasyInstall works just fine.
because there are so many
different packaging systems (apt, rpm, and so on): it's standard to let
the package manager handle these dependencies. And yes, it is
frustrating for end users.
I'm a happy user of Gentoo and Ubuntu. I don't have any frustration
feeling.

May 15 '07 #4
Bruno Desthuilliers wrote:
>What platform are you doing this on? On the Linux platform,
"dependency hell" of this sort is pretty much unavoidable,

Yes it is. EasyInstall works just fine.
You can install a beast like PyQt with easy_install? Meaning, that it
will download and build/install not just the PyQt bits, but also Qt
itself, sip, and all the other foundational components? If easy_install
handles all that, I'm impressed.
--
Kevin Walzer
Code by Kevin
http://www.codebykevin.com
May 15 '07 #5
Kevin Walzer wrote:
>
What platform are you doing this on? On the Linux platform, "dependency
hell" of this sort is pretty much unavoidable, because there are so many
different packaging systems (apt, rpm, and so on): it's standard to let
the package manager handle these dependencies. And yes, it is
frustrating for end users.
I mainly write apps for Linux although some are in theory cross platform
(but I don't have Windows to test on so I don't really care about that
part). Of course catering to every concievable package management system
is impossible so I'm looking for something to make it easy for people to
use the app as it is.
>
There are other methods for distributing "frozen binaries," including
the freeze module that ships with Python itself, cx_freeze, and
PyInstaller: these three may work on Linux/Unix as well as Windows (they
are not supported on the Mac). But the methods above are generally the
ones most widely used.
A binary would be ideal. I'll look into the freeze modules and
Pyinstaller. Even if they don't handle huge things like Qt it would be a
step in the right direction if it handles smaller third part modules.
And maybe the smartest thing to do would be to dump PyQt and just go for
tkinter, however ugly it is :/

Anyways, thanks for the help people
Tina
May 16 '07 #6
Kevin Walzer a écrit :
Bruno Desthuilliers wrote:
>>What platform are you doing this on? On the Linux platform,
"dependency hell" of this sort is pretty much unavoidable,

Yes it is. EasyInstall works just fine.

You can install a beast like PyQt with easy_install? Meaning, that it
will download and build/install not just the PyQt bits, but also Qt
itself, sip, and all the other foundational components?
Are these components packaged in such a way to support easy_install ?-)

No, of course, easy_install doesn't *actually* support this (while
AFAICT, it technically *could* do the job). I was talking about
dependencies between Python packages.

If you want support for such external dependencies, emerge
(Gentoo-Linux) is your friend - and believe me, it's really impressive.

Note that if you go that way, neither Windows nor MacOS X are actually
able to cleanly manage such dependencies (which is why the usual
solution on these platforms - or at least on Windows - is to just bundle
everything in a single big package). FWIW, I sure had much more trouble
with "DLHell" on Windows than on Gentoo or Ubuntu.
If easy_install
handles all that, I'm impressed.
I'm already impressed by the whole setuptools package.

May 16 '07 #7
On May 16, 7:44 am, Tina I <tina...@bestem selv.comwrote:
A binary would be ideal. I'll look into the freeze modules and
Pyinstaller. Even if they don't handle huge things like Qt it would be a
step in the right direction if it handles smaller third part modules.
And maybe the smartest thing to do would be to dump PyQt and just
go for tkinter, however ugly it is :/
It's may be worth reading this message before making such a drastic
decision:

http://www.riverbankcomputing.com/pi...ay/016092.html

David ;-)

May 16 '07 #8
David Boddie wrote:
On May 16, 7:44 am, Tina I <tina...@bestem selv.comwrote:
>A binary would be ideal. I'll look into the freeze modules and
Pyinstaller. Even if they don't handle huge things like Qt it would be a
step in the right direction if it handles smaller third part modules.
And maybe the smartest thing to do would be to dump PyQt and just
go for tkinter, however ugly it is :/

It's may be worth reading this message before making such a drastic
decision:

http://www.riverbankcomputing.com/pi...ay/016092.html

David ;-)
Oh... now I feel stupid... I'm on the PyQt list but somehow missed that
topic.
Thanks!

Tina
May 16 '07 #9
Bruno Desthuilliers wrote:
Kevin Walzer a écrit :

Note that if you go that way, neither Windows nor MacOS X are actually
able to cleanly manage such dependencies (which is why the usual
solution on these platforms - or at least on Windows - is to just bundle
everything in a single big package). FWIW, I sure had much more trouble
with "DLHell" on Windows than on Gentoo or Ubuntu.
I target Mac OS X only with my Python application. py2app wraps up
Python, Tcl/Tk, and the related items into a single application bundle,
which the user can then install via drag-and-drop. The resulting package
is big, but hard drive space is cheap these days.
>
I'm already impressed by the whole setuptools package.
In general, I agree with this statement. It's very simple to do sudo
easy_install mypythonextensi on--even easier than grabbing a tarball
myself and doing python setup.py, because it downloads the bits for you.

--
Kevin Walzer
Code by Kevin
http://www.codebykevin.com
May 16 '07 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
2129
by: NEWS | last post by:
Can I install Python on a networked server and have any user run Python programs without having to go through the 9Mb client install? What are my options for distributing Python programs to my users? Thankyou to anyone who can help. Graham
1
1500
by: David | last post by:
I have a database application running on my development machine and now want to distribute the application to a third party. Would someone mind please explaining how I can modify the Setup Solution to distribute MSDE with the application. And, doe sthe third party need to then manually install MSDE and create the same instance or will the deployment solution install MSDE with the same Instance automatically. Thanks in advance.
6
1827
by: Jason | last post by:
A non-python programming friend of mine has said that any programs made with Python must be distributed with, or an alternative link, to the source of the program. Is this true?
2
2669
by: RickMuller | last post by:
I really appreciate the ease that the distutils make distributing Python modules. However, I have a question about using them to distribute non-Python (i.e. text) data files that support Python modules. Currently when I have data of this type, I parse it into python objects and make a python module from it. In other words, given a data file like % cat grocery_list.txt eggs spam
5
1739
by: MLH | last post by:
I have little or no knowledge as to how a runtime Access database application might be distributed from a website. I am sure that I'm about to find out. I do have one question for you wizards though... My experience has shown that when I have installed applications from the web, my browser generally asks what I want to do with the file... Do I wanna save it? or Do I wanna run it? The browser generally warns about the dangers of executing...
5
1899
by: Hans [DiaGraphIT] | last post by:
Hi! I thought that I've already posted this question(s), but let me try again. I've developed a windows application for use in a medical environment. I now need to distribute this application to a number of computers, how many i don't know. My application uses a third part supplier for handling charts and Crystal Decision for handling the reports.
1
1372
by: jerry chapman | last post by:
I have written a program which I want to run on another PC that doesn't have C# installed. What files do I have to move to that PC for my program to run?
6
1542
by: Funpolice | last post by:
Hello, I have written a program that requires some modules from pyxml to run. It will run fine on my pc but if I try to run it on another pc with python but without the pyxml modules, I will get import errors. What is the best way to run my program on other pc's without having to install dependent modules on them? I have tried cx_freeze, freeze.py and am having issues with those. Is there any other alternatives? I am using python 2.5 and...
9
1509
by: eliben | last post by:
Hello, I'm getting into Python now after years of Perl, and as part of my research I must understand how to do some common tasks I need. I have a bunch of Windows PCs at work to which I want to distribute an application I've developed on my PC. All these PCs have Python 2.5 installed. If my application contains only code I've developed, I simply zip its
0
9522
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9307
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9225
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6790
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6069
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4589
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4860
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2773
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2203
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.