redislabs-training / ru102py Goto Github PK
View Code? Open in Web Editor NEWThe example project for Redis University's RU102PY course.
Home Page: https://university.redis.com
License: MIT License
The example project for Redis University's RU102PY course.
Home Page: https://university.redis.com
License: MIT License
When using PyCharm as IDE .python-version file prevents me from opening terminal inside IDE with virtual environment activated.
So, I had to delete it.
The Makefile currently requires Python 3.8. Remove this hard requirement (probably also the .python-version
file) and make sure that the environment builds and tests on Python >=3.8 (e.g. try with 3.9/10/11). Will require update to the README file to say what the minimum version of Python required is.
Removing tests for Python version in favour of documenting the minimum required Python version seems to be a better way to go now.
Change the container used in the Docker compose file to be the Redis Stack one, when this has support for ARM... required for Apple M1 processors.
The current code (lines 52-54) sets the new maximum capacity to reading.wh_generated
:
max_capacity = self.redis.hget(key, SiteStats.MAX_CAPACITY)
if not max_capacity or reading.current_capacity > float(max_capacity):
self.redis.hset(key, SiteStats.MAX_CAPACITY, reading.wh_generated)
Instead, line 54 should set it to reading.current_capacity
:
self.redis.hset(key, SiteStats.MAX_CAPACITY, reading.current_capacity)
On lines 53-54:
assert capacity_report_dao.get_rank(readings[0].site_id) == 9
assert capacity_report_dao.get_rank(readings[9].site_id) == 0
should be:
assert capacity_report_dao.get_rank(readings[0].site_id) == 0
assert capacity_report_dao.get_rank(readings[9].site_id) == 9
Add a docker-compose.yml file that uses the RedisTimeSeries Docker container (https://hub.docker.com/r/redislabs/redistimeseries), and configure Redis in that container to persist data to a local folder named "redisdata". Here's an example file from another project that works like this (this one uses the redismod container but it's the same idea): https://github.com/redislabs-training/node-js-crash-course/blob/main/docker-compose.yml
This is part of our participation in Hacktoberfest 2021. Learn how to complete this issue here: https://developer.redis.com/hacktoberfest/
Need help or want to talk to us? Join us on Discord where we have a dedicated Hacktoberfest channel: https://discord.gg/ueQwKUh5Z3
Update the README file to show how to get RedisInsight which is optional but recommended for this course.
Update README.md
to add a screenshot of the running application, showing the map view with the solar site markers on it. For this you will need to follow the instructions in the README to get the application running. The code to generate the markers is stubbed out on the master
branch in this repo as it's an exercise for the training course that this repo is part of. To get the markers to draw so that you can take your screenshot, temporarily paste in the code from the solutions
branch here:
ru102py/redisolar/dao/redis/site.py
Line 37 in dcdf319
This is part of our participation in Hacktoberfest 2021. Learn how to complete this issue here: https://developer.redis.com/hacktoberfest/
Need help or want to talk to us? Join us on Discord where we have a dedicated Hacktoberfest channel: https://discord.gg/ueQwKUh5Z3
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.