Coder Social home page Coder Social logo

tempy's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

tempy's Issues

[FEATURE]: Add default settings support for tempy

Relates to #6

tempy should support the ability to specify default settings (i.e. location and system of measurement).

I'd like to use tempyrc for this. Right now, the Config class checks tempyrc for a user-provided API key. We'll need to expand the logic in the Config class to parse out each config option.

I suppose we should also add command line options for tempy to automatically update the config so the user doesn't have to go into tempyrc each time they want to make an update.

[REQUEST] Add weather alerts to tempy

Weather alerts would be a nice addition for tempy. Open to ideas on what something like that might look like (e.g. customization options, positioning, options to enable/disable)...

Update README.md

  • Incorrect instructions on where to store a user's personal API key
  • Update demo screenshot (currently represents an outdated version of tempy; a bug is visible in the lower left forecast panel.
  • General cleanup for succintness

[FEATURE] Add support for Windows users

Issue brought to my attention per #24

There's a bit of housecleaning to be done to make tempy compatible on Windows. Here's what I'm immediately aware of.

  • tempy does not look in valid Windows directories for a tempyrc config file.
    • Added support for nt os types. The config module now differentiates between nt and posix os names. If nt, we look at C:/Users/<username>/AppData/Roaming/tempyrc for a config.
  • Generate windows compatible strftime wherever it's needed.
    • This is what the user in #24 was having problems with. See the error they posted for details. Haven't had time to research anything, but it looks like strftime might work differently between Windows and Linux systems.

Invalid format string

Installed v1.0.9 via pip install git+https://github.com/noprobelm/tempy. Getting an invalid format string error:

$ tempy new york city
Traceback (most recent call last):
  File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "C:\Users\User\AppData\Local\Programs\Python\Python310\Scripts\tempy.exe\__main__.py", line 7, in <module>
  File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\tempy\__main__.py", line 8, in main
    renderable = Report(config)
  File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\tempy\weather.py", line 69, in __init__
    self.data = Data(config["location"], config["api_key"])
  File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\tempy\data.py", line 34, in __init__
    ).strftime("%A, %B %-d | %H:%M"),
ValueError: Invalid format string

Python 3.10 and Windows 10

Suggestion of improvements

In the beginning, I will appreciate your job.

There is no information about the contribution so I write Issue.

At first, cloning using ssh requires permission to repository. So instead of

git clone [email protected]:noprobelm/tempy.git && cd tempy

there should be

git clone https://github.com/noprobelm/tempy.git

But pip allows installing directly from the git repository

so there is no need to clone, one could just call:

pip install git+https://github.com/noprobelm/tempy

It will be also nice if the configuration file will allow defining default locations and units.

Thanks for a really nice package.

Local time is incorrect most of the time

The data module is using the localtime epoch to determine dtg information for the timing report, but we're not supplying the timestamp conversion with any timezone data. Current time readout is incorrect most of the time.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.