cybre-finn / next-companion

Rogue client for nextbike
GNU General Public License v3.0
23 stars 8 forks source link

[WIP] Change HTTP-Client to Retrofit & JSON-Parser to Jackson #20

Closed lgehr closed 2 years ago

lgehr commented 4 years ago

With these patches one can see what I had in mind regarding #19.

For some reason login is broken ATM, will try to fix later. (These patches also add some logging which makes it a lot easier to debug, hopefully :D )

lgehr commented 4 years ago

Login now works as intended.

lgehr commented 4 years ago

I think LoginActivity should be a normal task now and not Async. Having the Call Async should probably be enough?!

cybre-finn commented 3 years ago

Hi @lgehr, can you give me an update, are you still working on this? :thinking:

lgehr commented 3 years ago

Am 19. Oktober 2020 15:51:03 MESZ schrieb h0chi notifications@github.com:

Hi @lgehr, can you give me an update, are you still working on this? :thinking:

Hey, Sorry for not replying for so long. I'm currently very busy. I think I will have time for this project in the last week of October if that's OK for you!

Regards!

lgehr commented 3 years ago

Just commited some things to resolve your commands above.

* Your branch wont build on my setup. It fails at linting. The suggested hotfix was to disable linting in build.gradle.

Mhm that's strange. It worked for me the way it is. Maybe we should provide a .editorconfig (https://editorconfig.org/) to have the same styling. Will also look into AStudio linting settings.

* Some of my api code is still in place (e.g. list of rentals). Is this still todo or is there any difficulty, or not in intended to be in this PR... ?

Yes I only did login to wait for your feedback. I am now working on the rental part so we can delete your api code and merge :)

What do you think about making loginActivitya normal task? (not async)

Regards

lgehr commented 3 years ago

Sorry again that this is taking so long. I'm not so experienced...

I'm currently having a problem understanding the how the Activity Lifecycle interacts with Threads. Currently the getOpenRentals is implemented in the onTaskComplete. Could you maybe explain when onTaskComplete is fired in the Lifecycle? Or point me to the documentation? What happends with the thread we start in on Activity and then change the Activity while the tread is still running? Will the thread continue to run and how are the callbacks run when the activity is onPause()? Will the Activity enqueue an new Call everytime when it is onResume?

cybre-finn commented 3 years ago

I just started to review your code again. If you plan to commit more, please inform me asap and I'll block some time for the next weekend. Jitsi call is a good idea. If you do not intend commit more, we can do it today, right after my review, if you have the time.

Sorry again that this is taking so long. I'm not so experienced...

Nevermind. Neither am I. You're doing (probably) unpaid free software coding. That alone is pretty gracious, so no one is hurrying you.

lgehr commented 3 years ago

TODOs for this PR are:

After this we can merge. For me next weekend would be best to make a jitiscall and write the last commits.

cybre-finn commented 3 years ago

@lgehr just mail me your preferred date and time for jitsi conference hochi [ät zer.one

I just dropped the review due to a lot of TODOs and also stuff I just don't get b/c I'm not at all involved with the libraries you use. Would be better we get into this together.