TypeError: spans is not iterable TypeError: spans is null

Hello everbody:
We have been annotating texts using spans.manual recipe.
While reviewing the discrepancies, we faced this problem:

Oops, something went wrong 🙁.
Check the console for possible errors.

You might have come across a bug in Prodigy's web app – sorry about that. We'd love to fix this, so feel free to open an issue on the Prodigy Support Forum and include the steps that led to this message.

TypeError: spans is not iterable ---> When trying to re-annotate the text.
`- TypeError: spans is null.` ---> When trying to reject or ignore the text

  • In another trial, we got the same message but with:
    Any idea, how to fix this problem? We cannot proceed to the next document. We tried: Annotating the text, ignoring it and finally rejecting it, but we have these errors

Thanks for getting in touch about this. It does look like it might be a bug in Prodigy.

Could you give a sample line from the dataset? It's okay if you need to delete the text for privacy reasons. You should be able to get it with prodigy db-out.

Thanks @honnibal for your inmediate response. Here is a fragment of the 1st line of the text:
{"text":"BOCCE Bolet\u00edn Oficial Ciudad de Ceuta A\u00f1o XCV Viernes de Febrero de 2020 SUMARIO AUTORIDADES Y PERSONAL EXTRAORDINARIO CIUDAD AUT\u00d3NOMA DE CEUTA 22.- Decreto de fecha 19 de febrero de 2020, por el que se nombra a ....}
The, this is a fragmento of the first line of the tokens:
"tokens":[{"text":"BOCCE","start":0,"end":5,"id":0,"ws":true},{"text":"Bolet\u00edn","start":6,"end":13,"id":1,"ws":true},{"text":"Oficial","start":14,"end":21,"id":2,"ws":true},{"text":"Ciudad","start":22,"end":28,"id":3,"ws":true},{"text":"de","start":29,"end":31,"id":4,"ws":true},{"text":"Ceuta","start":32,"end":37,"id":5,"ws":true},{"text":"A\u00f1o","start":38,"end":41,"id":6,"ws":true},{"text":"XCV","start":42,"end":45,"id":7,"ws":true},{"text":"Viernes","start":46,"end":53,"id":8,"ws":true},{"text":"de","start":54,"end":56,"id":9,"ws":true},{"text":"Febrero","start":57,"end":64,"id":10,"ws":true},{"text":"de","start":65,"end":67,"id":11,"ws":true},{"text":"2020","start":68,"end":72,"id":12,"ws":true},{"text":"SUMARIO","start":73,"end":80,"id":13,"ws":true},{"text":"AUTORIDADES","start":81,"end":92,"id":14,"ws":true},{"text":"Y","start":93,"end":94,"id":15,"ws":true},{"text":"PERSONAL","start":95,"end":103,"id":16,"ws":true},{"text":"EXTRAORDINARIO","start":104,"end":118,"id":17,"ws":true},{"text":"CIUDAD","start":119,"end":125,"id":18,"ws":true},{"text":"AUT\u00d3NOMA","start":126,"end":134,"id":19,"ws":true},{"text":"DE","start":135,"end":137,"id":20,"ws":true},{"text":"CEUTA","start":138,"end":143,"id":21,"ws":true},{"text":"22.-","start":144,"end":148,"id":22,"ws":true},{"text":"Decreto","start":149,"end":156,"id":23,"ws":true},{"text":"de","start":157,"end":159,"id":24,"ws":true},{"text":"fecha","start":160,"end":165,"id":25,"ws":true},{"text":"19","start":166,"end":168,"id":26,"ws":true}

Please let me know once you can check it, so I can delete it.

Could you double-check if one of your examples has "spans": null in it or similar? From the error, it definitely sounds like there's something wrong with the format of the JSON that our back-end data validation didn't catch :thinking:

Thank you, Ines! We will check anyways and we will get back to you. Both texts under review had labelled spans.
:thinking: