GSA / code-gov-api

API powering the code.gov source code harvester
http://code.gov
Other
53 stars 28 forks source link

Website issue report for code.gov - Walkoff project link returning 404 #284

Closed froi closed 5 years ago

froi commented 5 years ago

The following bug report was sent to us via code@gsa.gov:

I was browsing code.gov and ran into a minor error that might be useful to know about

Summary: code.gov homepage has a 404 in the walkoff project link. Impact: Small - users visiting the home page will not see details of a featured project - the link to the repo still works.

Details: when opening https://code.gov then scrolling down to featured project walkoff then clicking "view project" then it opens url https://code.gov/#!/explore-code/agencies/NSA/repos/nsa_walkoff

Expected: we would see project info on the walkoff project Actual:

Recommendation: This error would be hidden from many standard link checkers and site monitors because the error is only presented in javascript and the site renders but with no contextually relevant content - only a human or a link checker that checks for javascript errors would discover it. Therefore, 1) Periodically run a link checker on the site that inspects javascript errors - or periodically run your end-to-end test suite, if one is available. 2) Present an error with more detail to the user when javascript encounters this condition. 3) Monitor for similar kinds errors by monitoring browser javascript errors.

Browser was: Chrome Version 69.0.3497.100 (Official Build) (64-bit) Region was: conus west Time was: 08:49:07 UTC Tuesday, October 23, 2018

froi commented 5 years ago

This issue has been resolved. The problem was on the harvester side.

The NSA file that was being used was incomplete and the official remote code.json was changed from where it was being hosted. A couple of changes were made to help us react quicker to these changes. Primarily the use of a remote datasources file. You can read about this feature here.

Below are screenshots of the project showing up in our production instance for Code.gov and api.code.gov:

Code.gov:

URL: https://code.gov/#!/explore-code/agencies/NSA/repos/nsa_walkoff

image

api.code.gov

URL: https://api.code.gov/repos/nsa_walkoff?api_key=DEMO_KEY

image