Trying to build the focal proposed package, it seems adding the mo files to SOURCES.txt with sed instead of regenerating SOURCES.txt does the job.
I changed debian/rules:
#rm -f horizon.egg-info/SOURCES.txt
sed -i 's/\(.*\)po$$/\1po\n\1mo/' horizon.egg-info/SOURCES.txt
Building the package with the original sources.txt, regenerating sources.txt and changed sources.txt gives:
Counting non .mo files in python3-django-horizon_18.3.2-0ubuntu0.20.04.1_all.deb
Original SOURCES.txt: 4335
Regenerated SOURCES.txt: 4301
Changed SOURCES.txt: 4335
Trying to build the focal proposed package, it seems adding the mo files to SOURCES.txt with sed instead of regenerating SOURCES.txt does the job.
I changed debian/rules: egg-info/ SOURCES. txt \)po$$/ \1po\n\ 1mo/' horizon. egg-info/ SOURCES. txt
#rm -f horizon.
sed -i 's/\(.*
Building the package with the original sources.txt, regenerating sources.txt and changed sources.txt gives:
Counting non .mo files in python3- django- horizon_ 18.3.2- 0ubuntu0. 20.04.1_ all.deb
Original SOURCES.txt: 4335
Regenerated SOURCES.txt: 4301
Changed SOURCES.txt: 4335
Counting .mo files
Original SOURCES.txt: 0
Regenerated SOURCES.txt: 96
Changed SOURCES.txt: 96
So changing SOURCES.txt adds the same number of .mo files without losing any non .mo file.
Also it doesn't loose any .json files:
Original SOURCES.txt: 21
Regenerated SOURCES.txt: 3
Changed SOURCES.txt: 21
The resulting package works fine and solves the problems for non-admin users.