#6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both))
by Luc Saffre · in Developers · assigned to Luc Saffre
Kokkuvõte
Children
Kommentaarid
- 2 kuud, 1 nädal ago by Luc Saffre in reply to Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : Seems that it is: I manually deleted the superfluous files, then ran checkdata -f and dump2py and pm prep, and there was still only one file.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) (1 reply) : TODO: verify whether the original issue is fixed.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : There is one subtle difference after my changes: wrap_source() in lino.modlib.memo.mixins is no longer called for overview field.
- 2 kuud, 1 nädal ago by Luc Saffre in reply to Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : Yes, that was it.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) (1 reply) : pm prep in noi2e says "Add 2 screenshots to 0 tickets.", and one doctest failure says:
094 >>> d = store.row2dict(ar, t1) 095 >>> d['TicketsByParent2'] 096 {'delayed_value_url': 'values/tickets/AllTickets/1/TicketsByParent2'} 097 >>> pprint(d) Differences (unified diff with -expected +actual): @... - 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : The demo2 fixture of comments generates the comments with memo commands that mention other database objects.
- 2 kuud, 1 nädal ago by Luc Saffre in reply to Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : The failure in test_workflow.py had a natural reason: I had forgotten to create an upload, so it was normal that the [ERROR list index out of range in '[file]' at position 117-123] command didn't mention anything. But in noi1e this is not the explanation , i verified this by setting memo.error_tolerance to 0 in noi1e settings.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) (1 reply) : I'm still not finished, but I managed to write a unit test that isolates the problem. book/lino_book/projects/noi1e/tests/test_workflow.py A ticket with "See also #1." causes a mention to get created, but "See also (Luc's version| Detail)." doesn't.
And in book/docs/apps/noi/memo.rst I added a section to t... - 2 kuud, 1 nädal ago by Luc Saffre in reply to Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : To avoid it, I currently run the memo parser twice, once on the full preview and once on the short preview. Hm...
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) (1 reply) : My current approach has a side effect : memo commands would no longer get executed in the short preview. I wonder whether we want this.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : The problem is that sanitized_soup() is being called multiple times during save() (in replace_toc(),
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : I started to tidy up the code. Changed the parse_source_text() method to be an instance method on the choice and no longer a class method the choicelist.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : I wonder whether HistoryAwarePreviewable works when editor_type changes. @8lurry let's look at this together.
- 2 kuud, 1 nädal ago by Luc Saffre in reply to Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : More precisely the EditorTypes feature.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) (1 reply) : The HistoryAwarePreviewable makes things more complicated.
- 2 kuud, 1 nädal ago by Luc Saffre in reply to Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : Yes, BasePreviewable.save() saves the two preview fields but never touches the content of the source field.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) (1 reply) : Sharif and i looked at it. The sanitizer looks okay, It seems to be something about the soup not getting saved. Because the body of the EN home page on stewards continues to contain the full image data even after saving it.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : @8lurry I'd like to show this to you as long as the issue is observable on stewards.
- 2 kuud, 1 nädal ago by Luc Saffre about #6962 (Upload files created by img tags get duplicated by restore.py or checkdata (or both)) : Created new Ticket #6962 (Upload files created by img tags get duplicated by restore.py).