[Haskell-cafe] Yesod double free or corruption

2012-12-12 Thread Andras Gyomrey
Hi,

i got the following error using yesod devel it happened after adding the
file which seems to have invalid content (not true). What should i do?

Andras Gyomrey
Yesod devel server. Press ENTER to quit
yesod: ./Handler/Model/Season.hs: hGetContents: invalid argument (invalid byte 
sequence)
*** glibc detected *** yesod: double free or corruption (out): 
0x2b5fe0006b10 ***
=== Backtrace: =
/lib64/libc.so.6(+0x75916)[0x2b5fda07b916]
/lib64/libc.so.6(+0x78443)[0x2b5fda07e443]
/lib64/libc.so.6(+0x203c6)[0x2b5fda0263c6]
/lib64/libc.so.6(iconv_close+0xf)[0x2b5fda02595f]
yesod[0x317d93a]
=== Memory map: 
0040-035a6000 r-xp  00:1b 112951588  
/home/paxer/.cabal/bin/yesod
037a5000-03bc1000 rwxp 031a5000 00:1b 112951588  
/home/paxer/.cabal/bin/yesod
03bc1000-03bca000 rwxp 03bc1000 00:00 0
05e7f000-05ec1000 rwxp 05e7f000 00:00 0  [heap]
2b5fd8ec1000-2b5fd8ee1000 r-xp  00:1b 99617724   
/lib64/ld-2.12.so
2b5fd8eef000-2b5fd8ef rwxp 2b5fd8eef000 00:00 0
2b5fd90e-2b5fd90e1000 r-xp 0001f000 00:1b 99617724   
/lib64/ld-2.12.so
2b5fd90e1000-2b5fd90e2000 rwxp 0002 00:1b 99617724   
/lib64/ld-2.12.so
2b5fd90e2000-2b5fd90e3000 rwxp 2b5fd90e2000 00:00 0
2b5fd90e3000-2b5fd90f8000 r-xp  00:1b 99617828   
/lib64/libz.so.1.2.3
2b5fd90f8000-2b5fd92f7000 ---p 00015000 00:1b 99617828   
/lib64/libz.so.1.2.3
2b5fd92f7000-2b5fd92f8000 r-xp 00014000 00:1b 99617828   
/lib64/libz.so.1.2.3
2b5fd92f8000-2b5fd92f9000 rwxp 00015000 00:1b 99617828   
/lib64/libz.so.1.2.3
2b5fd92f9000-2b5fd930 r-xp  00:1b 99628779   
/lib64/librt-2.12.so
2b5fd930-2b5fd94ff000 ---p 7000 00:1b 99628779   
/lib64/librt-2.12.so
2b5fd94ff000-2b5fd950 r-xp 6000 00:1b 99628779   
/lib64/librt-2.12.so
2b5fd950-2b5fd9501000 rwxp 7000 00:1b 99628779   
/lib64/librt-2.12.so
2b5fd9501000-2b5fd9503000 r-xp  00:1b 99625968   
/lib64/libutil-2.12.so
2b5fd9503000-2b5fd9702000 ---p 2000 00:1b 99625968   
/lib64/libutil-2.12.so
2b5fd9702000-2b5fd9703000 r-xp 1000 00:1b 99625968   
/lib64/libutil-2.12.so
2b5fd9703000-2b5fd9704000 rwxp 2000 00:1b 99625968   
/lib64/libutil-2.12.so
2b5fd9704000-2b5fd9705000 rwxp 2b5fd9704000 00:00 0
2b5fd9705000-2b5fd9707000 r-xp  00:1b 99623838   
/lib64/libdl-2.12.so
2b5fd9707000-2b5fd9907000 ---p 2000 00:1b 99623838   
/lib64/libdl-2.12.so
2b5fd9907000-2b5fd9908000 r-xp 2000 00:1b 99623838   
/lib64/libdl-2.12.so
2b5fd9908000-2b5fd9909000 rwxp 3000 00:1b 99623838   
/lib64/libdl-2.12.so
2b5fd9909000-2b5fd995f000 r-xp  00:1b 99624917   
/usr/lib64/libgmp.so.3.5.0
2b5fd995f000-2b5fd9b5f000 ---p 00056000 00:1b 99624917   
/usr/lib64/libgmp.so.3.5.0
2b5fd9b5f000-2b5fd9b64000 rwxp 00056000 00:1b 99624917   
/usr/lib64/libgmp.so.3.5.0
2b5fd9b64000-2b5fd9be7000 r-xp  00:1b 99625157   
/lib64/libm-2.12.so
2b5fd9be7000-2b5fd9de6000 ---p 00083000 00:1b 99625157   
/lib64/libm-2.12.so
2b5fd9de6000-2b5fd9de7000 r-xp 00082000 00:1b 99625157   
/lib64/libm-2.12.so
2b5fd9de7000-2b5fd9de8000 rwxp 00083000 00:1b 99625157   
/lib64/libm-2.12.so
2b5fd9de8000-2b5fd9de9000 rwxp 2b5fd9de8000 00:00 0
2b5fd9de9000-2b5fd9e0 r-xp  00:1b 99617779   
/lib64/libpthread-2.12.so
2b5fd9e0-2b5fda00 ---p 00017000 00:1b 99617779   
/lib64/libpthread-2.12.so
2b5fda00-2b5fda001000 r-xp 00017000 00:1b 99617779   
/lib64/libpthread-2.12.so
2b5fda001000-2b5fda002000 rwxp 00018000 00:1b 99617779   
/lib64/libpthread-2.12.so
2b5fda002000-2b5fda006000 rwxp 2b5fda002000 00:00 0
2b5fda006000-2b5fda18f000 r-xp  00:1b 99617771   
/lib64/libc-2.12.so
2b5fda18f000-2b5fda38f000 ---p 00189000 00:1b 99617771   
/lib64/libc-2.12.so
2b5fda38f000-2b5fda393000 r-xp 00189000 00:1b 99617771   
/lib64/libc-2.12.so
2b5fda393000-2b5fda394000 rwxp 0018d000 00:1b 99617771   
/lib64/libc-2.12.so
2b5fda394000-2b5fda39b000 rwxp 2b5fda394000 00:00 0
2b5fda40-2b5fda50 rwxp 2b5fda40 00:00 0
2b5fda50-2b5fda501000 ---p 2b5fda50 00:00 0
2b5fda501000-2b5fdaf01000 rwxp 2b5fda501000 00:00 0
2b5fdaf01000-2b5fdaf08000 r-xs  00:1b 99630484   
/usr/lib64/gconv/gconv-modules.cache
2b5fdaf08000-2b5fdaf0a000 r-xp  00:1b 99625937   
/usr/lib64/gconv/UTF-32.so
2b5fdaf0a000-2b5fdb109000 ---p 2000 00:1b 99625937   
/usr/lib64/gconv/UTF-32

