Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9132085
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T08:15:05+00:00 2026-06-17T08:15:05+00:00

I’m working on a new Python authentication library for WSGI frameworks and want to

  • 0

I’m working on a new Python authentication library for WSGI frameworks and want to use the python-openid and maybe some other third-party libs too. I see 2 options:

  • Distribute my library with a copy of the third-party library inside (via GIT submodules)
  • Let the user of my library resolve the dependency on the third-party library by himself

The question is:

What is the preferred conventional way of incorporating a third party library in Python open source projects?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T08:15:06+00:00Added an answer on June 17, 2026 at 8:15 am

    The preffered way is to use setuptools/distribute and define a setup.py for your project that downloads third-party libraries via PyPi.

    Here’s an extract from one of my projects. Note the use of setup/install/test/extras-require keyword arguments, which is what you’re looking for

    import distribute_setup
    distribute_setup.use_setuptools()
    
    import os
    from setuptools import setup, find_packages
    
    # Utility function to read the README file.
    # Used for the long_description.  It's nice, because now 1) we have a top level
    # README file and 2) it's easier to type in the README file than to put a raw
    # string in below ...
    
    def read(fname):
        return open(os.path.join(os.path.dirname(__file__), fname)).read()
    
    setup(
        name='buildboticon',
        version='0.3.2',
        author='Marcus Lindblom',
        author_email='macke@yar.nu',
        description=('A buildbot monitoring utility'),
        license='GPL 3.0',
        keywords='buildbot systemtray pyqt',
    
        url='http://bitbucket.org/marcusl/buildboticon',
        download_url='http://packages.python.org/buildboticon',
    
        package_dir={'':'src'},
        packages=find_packages('src', exclude=['*.tests']),
        long_description=read('README'),
    
        entry_points={
            'setuptools.installation': [
                'eggsecutable = bbicon:main',
            ],
            'gui_scripts': [
                'buildboticon = bbicon:main',
            ]
        },
    
        setup_requires=[
            'setuptools_hg',
        ],
    
        tests_require=[
            'unittest2 >= 0.5',
            'mock >= 0.7.0b4',
        ],
    
        install_requires=[
            'pyyaml >= 0.3',
    #        'pyqt >= 4.7'   # PyQt doesn't have anything useful on PyPi :(
        ],
    
        extras_require={
            'speech':  ['pyspeech >= 1.0'],
    #        'phidgets': ['PhidgetsPython >= 2.1.7'],
        },
    

    Full file here: https://bitbucket.org/marcusl/buildboticon/src/5232de5ead73/python/setup.py

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want use html5's new tag to play a wav file (currently only supported
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have just tried to save a simple *.rtf file with some websites and
I want to count how many characters a certain string has in PHP, but
I am confused How to use looping for Json response Array in another Array.
For some reason, after submitting a string like this Jack’s Spindle from a text
I am trying to understand how to use SyndicationItem to display feed which is
I have a French site that I want to parse, but am running into
I'm interested in microtypography issues on the web. I want a tool to fix:
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.