singer-io / tap-appsflyer

A Singer.io tap for extracting data from the AppsFlyer API
GNU Affero General Public License v3.0
11 stars 40 forks source link

chore(__init__): add xform caster from string to integer #3

Closed gautiermorel closed 6 years ago

gautiermorel commented 6 years ago

First I was thinking about edit raw_datas schemas, but maybe with this workaround, it will be more flexible to avoid violation schema errors. I have no test environments through Singer, so I hadn't got any chances to test my code before create this pull request. Thanks ;)

Gautier

cmerrick commented 6 years ago

Hi @gautiermorel, thanks for your contribution!

In order for us to evaluate and accept your PR, we ask that you sign a contribution license agreement. It's all electronic and will take just minutes.

cmerrick commented 6 years ago

You did it @gautiermorel!

Thank you for signing the Singer Contribution License Agreement.

KAllan357 commented 6 years ago

Hi @gautiermorel I think this might not work well for us. Based on my understanding and the example I saw in https://github.com/singer-io/tap-appsflyer/issues/2 this would still fail.

A value of '5a5eb9c9bc9b350014690a5a' would be passed to this function which would raise and then reraise a ValueError as it tries to convert the value to a String.

My preference would be to just add the "string" type to the array here https://github.com/singer-io/tap-appsflyer/blob/master/tap_appsflyer/schemas/raw_data/in_app_events.json#L347

gautiermorel commented 6 years ago

Thanks for the reply ! So I will close this PR, edit in_app_events schema and push a new one :)