Re: Re: large file endings in ZMS Image
Niels Dettenbach <[email protected]> Thu, 16 Jun 2011 16:11:46 +0200
| Newsgroups | gmane.comp.cms.zms.devel |
|---|---|
| Organization | Syndicat IT&Internet |
| Message-ID | <[email protected]> |
Am Donnerstag 16 Juni 2011, 15:46:05 schrieben Sie:
> thanks for sharing the code. Can you explain the connection to your
> problems with mediafolder code. Why did the "pack" function fail before
> you fixed the object tree - did ZMS raise any Exception? Why was it
> necessary to fix the "version" attributes?
However i got strange errors when using "pack db" or while try to reimport stuff - even from objects which did not held any stuff in media db (i.e.text objects...).
I.e.:
--- schnipp ---
2011-06-08T12:05:12 ERROR root [ZMSTextarea@/e7849][getObjVersions]: an unexpected error occured!
Traceback (most recent call last):
File "/var/zope/srg212/Products/zms/_versionmanager.py", line 1032, in getObjVersions
obs.insert(0,(getattr( ob,'master_version',0) * 10000 + getattr( ob,'major_version',0) * 100 + getattr( ob,'minor_version',0),ob))
TypeError: unsupported operand type(s) for +: 'int' and 'list'
--- schnapp ---
Such objects got "repaired" (means, working without errors) when i opened them in ZMS or even just the numerical id object in ZMI (Zope view) and clicked "save" without any changes within
ZMS or the ZMI forms. So i tried to read the version vars and wrote them back if possible. Not all of the objects gave out the versions vars by script (but in ZMI they was shown with "0"...). From
my view this was a strange behaviour...
So i temporarily tried in _versionmanager.py to capsulate:
obs.insert(0,(getattr( ob,'master_version',0) * 10000 + getattr( ob,'major_version',0) * 100 + getattr( ob,'minor_version',0),ob))
into a python transaction (try: except) which leads to packing to run until end - but with lost objects with large file endings. Because i had problems with large file endings, special filenames (i.e.
long ones with the same long "prefix" - i.e. as from digicams) or special chars within filenames several times before in older ZMS versions too (no thumbs generated or) i posted here.
Now i assume my temporarily hack within _versionmanager.py (try: except) did lead to that effect here.
> Please share your insight!
Not shure how far that can help you here - pls feel free to ask or investigate with me.
Sorry for the noise...
best regards,
Niels.
--
---
Niels Dettenbach
---
Syndicat IT&Internet
http://www.syndicat.com
T.-Muentzer.-Str. 2, 37308 Heilbad Heiligenstadt - DE
---
Kryptoinfo:
PGP public key ID 651CA20D
Fingerprint: 55E0 4DCD B04C 4A49 1586 88AE 54DC 4465 651C A20D
https://syndicat.com/pub_key.asc
---
signature.asc
(application/pgp-signature, 836 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (GNU/Linux) iQIcBAABCAAGBQJN+g8iAAoJEM78prARigUnL88P/RRRRMqNtdTbpyWP75uYVqAk yoe4koMJDB+fbvFneiTJqw7rVUzlkT1+drdTAwdijjsbtGv4Pyea4ZMw7brGa+y/ 3yGfyMxjkrxVjRTT6TLYIsHf0c0UeBH9Jl/he1hCpnpuDoceplod75ZdMIBAmOS3 2SU/7Ms4PUGjOoQuZ3WJ5C1Hg3JL8ggLq9fhwDI6eDMI/DWzPpgUUDoLn0WkIazn oqukJKaYqh1+HfNcQZbPSEyoNRwP0P6q2aPpGrwiiAJUY2vpbGfuJe17rzi5JBGe PNCG9OLcAdUTZvE5j80IDogFtxqLl3PkxSwbHULYmkfF4PidwaYEPYeDJpjaDsMS 8pogtOZfS4p0mtXNk18JFxbSfZ5M9hC6w9tglYiFmLHXUFe8SEpeC+zlXqk4CU81 UGWJVk2QcjpBC5WtoxJWN1YFmLKgQh9tjrfYOhUNHURpS/XdVi+EaC3LJ8TRh8NY 9A6LXFdgP9DW/7CCiQeT/XHbfNtjHwLSJUtf/YMwiyH/NvXIsTz33qLmBgBtCQSh 1+Q7hT4xSHHlm/wUFPJM4695t7T7odMzrje6mrNPAY+J/bJLTG6FhccLBO7iLzOa 9QKGF5d8gJmfkiGojO1TQF/d2QOXEBv4A+1nDUUZvDv8nh8BkAkN7ZF879XdmXko QiZ0+NWPlUIIU+s4ah4T =5/An -----END PGP SIGNATURE-----