2024-01-29 Forthic Office Hours
Resources
Forthic OH Signup: https://calendly.com/forthix/forthic-users-office-hours
Date
Jan 29, 2024
Questions
Q: At LinkedIn, my report stopped running. What can I do?
A report may fail to run for a number of reasons:
An edit introduced a bug into the report
Something the report depended on has changed (expired token, external service is down)
The data has changed in an unexpected way that the report wasn’t prepared to handle
The job runner is failing
Scientific Method + Binary Search
To troubleshoot this, we want to pose a hypothesis that cuts the search space in half. For instance, we can guess that the problem is in the report and not in the job runner. To test this hypothesis, we need to run the report locally.
This can be a bit tedious to set up because it requires you to set up SSH keys and then copy them into the right systems and then check that everything is working, etc. One way around this is to just download the Forthic app sources instead of trying to check them out with git. Here’s how to do it:
Go to go/forthic-apps (if you aren’t signed in, you may need to go to
go/forthic-apps
again after you sign in)Click on the link with the zip file download for the repo
Unzip this on your computer
Open up a terminal and
cd
into the unzipped directoryType
make
and wait until you see a message like “Running on http://localhost:5000”Go to
http://localhost:5000
. If you see “Howdy”, then things are running!
Running the report
The URL pattern for your local server matches the file directory structure in the Forthic apps directory. For instance, if you have an app in user/rjose/global-tickets
, you can run this by going to http://localhost:5000/user/rjose/global-tickets
The first time you run the report, you will need to specify Jira and Google token info. There’s a file with this information called “Forthic App Secrets”. Ask someone on the #forthic-users
Slack channel if they can share this with you. After you enter this information, you’ll be ready to go.
Running a report from ratchet locally
If you want to run a report from ratchet on your computer, do the following:
Create a subdirectory under
forthic-apps
with the same pattern as the other apps. One convention I like to use is to name the new app the ID of your one-of appIn your directory, create an empty
main.forthic
fileGo to your one-of admin page and copy the code from the top section into your
main.forthic
fileRun your app locally as above
Back to the Scientific Method
If you were able to run your app locally, then the problem is in the job runner. Unfortunately, you’ll need to ask a LinkedIn engineer on the team that owns ratchet to help you proceed.
If your app didn’t run locally, then you can pose a new hypothesis that splits the search space in half. Proceed this way until your hypothesis is correct and you have found the problem.