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

VObject is not thread-safe #675

Closed
Unrud opened this issue Jul 26, 2017 · 4 comments
Closed

VObject is not thread-safe #675

Unrud opened this issue Jul 26, 2017 · 4 comments

Comments

@Unrud
Copy link
Collaborator

Unrud commented Jul 26, 2017

The problem seems to be in dateutil.

Traceback (most recent call last):
  File "radicale/storage.py", line 1357, in _get_with_metadata
    ctext = vobject_item.serialize()
  File "vobject/base.py", line 254, in serialize
    return behavior.serialize(self, buf, lineLength, validate)
  File "vobject/behavior.py", line 155, in serialize
    cls.generateImplicitParameters(obj)
  File "vobject/icalendar.py", line 971, in generateImplicitParameters
    findTzids(obj, tzidsUsed)
  File "vobject/icalendar.py", line 969, in findTzids
    findTzids(child, table)
  File "vobject/icalendar.py", line 969, in findTzids
    findTzids(child, table)
  File "object/icalendar.py", line 964, in findTzids
    tzid = TimezoneComponent.registerTzinfo(tzinfo)
  File "vobject/icalendar.py", line 129, in registerTzinfo
    tzid = obj.pickTzid(tzinfo)
  File "vobject/icalendar.py", line 334, in pickTzid
    if tzinfo is None or (not allowUTC and tzinfo_eq(tzinfo, utc)):
  File "vobject/icalendar.py", line 1996, in tzinfo_eq
    if not dt_test(datetime.datetime(startYear, 1, 1)):
  File "vobject/icalendar.py", line 1994, in dt_test
    return tzinfo1.utcoffset(dt) == tzinfo2.utcoffset(dt)
  File "dateutil/tz/tz.py", line 1109, in utcoffset
    return self._find_comp(dt).tzoffsetto
  File "dateutil/tz/tz.py", line 1062, in _find_comp
    return self._cachecomp[self._cachedate.index((dt, self._fold(dt)))]
IndexError: list index out of range

Edit: dateutil/dateutil#428

@prlw1
Copy link

prlw1 commented Aug 3, 2017

While on VObject, I observe:

Python 3.6.1 (default, Jun 27 2017, 15:00:07) 
[GCC 5.4.0] on netbsd8
Type "help", "copyright", "credits" or "license" for more information.
>>> import vobject
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'vobject'
>>> import vdirsyncer.vobject
>>> exit()

So I need the trivial s/import vobject/import vdirsyncer.vobject/ in __init__.py and radicale_storage.py

@Unrud
Copy link
Collaborator Author

Unrud commented Aug 3, 2017

So I need the trivial s/import vobject/import vdirsyncer.vobject/ in init.py and radicale_storage.py

No, vobject and vdirsyncer.vobject are not the same. You have to install the vobject python module. If you install Radicale with $ python3 -m pip install --upgrade radicale it should install all dependencies.

@Unrud
Copy link
Collaborator Author

Unrud commented Aug 6, 2017

Fixed in dateutil/dateutil@94f1639. This can be closed, when the next version of dateutil gets released.

netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this issue Aug 10, 2017
…ches.

  Kozea/Radicale#675 (comment)

* override folder for storing local collections, from
  /var/lib/radicale/collections to ${PREFIX}/share/radicale/collections

Update Radicale2 to 2.1.4

2.1.4 - Wild Radish
-------------------

This feature is not compatible with the 1.x.x versions. See
http://radicale.org/1to2/ if you want to switch from 1.x.x to
2.x.x.

* Fix incorrect time range matching and calculation for some edge-cases with
  rescheduled recurrences
* Fix owner property

2.1.3 - Wild Radish
-------------------

This feature is not compatible with the 1.x.x versions. See
http://radicale.org/1to2/ if you want to switch from 1.x.x to
2.x.x.

* Enable timeout for SSL handshakes and move them out of the main thread
* Create cache entries during upload of items
* Stop built-in server on Windows when Ctrl+C is pressed
* Prevent slow down when multiple requests hit a collection during cache warm-up

2.1.2 - Wild Radish
-------------------

This feature is not compatible with the 1.x.x versions. See
http://radicale.org/1to2/ if you want to switch from 1.x.x to
2.x.x.

* Remove workarounds for bugs in VObject < 0.9.5
* Error checking of collection tags and associated components
* Improve error checking of uploaded collections and components
* Don't delete empty collection properties implicitly
* Improve logging of VObject serialization
@Unrud
Copy link
Collaborator Author

Unrud commented May 4, 2018

Fixed by #813

@Unrud Unrud closed this as completed May 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants