Miserlou / Miserlou/lambda-packages
Regex not working
Nobody has claimed this yet.
- Dominant language
- Shell
- Stars
- 728
- Forks
- 157
- PR merge metrics
- No merged PRs in 30d
Description
When trying to use the dateparser module w/ AWS Lambda (Python 3.6, Zappa 0.44.3), I'm seeing an error in CloudWatch, after trying to import dateparser (the upper portion of this trace has been omitted):
File "/var/task/dateparser/__init__.py", line 4, in <module>
from .date import DateDataParser
File "/var/task/dateparser/date.py", line 8, in <module>
import regex as re
File "/var/task/regex.py", line 400, in <module>
import _regex_core
File "/var/task/_regex_core.py", line 21, in <module>
import _regex
ModuleNotFoundError: No module named '_regex'
Regex has versions newer than the one currently in lambda-packages (lambda-packages: 2016.8.27, regex (current): 2017.12.12), and appears to only be pre-built for python 2.7. Perhaps the solution is simply upgrading the pre-built regex? Including a pre-built version for python 3.6?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the import chain in dateparser/init.py, date.py, regex.py, and _regex_core.py, then inspect the pre-built regex package used by lambda-packages. Reproduce the Python 3.6 import failure in AWS Lambda and verify that the packaged artifact provides a compatible _regex module; the issue is done when dateparser imports successfully there.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, python
- Domain
- build-system, cloud
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100