Correction: we are making fastavro a default option on Python 3 only for now. You can follow https://github.com/apache/beam/pull/8130 for updates on that.
*From:*Valentyn Tymofieiev <[email protected]> *Date:*Fri, May 3, 2019, 10:41 PM *To:* <[email protected]> Hi, > > Unfortunately, Avro library currently doesn't work well with Python 3. > Could you try using fastavro in your pipeline and report back if that > helped to resolve your issue? We are also making fastavro a default option, > likely starting from 2.13.0. You could use fastavro as follows > > (sent from Phone, apologies for possible errors): > > WriteToAvro( > ..., > use_fastavro=True > ) > > > > > *From:*Chengxuan Wang <[email protected]> > *Date:*Fri, May 3, 2019, 8:30 PM > *To:* <[email protected]> > > Hi, >> I am trying to create a PTransform to combine avro schemas. But I met >> `json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)`, >> I think It is related to >> https://github.com/apache/avro/blob/master/lang/py3/avro/schema.py#L1058 . >> Because avro didn't implement __ne__, it will use __eq__ delegated. >> >> Then I saw there is `without_default` method in CombineGlobally, so I >> add that. Now I get `xception: Attempting to map key 'b' to value >> <avro.schema.Field object at 0x7f71b435ec50> in ImmutableDict {} [while >> running 'WriteToAvro/_WriteToAvroWithNoSchema/WriteBundles']`. >> >> Does anyone have this problem before? I am using python3 with apache-beam >> 2.12.0(the latest one)? >> >> It works fine under python2, but can't work under python3. >> >> Thanks, >> Chengxuan >> >
