Giter Site home page Giter Site logo

insiderinsight's Introduction

Insider Insight Official Documentation

Welcome to the official documentation for Insider Insight.

Documentation

For detailed information and component references, visit the Daisy UI Documentation.

Demo

To see Daisy UI in action, check out our live demo.

landing lists

signup

Profit

Repository Branches

  • Rails 7 + esbuild (Main Branch): The current stable version.
  • Rails 6 + webpacker: For those using older versions of Rails, you can find it here.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

Before you begin, ensure you have the following installed:

  • Ruby (version specified in .ruby-version)
  • Rails (compatible with Rails 6 and Rails 7)
  • Yarn
  • Node.js

Installation

Follow these steps to set up the project locally:

# Clone the repository
git clone https://github.com/evolshenanigans/insiderinsight.git
cd insiderinsight

# Install dependencies
bundle install
yarn install

# Set up the database
rails db:create
rails db:migrate

# Start the development server
./bin/dev

Running the Scraper

The scraper fetches information about government officials' trades and stores the data in CSV files. These files can then be uploaded to your personal database.

Prerequisites

Ensure you have Ruby installed along with the following gems: puppeteer, nokogiri, csv, date, and pg.

Steps to Run the Scraper

  1. Navigate to the directory containing the scraper script.
  2. Run the scraper script:
    ruby scraper.rb
  3. After the scraper completes, three CSV files (officials.csv, stocks.csv, trades.csv) will be created in the current directory.

Uploading to Database

To upload the data from CSV files to your PostgreSQL database:

  1. Ensure your PostgreSQL credentials and database details are correctly configured in the script.
  2. Use the copy_csv_to_database method in the script, specifying the path to each CSV file and the corresponding database table.

Common Issues

Issue: wrong ruby version

  • Solution: the current version of this project only supports up to ruby 3.2.1.

Issue: Scraper fails to fetch data due to a change in the website's HTML structure.

  • Solution: Check if the website's structure has changed and adjust the CSS selectors in the script accordingly.

Issue: Database connection errors.

  • Solution: Verify that your PostgreSQL credentials and database details are correct. Ensure your PostgreSQL service is running.

FAQ

Q: What versions of Rails does Daisy UI support? A: Daisy UI supports Rails 6 and Rails 7. Please switch to the appropriate branch as per your Rails version requirement.

Q: Where can I find component examples? A: You can find examples and usage guidelines on the Daisy UI Documentation site and in the demo application.

Troubleshooting

Issue: Styles are not applying correctly.

  • Solution: Ensure Tailwind CSS is correctly installed and imported into your project. Check your tailwind.config.js and ensure it's configured properly.

Issue: Getting a database error during setup.

  • Solution: Make sure you've created the database with rails db:create before running migrations. Also, verify your database configuration in config/database.yml.

insiderinsight's People

Contributors

evolshenanigans avatar

Watchers

 avatar

insiderinsight's Issues

sign up and sign in issues

Sign up and forgot password layout seems to use simple forms and is inconsistent with sign in
Sign up currently doesn't seem to work
Same as sign in where it works fine in production, just not development

design problems

  1. Windows for parallax on home page broken on large windows size (full screen on 13' MacBook)
    2.Sidebar options seems redundant with options shown on navbar on fullscreen (i.e. About and Sources)
    3.Bell icon and search icon on top navbar doesn't do anything
    4."About" options in navbars lead to Daisy UI page, wording seems misleading since you'd expect it to be something about your application, not the web design philosophy you designed this around
    5.Home screen has image of burning government building, reminiscent of January 6th, I don't know if that's the vibe you want to convey
    6.Using dev tools to view in mobile size breaks layout as bell and search icons remain on right and push rest of view off weirdly
    7.Login page layout also broken when on fullscreen size
    8.When trying to log in as a user that's not currently existent, there's no indication that there was something wrong with email or password, just refreshes the login screen without information on what went wrong
    This seems to work fine in production with a flash message, but not in development for whatever reason
    9.Top navbar options that you see on fullscreen mostly disappear when you reduce screen size (i.e. Home, Portfolio, About, Source)
    10.Transaction Type on officials details should be capitalized or upcased to keep consistent with rest of formatting on screen
    11.Officials layout could be a little bit cleaner, photos sometimes stretched horizontally to keep within circle (example I saw this occurring is Mark Green)

scraper issue

Running ruby lib/scrapers/officials_scraper.rb doesn't work in codespaces, requires chrome installed on system?
All officials listed underneath home page? Is that the best place to keep your officials list, or should there be a separate page for this?

home page redesign

Home page says "Interested? Click Below" but there's nothing to click (if you
have not ran the scraper task)

README issue

If README has steps on starting the app on different development environment, should probably also include step after yarn install to db:migrate

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.