-
Craig Silverstein authored
## Summary: This repo has had a bit of bitrot. It has submodules that seem to be unused. It's also very old code. I kept the logic unchanged but moved the code to python3. Note that this must be deployed with parallel changes to the Dockerfile in Khan/internal-services/graphie-to-png/. Issue: https://khanacademy.atlassian.net/browse/INFRA-10116 ## Test plan: I ran: ``` % ./cleanup_svg.py < /usr/share/yelp-xsl/xslt/common/icons/yelp-note-advanced.svg <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path d="M5.447 12.572A5.98 5.98 0 0 0 2 18v4h20v-4a5.98 5.98 0 0 0-3.441-5.424A8 8 0 0 1 12 16a8 8 0 0 1-6.553-3.428" class="yelp-svg-fill"/><path d="M12 3a5 5 0 0 0-5 5 5 5 0 0 0 5 5 5 5 0 0 0 5-5 5 5 0 0 0-5-5m0 3a2 2 0 0 1 2 2 2 2 0 0 1-2 2 2 2 0 0 1-2-2 2 2 0 0 1 2-2" class="yelp-svg-fill"/><path d="M15.312 6 19 7v2l-3.469 1zM14 11.312 13 15h-2l-1-3.469zM10 4.688 11 1h2l1 3.469zM8.688 10 5 9V7l3.469-1z" class="yelp-svg-fill"/><path d="m12.928 4.244 3.315-1.9 1.414 1.413-1.746 3.16zM15.757 8.928l1.9 3.315-1.414 1.414-3.16-1.746zM8.244 7.072l-1.9-3.315 1.413-1.414 3.16 1.746zM11.072 11.757l-3.315 1.9-1.414-1.414 1.746-3.16z" class="yelp-svg-fill"/></svg> ``` which seems plausible to me. I also ran `cp secrets.py.example secrets.py; ./server.sh` and visited http://localhost:8765/ and got a reasonable homepage. I selected one of the images from the dropdown and clicked "convert to image" and got an error that the S3 key was wrong, which means the logic to talk to S3 is looking good. Author: csilvers Reviewers: benchristel, mpolyak, csilvers Required Reviewers: Approved By: benchristel, mpolyak Checks: Pull Request URL: https://github.com/Khan/graphie-to-png/pull/23
Loading