Re: [Haskell-cafe] HaskellDB Convertible Exception: incompatible types

2012-10-04 Thread Andras Gyomrey
Hi,

going deeper i found the following:

http://hackage.haskell.org/packages/archive/haskelldb-hdbc/2.1.0/doc/html/src/Database-HaskellDB-HDBC.html#line-126

HaskellDB is converting from SqlTimestampT (no timezone defined) to
CalendarTimeT (timezone required). This conversion tries then to be done
using LocalTime (
http://hackage.haskell.org/packages/archive/HDBC/2.2.6.1/doc/html/src/Database-HDBC-SqlValue.html#line-735
)
 which fails.

I believe real problem is CalendarTimeT. SqlTimestampT clearly doesn't
define a timezone. There's a need to create a new type to handle these
types. Timestamps but no timezone (Localtime).

I attach a patch for this. I tested this in a project. Not quite sure how
to add the tests. What should i do to add this patch to haskell? A version
dependency of this two should be added,

Andras


2012/9/29 Andras Gyomrey lgand...@gmail.com

 Hi,

 I get

 *** Exception: Convertible: error converting source data SqlLocalTime
 2012-04-27 10:22:15 of type SqlValue to type
 Data.Time.LocalTime.LocalTime.ZonedTime: incompatible types

 when i try to show a record with a field of type CalendarTime
 (automatically generated by Database.HaskellDB.DBDirect, Mysql database
 type is timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE
 CURRENT_TIMESTAMP

 I already looked forhttp://
 haskell.1045720.n5.nabble.com/programmatic-DB-interface-td3120759.html.
 But the problem there is about a regexp (not a type). And the incompatible
 type problem was caused because of a concatenation. Here, as you can see, i
 have no idea what's going on.

 Can someone please help me?

 Andras




haskelldb-2.1.1.patch
Description: Binary data


haskelldb-hdbc-2.1.0.patch
Description: Binary data
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] HDBC nested withTransaction

2012-07-18 Thread Andras Gyomrey
Hi,

are there any plans of implementing nested transactions using
withTransaction in HDBC?
In mysql exists checkpoints and in postgres explicit subtransactions,

Andras Gyomrey
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe