pimutils / pimutils/vdirsyncer
google_calendar discover fails with missing import
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.9k
- Forks
- 185
- Avg merge
- 11h 49m
- Merged PRs (30d)
- 1
Description
Looks like this was probably caused by commit 04b6913, since that's where prepare_verify was removed.
vdirsyncer git ac45cf1, Python 3.7.0, Linux (Arch)
Config file:
[general]
status_path = "~/.local/share/vdirsyncer/status/"
[storage cal_local]
type = "filesystem"
path = "~/docs/calendar"
fileext = ".ics"
[storage cal_google]
type = "google_calendar"
token_file = "~/.local/share/vdirsyncer/token_google"
client_id = "redacted"
client_secret = "redacted"
[pair google]
a = "cal_local"
b = "cal_google"
conflict_resolution = "b wins"
collections = [["Google", "Google", "djpohly@gmail.com"]]
metadata = ["color"]
Output of vdirsyncer -vdebug discover:
error: Unknown error occurred: cannot import name 'prepare_verify' from 'vdirsyncer.http' (/usr/lib/python3.7/site-packages/vdirsyncer/http.py)
error: Use `-vdebug` to see the full traceback.
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/cli/utils.py", line 342, in _worker
debug: func(wq=self)
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/cli/tasks.py", line 82, in discover_collections
debug: rv = collections_for_pair(pair=pair, **kwargs)
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/cli/discover.py", line 65, in collections_for_pair
debug: b_discovered = _DiscoverResult(pair.config_b)
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/cli/discover.py", line 129, in __init__
debug: self._cls, _ = storage_class_from_config(config)
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/cli/utils.py", line 250, in storage_class_from_config
debug: cls = storage_names[storage_name]
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/cli/utils.py", line 48, in __getitem__
debug: mod = importlib.import_module(modname)
debug: File "/usr/lib/python3.7/importlib/__init__.py", line 127, in import_module
debug: return _bootstrap._gcd_import(name[level:], package, level)
debug: File "<frozen importlib._bootstrap>", line 1006, in _gcd_import
debug: File "<frozen importlib._bootstrap>", line 983, in _find_and_load
debug: File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
debug: File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
debug: File "<frozen importlib._bootstrap_external>", line 728, in exec_module
debug: File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/storage/google.py", line 14, in <module>
debug: from . import base, olddav as dav
debug: File "/usr/lib/python3.7/site-packages/vdirsyncer/storage/olddav.py", line 15, in <module>
debug: from ..http import USERAGENT, prepare_auth, \
error: 1 out of 1 tasks failed.
Contributor guide
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 by reproducing vdirsyncer -vdebug discover with the configuration in the issue, then inspect vdirsyncer/http.py and the import in vdirsyncer/storage/olddav.py. Check the change associated with commit 04b6913; done means the Google Calendar discovery path imports successfully and completes without the missing prepare_verify error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100