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

Add wind direction to the API Based Weather Report #744

Open
yanliutafewa opened this issue May 12, 2024 · 3 comments
Open

Add wind direction to the API Based Weather Report #744

yanliutafewa opened this issue May 12, 2024 · 3 comments
Assignees

Comments

@yanliutafewa
Copy link
Contributor

Hi there,

As for the sub project "API Based Weather Report", I think it's a good idea to add "wind direction" to the output. Because the wind direction in the json API response is a degree - like “70” instead of a natural direction - like “ENE”, it also needs to be converted.
Hope I can have the honor to add this.

best,
Yan

@yanliutafewa
Copy link
Contributor Author

Could you please assign this to me @Mrinank-Bhowmick :)

@yanliutafewa
Copy link
Contributor Author

Thank you! @Mrinank-Bhowmick

Best,
Yan

@yanliutafewa
Copy link
Contributor Author

Hi, Team

I improved the functionalities of "API Based Weather Report" by adding features:

  1. Get and present “sunrise time” and “sunset time” for the city. It contains a function to convert the unix timestamp to local time.
  2. Get and present “wind direction”. It contains a function to convert a degree to a direction.
  3. Let user determine whether they want the temperature to be presented in Celsius or Fahrenheit.
  4. Add ‘Country’ to outputs, since some cities have the same name but in different country.
  5. Add output message when the API key is invalid.
  6. Add output message when the city is not found.
    To improve the maintainability for the program, I am also added docstrings and unit test class.

Now, I'm going to create a pull request for my updates.

Best,
Yan

Mrinank-Bhowmick added a commit that referenced this issue Jun 8, 2024
Add features to "API Based Weather Report" - #744
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

No branches or pull requests

1 participant