Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@xyluo25
Copy link

@xyluo25 xyluo25 commented Feb 2, 2024

Hi Developers,

I have updated the old code to a new version, utilizing Python 3.10 to refactor it. I have rectified several errors, added type hints to functions, and included docstrings for functions.

bests,
Xiangyong

@martinfleis
Copy link
Member

I'll let maintainers to respond to this, just wanted to flag that some changes here go against the subpackage template we use within PySAL and moving tests outside of mgwr will break reverse dependency testing set up in upstream.

@xyluo25
Copy link
Author

xyluo25 commented Feb 2, 2024

I'll let maintainers to respond to this, just wanted to flag that some changes here go against the subpackage template we use within PySAL and moving tests outside of mgwr will break reverse dependency testing set up in upstream.

Hi Martin, thank you for your fast response. I will move tests back to mgwr to avoid further conflicts.

@Ziqi-Li
Copy link
Member

Ziqi-Li commented Feb 2, 2024

@martinfleis Hi Martin, do we have some central guideline on supporting python version regarding its life cycle?

@martinfleis
Copy link
Member

@Ziqi-Li Both Python versions and dependencies shall follow SPEC0. Python 3.10 is the minimum at this moment.

@xyluo25
Copy link
Author

xyluo25 commented Feb 2, 2024

@Ziqi-Li @martinfleis Please find the attached file:change_log_xy.pdf for your reference.
change_log_xy.pdf

@Ziqi-Li
Copy link
Member

Ziqi-Li commented Feb 8, 2024

Hi @xyluo25 your tests are failed, can you make sure they pass so that we can have a closer look? Also please make sure that all the changes you proposed are essential, as we may want to have minimum changes to the code base. We can always have minor updates afterwards.

@xyluo25
Copy link
Author

xyluo25 commented Feb 8, 2024

Hi @xyluo25 your tests are failed, can you make sure they pass so that we can have a closer look? Also please make sure that all the changes you proposed are essential, as we may want to have minimum changes to the code base. We can always have minor updates afterwards.

Dear Ziqi, thank you for your prompt response and i will uopdate the code to pass the unittest soon.

@martinfleis
Copy link
Member

Hey, I am afraid that this PR is not reviewable in its current form. It is simply too large and opaque. Every time you contribute to an open source project like mgwr, it is much better to open an issue to discuss the changes and agree on the way to tackle them before opening a pull request. We could've guided you before you spent a large amount of time to do a single massive PR.

The issue with this is that it changes way too many things at the same time. If you look at the history of pull requests, they always focus on a single atomic change. Here, you do many things and it makes it extremely challenging to review it. From what I understand you:

  • format the code using black or some other formatter
  • lint using ruff or something similar - as a result there are implementation changes
  • add some docstrings or change existing while changing their formatting and structure - the latter is a big no as it breaks the convention
  • add some type hints
  • update sphinx configuration
  • move or otherwise change test files
  • update readthedocs.yml
  • update documentation
  • bump Python support

And possibly something else. Every single of these points should be a Pull Request and for every single one there should be an issue and a discussion where maintainers agree what should be done and how.

And every single of these changes should pass CI checks. As you can see, your changes are changing the values produced by MGWR which cannot happen.

@Ziqi-Li
Copy link
Member

Ziqi-Li commented Feb 11, 2024

Thanks @martinfleis for the detailed suggestions.

@xyluo25, I second what @martinfleis says. Maybe you can focus your first task/PR on solely python 3.10 support, and then update other things successively. Your current PR is too big and extensive. Could you also make sure every time your CI tests work on your own fork before pushing a new commit to this PR.

@xyluo25
Copy link
Author

xyluo25 commented Feb 11, 2024

Thanks @martinfleis for the detailed suggestions.

@xyluo25, I second what @martinfleis says. Maybe you can focus your first task/PR on solely python 3.10 support, and then update other things successively. Your current PR is too big and extensive. Could you also make sure every time your CI tests work on your own fork before pushing a new commit to this PR.

@martinfleis @Ziqi-Li
Hello Marin and Ziqi,

Thank you both for your insightful feedback. Based on your suggestions, I will ensure to initiate a separate Pull Request (PR) for each issue. As advised, "Each point will be addressed in its own Pull Request, accompanied by a corresponding issue and a discussion where maintainers can agree on the proposed actions and methodologies." Additionally, I will ensure that all new PRs pass the CI tests successfully.

Moreover, I plan to prioritize updating our project to Python 3.10 before proceeding with other advanced implementations.

Warm regards,
Xiangyong Roy Luo

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