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

Import Web Assembly support from snapchat's djinni fork #157

Open
wants to merge 15 commits into
base: main
Choose a base branch
from

Conversation

mutagene
Copy link
Contributor

@mutagene mutagene commented Nov 6, 2023

I felt quite inspired by @eakoli 's latest contribution. I'm not sure there's the appetite for this, but at least on my projects, if I'm using djinni in the future it's hard to imagine not wanting the possibility of a web assembly (and flutter?) target. This is quite a naive attempt to steal that from the snapchat djinni, and without the lib-side work (which I haven't done yet), I'm not sure it even works. Anyway, the way these things go I may have time to work on it some more and I may not, so I thought I'd make the (draft) PR now and then worry about the rest later.

@mutagene mutagene force-pushed the import-wasm-support-from-snapchat branch from 9d18164 to 9ea2a7b Compare November 6, 2023 20:24
@a4z
Copy link
Contributor

a4z commented Nov 6, 2023

Wow, that's a pretty fantastic development!

Just a question: After looking back at the Python addition, I see that it is now 80% to 90% done but then slowed down.
Is there a danger we will end up in a similar situation (which might also be OK, because better 80% than nothing)
Or can we have a sample Hello World app utilizing this WASM generator once it is no longer in draft state?

@mutagene mutagene changed the title [DRAFT] Try to bring in some subset of web assembly set from snapchat-djinni [DRAFT] Try to bring in some subset of web assembly supportfrom snapchat-djinni Nov 7, 2023
@mutagene
Copy link
Contributor Author

mutagene commented Nov 7, 2023

Yes, I think we need some kind of definitive sample for this to be moved out of draft status. I haven't checked what there is in the snapchat repository, yet. I understand your concerns about abandoned platforms, but (at least for me) web assembly is pretty essential. I think that, given the state of the support on the snapchat fork, it should be possible to get the web assembly support here quite usable without too much pain. Fingers crossed. Next up the support lib, I guess.

@mutagene mutagene force-pushed the import-wasm-support-from-snapchat branch 3 times, most recently from 3027080 to e0c0dce Compare November 18, 2023 22:35
@mutagene mutagene force-pushed the import-wasm-support-from-snapchat branch from 801ded6 to 76ef1b2 Compare November 20, 2023 19:01
@eakoli
Copy link
Contributor

eakoli commented Nov 21, 2023

One of my general concerns with this PR is how many changes seem be outside of the new generator code, as in theory, adding a new generator should change little of the existing code other than extending the places to enable the new output.

E.g. Ive started working on a swift and kotlin generator and so far haven't had to make any changes to existing code other than adding the options and extra bools to enable them during testing

@a4z
Copy link
Contributor

a4z commented Nov 21, 2023

I agree, we need to check that all changes are related to the WASM part and not sneak in via any other Snapchat additions that might change behavior.

On the other hand, if the expected files from the tests are unchanged, nothing should have changed (or our tests are incomplete). So we should have some safety net in place,

@mutagene
Copy link
Contributor Author

One of my general concerns with this PR is how many changes seem be outside of the new generator code, as in theory, adding a new generator should change little of the existing code other than extending the places to enable the new output.

E.g. Ive started working on a swift and kotlin generator and so far haven't had to make any changes to existing code other than adding the options and extra bools to enable them during testing

I've been trying to reduce these changes. I think all that remains is the isOptional change/fix, which I think/hope is tolerable given that it has not forced any changes in existing expected generated c++ code.

@mutagene mutagene force-pushed the import-wasm-support-from-snapchat branch from d77aee4 to d78420d Compare November 26, 2023 11:36
@mutagene mutagene changed the title [DRAFT] Try to bring in some subset of web assembly supportfrom snapchat-djinni [DRAFT] Import Web Assembly support from snapchat's djinni fork Nov 26, 2023
@mutagene mutagene marked this pull request as ready for review December 2, 2023 10:15
@mutagene mutagene changed the title [DRAFT] Import Web Assembly support from snapchat's djinni fork Import Web Assembly support from snapchat's djinni fork Dec 2, 2023
@a4z
Copy link
Contributor

a4z commented Dec 10, 2023

I am sorry, but looking at my calendar, it is very likely my review must wait until the Christmas holidays.
I want to prioritize these tasks, and I will try to do it, but it is difficult.
Thank you for your understanding and patience.

@mutagene mutagene force-pushed the import-wasm-support-from-snapchat branch from ba6c5bb to e5e0995 Compare December 29, 2023 23:45
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.

3 participants