Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add environment variable support #41

Conversation

cmendesce
Copy link

Closes #40.

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 98.131% when pulling 62e3f2c on cmendesce:env-var-support into cd6ad70 on NaturalHistoryMuseum:master.

@@ -59,10 +60,12 @@ def load_objects(dir):
except OSError:
dependencies, libzbar = load_objects(Path(__file__).parent)
else:
# Assume a shared library on the path
path = find_library('zbar')
path = os.getenv('ZBAR_PATH')

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could be replaced with os.getenv('ZBAR_PATH') or find_library('zbar')

@quicklizard99 quicklizard99 changed the base branch from master to feature/40-path-to-zbar February 25, 2019 21:10
@quicklizard99 quicklizard99 merged commit bb2444a into NaturalHistoryMuseum:feature/40-path-to-zbar Feb 25, 2019
@nickovs
Copy link

nickovs commented Nov 7, 2021

Can we please get the feature merged onto the main line code? As noted in my comment, because of the way that Python's ctypes.utils.find_library() is implemented, setting LD_LIBRARY_PATH does not work on AWS Lambda Python instances and as a result it's impossible to use pyzbar on AWS Lambda without resorting to deploying your Lambda function as an entire Docker container.

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.

5 participants