vercel-dart
vercel-dart copied to clipboard
Migrating to null safety
I got dependency conflict between shelf
and notion_api
, can you migrate vercel-dart to null safety and also aws-lambda-dart-runtime
is already supported null safety. Btw the process is pretty simple though, check out https://dart.dev/null-safety/migration-guide.
I tried to do it myself but failed pathetically, I don't know how to test the project locally with vercel dev
so I published it to npmjs.com but it's still didn't resolve the conflict, maybe a trouble at build.sh
> reading and writing pubspec.yam
, make it still use the old shelf
version (^0.7.9) instead of the new one I just added (^1.2.0)
Because every version of vercel_dart from git depends on shelf ^0.7.9 and api depends on shelf ^1.2.0, vercel_dart from git is forbidden.
So, because api depends on vercel_dart from git, version solving failed.
Thanks for the report. But that aws-lambda-dart-runtime
is really messed up. The main repo is no longer maintained and one contributor is continuing the work from a fork. But the problem is even he didn't add my PR which fixes a severe bug. So I can't use their null-safety-migrated repo, and I might need to update my fork. But then there's gonna be dependency conflicts and my fork will never be able to merge. Plus if I fork his updated fork, then my PR's on the main repo gonna become invalid.
For now, I think I'm just gonna have to update my fork separately. I'll let you know soon.
Update: Seems like that one guy's fork is also no longer actively maintained. This is so messed up.
Seems like that one guy's fork is also no longer actively maintained. This is so messed up.
You talking about katallaxie/aws-lambda-dart-runtime right? I know it is not actively maintaining but it has enough features and null safety right? I can fork his and add your code or I invite you to collaboration in case you don't want to lose your PR.
Man, using Flutter Web with Dart Server is kind of cumbersome and not much of support, at first I want to deploy Flutter Web on Netlify and use it Serverless Functions, but I found your project so I don't have to deal with JS/TS. I really want to help you but I don't know how vercel-dart code flow (even read the vercel guide, didn't contain much though), like I migrate the "dart" directory to null safety and it's still read and write the old pubspec.
I don't have much knowledge about backend, so if I choose to use Netlify Serverless Functions with Deno, Node, Express (JS/TS) or whatever Javascript can I convert Dart class model into JS model in case I don't want to rewrite the same model twice just because of the language difference. Like fetch notion_api
using Serverless Function and serialize it into a class model (Dart class model into JS model) and return its deserialized as json. So when I call the function in Flutter Web I can reuse the Dart class model.
Oh, nevermind I take my words back. I just found out that the bug has been fixed altogether with null-safety. I'll release vercel-dart
as a pub package and will also update the NPM package.
Thank you so much, if you are free please do it quick, it will not take much of your time though. But if you not then let me know so I can arrange my work. Once again, thank you so much!
Hey, Frenco here. Just notifying you that "no they didn't fix it even though I thought they did". I've spent maybe the last 3-hours finding a way to make it work via my own fork but my old solution won't any longer work with the current null-safety migrated code. Sorry to say that but you might arrange your work for the better.
I'll make sure to fix that bug and will make this work but might take a bit longer though since I'm a tad difficult to give my time on OSS on weekdays. Sorry about that. This is related to https://github.com/dart-lang/http/issues/577.
Oh shit, didn't think it's pretty complicated, thank you so much for all the hard work, I'll find another way around, feel free to do it any time that fits your schedule. Btw I really appreciate your work bro!