Coder Social home page Coder Social logo

amtrak's Introduction

Hey There!

About Me:

Hi! My name is Piero and I am a programmer based in Chicago (originally from Atlanta)! I have been putting this one off for a while, but I should have my readme complete soon!

amtrak's People

Contributors

piemadd avatar

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

Watchers

 avatar  avatar  avatar  avatar  avatar

amtrak's Issues

Consider normalizing object to be the same shape regardless of endpoint

first off: nice job, thank you for making this data way more accessible! I understand part of this issue is likely from just how amtrak is making the data available.

Viewing train from /trains/{number} endpoint

notice estArr, estDep included.

2022-04-22_05-06

Viewing train from /stations/{code} endpoint

notice estArr, estDep not included

2022-04-22_05-05

It would be nice if in the /stations/{code} endpoint, the shape was the same.

My use case

Simply get my train and see when it's Amtrak-reported estimated arrival is. Not sure how to query that robustly yet. The /trains endpoint has the nice info but I'd likely have filter by station/date in some (totally possible) way.

deeper use case: omg I love amtrak but the chicago bound train is scheduled to slide through at 3:20am and is usually 1 to 5 hours late. Gotta pipe this data into a cron script that tells Twilio to spam my phone an hour before the train is about to arrive so that I can get the maximum amount of sleep. Open for collab on that :)

MagicMirror Module

First of all, thank you so much for making an accessible and clean method for accessing the Amtrak API! This is a public good, kudos.

Would you be interested in developing a MagicMirror module that displays this data on a map? I know the community would really appreciate it and I personally will do what I can to test and contribute.

https://github.com/MichMich/MagicMirror

Thanks again!

anyway to get all trains schedule for the day for a particular route ?

I am try to find all trains scheduled for a day (they may not be active yet) for a particular route. From the API it seems it only fetches active/soon to be active trains.
Ideally looking for output (in json format) similar to what you get when you search with starting/ending station and date on amtrak website.

Security issue on dependency

From your example: https://replit.com/@piemadd/Amtrakjs-Example

                                                                                
┌──────────────────────────────────────────────────────────────────────────────┐
│                                Manual Review                                 │
│            Some vulnerabilities require your attention to resolve            │
│                                                                              │
│         Visit https://go.npm.me/audit-guide for additional guidance          │
└──────────────────────────────────────────────────────────────────────────────┘
┌───────────────┬──────────────────────────────────────────────────────────────┐
│ High          │ Regular Expression Denial of Service in minimatch            │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Package       │ minimatch                                                    │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Patched in    │ >=3.0.2                                                      │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Dependency of │ amtrak                                                       │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Path          │ amtrak > isdst > tap > glob > minimatch                      │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ More info     │ https://github.com/advisories/GHSA-hxm2-r34f-qmc5            │
└───────────────┴──────────────────────────────────────────────────────────────┘
┌───────────────┬──────────────────────────────────────────────────────────────┐
│ Critical      │ Incorrect Handling of Non-Boolean Comparisons During         │
│               │ Minification in uglify-js                                    │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Package       │ uglify-js                                                    │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Patched in    │ >=2.4.24                                                     │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Dependency of │ amtrak                                                       │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Path          │ amtrak > isdst > tap > runforcover > bunker > burrito >      │
│               │ uglify-js                                                    │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ More info     │ https://github.com/advisories/GHSA-34r7-q49f-h37c            │
└───────────────┴──────────────────────────────────────────────────────────────┘
┌───────────────┬──────────────────────────────────────────────────────────────┐
│ High          │ Regular Expression Denial of Service in uglify-js            │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Package       │ uglify-js                                                    │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Patched in    │ >=2.6.0                                                      │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Dependency of │ amtrak                                                       │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ Path          │ amtrak > isdst > tap > runforcover > bunker > burrito >      │
│               │ uglify-js                                                    │
├───────────────┼──────────────────────────────────────────────────────────────┤
│ More info     │ https://github.com/advisories/GHSA-c9f4-xj24-8jqx            │
└───────────────┴──────────────────────────────────────────────────────────────┘
found 3 vulnerabilities (2 high, 1 critical) in 37 scanned packages
  3 vulnerabilities require manual review. See the full report for details.

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.