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

Null-Safety with 9.0.0 changes #97

Closed
wants to merge 13 commits into from
Closed

Null-Safety with 9.0.0 changes #97

wants to merge 13 commits into from

Conversation

radvansky-tomas
Copy link

Hi I work with Greg and did requested changes from 9.0.0 branch.
I also resolved that one failing tests we had before. Please review it and try to merge it at least to develop branch.

gmcdowell and others added 13 commits February 16, 2021 13:39
refactored (& deprecated some) tests to pass
…fall back, incorrect dropdown min height value, handle null value in reactive slider
# Conflicts:
#	lib/src/widgets/reactive_checkbox.dart
#	lib/src/widgets/reactive_checkbox_list_tile.dart
#	lib/src/widgets/reactive_date_picker.dart
#	lib/src/widgets/reactive_dropdown_field.dart
#	lib/src/widgets/reactive_form_field.dart
#	lib/src/widgets/reactive_radio.dart
#	lib/src/widgets/reactive_radio_list_tile.dart
#	lib/src/widgets/reactive_status_listenable_builder.dart
#	lib/src/widgets/reactive_switch.dart
#	lib/src/widgets/reactive_switch_list_tile.dart
#	lib/src/widgets/reactive_text_field.dart
#	lib/src/widgets/reactive_time_picker.dart
@joanpablo
Copy link
Owner

Hi @radvansky-tomas,

Thanks for both of you, and for your work. I will review it. I will let you know soon. I guess then that I should merge this request instead of the one from @gmcdowell ??

@radvansky-tomas
Copy link
Author

yes correct, thank you for your time

@DevNico
Copy link

DevNico commented Mar 4, 2021

Flutter 2 is out and with it stable null safety a null safe version would be highly appreciated!

@joanpablo
Copy link
Owner

joanpablo commented Mar 4, 2021

I guys, Hi @radvansky-tomas @gmcdowell @DevNico,

I agree with you, null-safety is a Must now that Flutter 2 is announced. I have been working in stabilizations in type systems because something was broken in the last couple of releases, so that has been my focus. I feel responsible for bringing a stable plugin to the community. I'm waiting for a response to some issues related to the type system, after all those issues are solved my next focus is going to be null-safety and study and merge this PR.

I really appreciate your help. Thanks for your issues and patience.

@DevNico
Copy link

DevNico commented Mar 4, 2021

Could you mention the issues that are blocking for you so we can follow them too?

Also thank you for this great package!

@joanpablo
Copy link
Owner

joanpablo commented Mar 4, 2021

Type related issues:

Pull Requests related to Type System:

@gmcdowell
Copy link

@joanpablo thanks for the update and insight into your priorities.
We are going to continue to work on refining our branch (we will consolidate things too) and will keep an eye on your progress.

Do reach out if there is anything we can assist with.

@joanpablo
Copy link
Owner

Thanks @gmcdowell for your kind words, and thanks for the patient of all of you. I have released a couple of versions that solved some issues and I finally have added intl 0.17.0, so the project is not yet null safety but at least it is using the last version of intl.

@kuhnroyal
Copy link
Contributor

Really looking forward to this but I think a couple of dynamic things need to be removed before this is possible and valuable. See #102 (comment)

@DevNico
Copy link

DevNico commented Mar 17, 2021

Any updates on when a null safe version will be available? 😄

@joanpablo
Copy link
Owner

Hi guys,

@DevNico I'm working on it. I will need one more week. It's almost done, but because I'm doing two refactorings (null-safety and strict type system) I will need more time.

@DevNico
Copy link

DevNico commented Mar 17, 2021

Alright thanks for the update. Please don't feel rushed, take your time! I just wanted to know how far along you are.

Thank you for this great package!

@joanpablo
Copy link
Owner

Tomorrow I will push my branch so everybody can check my progress. All the library is already migrated to null safety but there are still some tests that are not running because of types of casting issues, I need to solve these casting issues in some way.

@cedvdb
Copy link

cedvdb commented Mar 18, 2021

@joanpablo Thanks for the awesome work. I'm interested in using your branch. Even if it's not production ready so I can start the null safety migration. So if it's possible to push it, it would be great

@joanpablo
Copy link
Owner

joanpablo commented Mar 23, 2021

Hi guys @gmcdowell, @radvansky-tomas, @DevNico, @cedvdb

I have updated the develop branch with a fully functional version of Reactive Forms using the latest version of Flutter with null-safety and a better type system. All tests are running OK. You can check it. I'm still working to improve minor things but I'm very close to release the new version.

@vasilich6107 you can update the reactive widgets library with the latest changes.

@vasilich6107
Copy link
Contributor

Thanks for the update!

@vasilich6107
Copy link
Contributor

vasilich6107 commented Mar 24, 2021

@joanpablo I tried to use the dev branch for migration
One thing that I'd like to ask is to give more meaningful name for ReactiveFormField<T, K>

Previously there was only T and this was easy to understand - T is a type of value.
In case of multiple generic values - single letters T and K are not very verbose

@joanpablo
Copy link
Owner

joanpablo commented Mar 24, 2021

@joanpablo I tried to use the dev branch for migration
One thing that I'd like to ask is to give more meaningful name for ReactiveFormField<T, K>

Previously there was only T and this was easy to understand - T is a type of value.
In case of multiple generic values - single letters T and K are not very verbose

I'm agree with you, I was planning to explain in the class Doc, but what do you suggest?

Something like:

ReactiveFormField<ModelDataType, ViewDataType>

??

@joanpablo
Copy link
Owner

I have release v10.0.0 with null safety.

You can now test it. Now we are in a better position to continuously improve the package :)

Thanks to all of you.

@joanpablo joanpablo closed this Mar 24, 2021
@vasilich6107
Copy link
Contributor

vasilich6107 commented Mar 25, 2021

@joanpablo I can suggest
TFormControl(instead of T) which describes the type incoming from FormControl and TField(instead of K) which describes the type expected by field

Here is how control_value_accessor will look like - https://tppr.me/kWbVX

@joanpablo
Copy link
Owner

joanpablo commented Mar 25, 2021

@joanpablo I can suggest
TFormControl(instead of T) which describes the type incoming from FormControl and TField(instead of K) which describes the type expected by field

Here is how control_value_accessor will look like - https://tppr.me/kWbVX

I have already released it before your suggestion 😅

@vasilich6107
Copy link
Contributor

If my suggestion is ok - I can make PR with update ;-)

@cedvdb
Copy link

cedvdb commented Mar 26, 2021

do not prefix it both by T, it's not meaningful either. Just add Type. That's my suggestion. Honestly for generic names you don't really care to be a bit too verbose since it's not part of what's imediatly seen in the public API

@joanpablo
Copy link
Owner

Hi @cedvdb @vasilich6107,

I already put ReactiveFormField<ModelDataType, ViewDataType> is not a traditional name but I think it is quite understandable. I will keep that names for now. Thanks for the suggestions :)

@cedvdb
Copy link

cedvdb commented Mar 26, 2021

@joanpablo Those names are fine imho

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.

None yet

7 participants