Home Forums Support Importing JSON in pro plan dosn't work

This topic contains 15 replies, has 3 voices, and was last updated by  DavidBomba 1 month, 1 week ago.

Viewing 16 posts - 1 through 16 (of 16 total)
  • Author
    Posts
  • #22821

    paroiron
    Participant

    Hi, after setting both my local self hosted Invoice Ninja and my pro plan to English, I exported to a JSON file and imported both data and settings to my pro plan, but it failed. I’ve tried to import data only or settings only with the same lack of success. The only message I get is “Please select a file” in a reddish line up the screen.
    I’ve had no luck with the knowledge base or the forum.
    I have custom fields, but I don’t think it is a problem, is it?
    Is there anything I should double check or configure ? Thanks !

    (By the way, I think import/export should be independent from language.)

    #22822

    paroiron
    Participant

    CSV seems to work, but it seems like I can’t get all the data from it.

    #22825

    Hillel Coren
    Keymaster

    Hmmm… the language shouldn’t affect the JSON import/export.

    If you’re transferring from self-host to hosted can you confirm the self host app is running the latest version.

    #22826

    paroiron
    Participant

    Hi,
    About the language, I assumed it was sensitive because there’s a warning on the app’s import page (“use English”).
    My local install is very close to the latest version, i.e. 4.5.xx. I’ll check tomorrow ’cause it’s past bedtime here.
    Cheers

    #22830

    paroiron
    Participant

    Checked : self hosted is v.4.5.4. I don’t think such a minor difference in version should be a problem : I understand you can’t guarantee backward compatibility, but forward compatibility on a third digit version shouldn’t matter. Am I mistaken ?

    #22833

    Hillel Coren
    Keymaster

    I’m not sure.. that said if the problem were due to a version mismatch I’d expect it to fail during the import, it sounds like you aren’t able to upload the JSON file itself. How large is the file, maybe it’s a size issue?

    #22835

    paroiron
    Participant

    Yes it seems like no file was passed to the app. File is 2.4Mo. Nothing close to a big data problem. Maybe a timeout if your server is a bit too busy ?
    I tried to create another account on my self hosted Invoice Ninja and to import the same file : it took a few minutes but it worked, so I don’t think the file is corrupted. I had about 30 error messages though :
    “{“account_key”:”bbeqkrvxhdkk3mh85mbwpup1st3f3nit”,”is_owner”:true,”amount”:100,”transaction_reference”:””,”payment_date”:”2019-10-30″,”updated_at”:1572430401,”archived_at”:null,”is_deleted”:false,”payment_type_id”:1,”invoice_id”:236,”invoice_number”:”F201910347″,”private_notes”:””,”exchange_rate”:1,”exchange_currency_id”:0,”refunded”:0,”payment_status_id”:4,”type”:”payment”,”error”:”The client does not have enough credit.”}
    After some investigation, it seems like I lost past/used and pending credits, creating this problem.

    Any idea on one of these now two problems ? That’s quite annoying, I can’t use my pro plan if I can’t transfer the data safely.

    • This reply was modified 1 month, 2 weeks ago by  paroiron.
    • This reply was modified 1 month, 2 weeks ago by  paroiron.
    #22841

    Hillel Coren
    Keymaster

    I’m not sure about the first issue, maybe it’s related to the character encoding?

    I believe the second issue is an open bug.

    #22854

    paroiron
    Participant

    So what can I do ?

    How can I transfer my data to my pro plan ? CSV doesn’t seem to be an option, as it can only transfer some fields, not all the data. I like the JSON process, because it’s complete (settings and all the data).

    It raises another question : on a pro plan, I guess you have a backup system for the data we put in the app. But if I want to backup on my side using JSON and cannot use it, I don’t feel safe.

    #22856

    paroiron
    Participant

    You’re right the second issue is #2075 bug for applied credits of may 2018 :
    https://github.com/invoiceninja/invoiceninja/issues/2075
    I can manually correct it because I only have 3 dozens of concerned invoices. I’m lucky I don’t have 3 hundreds.

    Still I can’t import the JSON on my pro plan (first issue). Is there any workaround you could think of ?

    • This reply was modified 1 month, 2 weeks ago by  paroiron. Reason: disambiguation
    #22859

    Hillel Coren
    Keymaster

    Another option would be to use a third party site such as Zapier, Intergormat or Piesync to transfer the data.

    #22888

    paroiron
    Participant

    I won’t, because I subscribed to the pro plan to simplify my tasks at the shop, not to spend hours searching how to use a third party app to transfert data from invoiceninja to invoiceninja.

    I tried to change endlines or things of the kind to the files (dos2unix / unix2dos) with no success. I tried to export from the online version and import into the online version : no problem, even with applied credits (bug #2075 not reproduced here, that’s encouraging).

    #22889

    paroiron
    Participant

    OKay, some new progress : updating my local app to v4.5.17 did no change, but exporting from online app and importing back again works perfectly fine, even for applied credits (no more bug #2075).

    I think the problem is related to file size : my current failing JSON file is 2.5M, but a much smaller 20k JSON file makes it from my local app to the online one hands down !

    Hillel : would you or someone of your crew check the file size limit for JSON import on pro plans please ?

    • This reply was modified 1 month, 1 week ago by  paroiron. Reason: disambiguaton
    #22900

    Hillel Coren
    Keymaster

    I agree it seems like a server configuration issue, we’ll look into it…

    #22903

    paroiron
    Participant

    Thank you, let me know when you think it’s ok, because I really need to transfer all this on my pro plan before Jan.1st.

    #22905

    DavidBomba
    Keymaster

    @paroiron

    Can you send us an email [email protected] i’ll give you some instructions from there.

    Thanks

Viewing 16 posts - 1 through 16 (of 16 total)

You must be logged in to reply to this topic.

Posted in: