Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correctly extract costume / sound hash for projects missing md5ext field #61

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

kchadha
Copy link

@kchadha kchadha commented Jun 2, 2022

Resolves

Some projects have costume or sound objects without an md5ext field. This is allowed by scratch-parser and scratch-vm. These changes help scratch-analysis extract the costume hash correctly in these cases.

I cannot figure out a good way to search for these projects in Kibana, but they appear as having a - instead of an md5 extension in the costumeHash field:

image

Proposed Changes

If we're trying to extract the md5ext from a costume or sound object and it's missing, use the assetId and dataFormat instead. These two fields are required by our project format and validated by scratch-parser.

Test Coverage

Added a test and a test fixture (production Scratch project) which exhibits this problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant