Git Product home page Git Product logo

nfl-pickem-legacy's Introduction

go_nfl

NOTE: This is my first attempt at making the NFL pickem' pool. It's a completely server side application. I have abandoned maintaining this version of the application in favor of splitting the app into a RESTful API and a completely independent front end. Since the architecture is completely distinct, and the git history is not relevant any more to the new version, I have decided to split the respositories rather than maintain a legacy branch. www.github.com/ameske/nfl-pickem will refer to the new version of the application.

A customized NFL Pick-Em Pool manager written in Go.

There weren't any pick-em managers that gave the ability to set up customized scoring. This is an automated pick-em-pool application that uses our scoring system.

The system works as follows:

  1. Each week, pick the winners of all of the games.
  2. Next, assign point values to the games. You have one 7 point game, two 5 point games, and five 3 point games based on the number of byes in a week. The remainder of the games are worth only one point.

There is currently support for:

  • Login/Logout and session management
  • Admin picks management page (set/correct/update individual picks for all users for a given week)
  • Automatic importing of game scores after each "wave" of games completes
  • Automatic grading of picks after each "wave" of games completes
  • Dynamically generated results page for each week
  • Dynamically generated standings page for each week
  • Dynamically generated picks form based on the current NFL week and whether games have already started or not
  • E-mail notifications to users when picks are submitted/modified
  • CLI app for manually managing score imports and grading

nfl-pickem-legacy's People

Contributors

ameske avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar

nfl-pickem-legacy's Issues

Admin scripts must be run manually

Currently, scraping for results, loading the results into the database, and grading the previous week's picks must all be run manually. It would be ideal if the application was set-up to automatically handle those tasks. (Or to create cron tasks and an install script for the user)

Remove dependency on gorp

Gorp is a fantastic library, but I'd like to eliminate as many 3rd party dependencies as I can and try to do things with just the std lib.

Standings table on the home page updates incorrectly w/ live updating

The standings table on the front page is a direct query on the backing data. This causes issues when live updating results, as it thinks the week is "over" and incorrectly reports the standings. In this type of pool, a week isn't meaningful until it is over. There needs to be some logic to show the previous week, (and don't forget to protect the edge case of week 1), instead of the current "at this moment" standings.

Season setup game scraping script does not store timezone for games

The python script that scrapes the NFL's website and extracts the games for a season does not store the timestamps with timezone information. This causes headaches when trying to calculate whether or not a game has already started and cannot be picked. Currently, this is worked around in the app, but it would be ideal for future years to store the timezone correctly

Generate test weeks and results for offseason testing

There needs to be a way to create test weeks for offseason testing. This is probably a combined effort with a generation tool, changes to the code to accept more parameters to give me control of testing, and some template changes.

Standings calculation incorrect in week is in progress

If a week is in progress, the standings calculation takes it into account as an actual finished week score, causing the current week to be counted as the lowest week and dropped. While this isn't technically inaccurate, it's rather misleading until more games have been completed.

Standings cannot correctly calculate points if a week has no correct games

Currently, if a user does not submit any picks for a given week all games are marked as "incorrect". This in of itself is not a problem, however the method for calculating the lowest week in the SQL query cannot account for this. Due to the week not having any correct picks, a row is not generated by the query representing that week. MIN should be the empty week, however it becomes another non-empty week. I think I can fix this by adjusting the SQL query to preserve the 0 point weeks.

Application crashes during the offseason

It's really tough to work on the application when the NFL season is not current as the app will crash trying to figure out the current week/year. The main landing pages need to be able to detect we're not in a season and display a message rather than just crash.

Picks form incorrectly locking out users from making picks

The picks form contains logic to lock the form elements based on whether or not the game has started; however, there's a bug in my logic somewhere. I can't remember the behavior that I saw, so this is currently just a note to double check that block of code.

Update code to use new helper functions

A few helper functions were created to reduce code duplication and clean up the handlers in the v0.1-beta release. Not all helper functions were modified to use these functions.

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.