Remove the email pipeline
The mailbox sync (Microsoft Graph and IMAP), its Claude classifier, the /email routes and the Settings page's email section are taken out while the pipeline is unused. The last commit with it is tagged email-pipeline-last; reverting this commit brings it back. The status rules the capture path shares (statusOrder, StatusAdvances, NormalizeStatus) move to job_status.go with their tests. ProcessedEmail stays in the migration, marked dormant, so its history survives for a restored pipeline. golang.org/x/oauth2 is no longer needed. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
@@ -17,8 +17,8 @@ import (
|
||||
// CreateJobApplication is the resolver for the createJobApplication field.
|
||||
func (r *mutationResolver) CreateJobApplication(ctx context.Context, input model.CreateJobApplicationInput) (*models.JobApplication, error) {
|
||||
// String! is non-null but not non-empty, and the columns are only
|
||||
// `not null`, so "" stores happily and then never matches the email
|
||||
// pipeline's LOWER(company) lookup — an orphan row no sync can advance.
|
||||
// `not null`, so "" stores happily and then never matches the capture
|
||||
// upsert's LOWER(company) lookup — an orphan row no capture can find.
|
||||
jobTitle := strings.TrimSpace(input.JobTitle)
|
||||
company := strings.TrimSpace(input.Company)
|
||||
if jobTitle == "" || company == "" {
|
||||
@@ -98,8 +98,7 @@ func (r *mutationResolver) DeleteJobApplication(ctx context.Context, id int) (bo
|
||||
// the tracker a row was gone when it had never existed. The return type
|
||||
// stays Boolean! for the front end's sake, so the only value is true.
|
||||
//
|
||||
// Soft delete: the row is kept, which is what lets the email pipeline see
|
||||
// that an application was deleted and not re-create it.
|
||||
// Soft delete: the row is kept with deleted_at set, not purged.
|
||||
var app models.JobApplication
|
||||
if err := r.Store.DB.First(&app, id).Error; err != nil {
|
||||
return false, err
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
# Job application tracker. Rows come from these mutations, automatically from
|
||||
# the email sync pipeline (internal/services/email_sync.go), from the browser
|
||||
# Job application tracker. Rows come from these mutations, from the browser
|
||||
# capture userscript (internal/handlers/handle_job_capture.go), or from
|
||||
# promoting a lead (job_lead.graphql). These are private data, so the queries
|
||||
# here are @admin as well as the mutations.
|
||||
@@ -7,10 +6,10 @@
|
||||
# description is the captured posting text. It can run to tens of kilobytes,
|
||||
# so the tracker's list query leaves it out and asks for it per row.
|
||||
|
||||
# The lifecycle of an application, in the order the email pipeline and the
|
||||
# capture endpoint are allowed to advance it. The values are lowercase on
|
||||
# purpose: they are exactly the strings stored in the status column and ranked
|
||||
# in services.statusOrder (internal/services/email_sync.go), and a test there
|
||||
# The lifecycle of an application, in the order the capture endpoint is
|
||||
# allowed to advance it. The values are lowercase on purpose: they are exactly
|
||||
# the strings stored in the status column and ranked in services.statusOrder
|
||||
# (internal/services/job_status.go), and a test there
|
||||
# fails if this list and that map ever differ. Adding a status means adding
|
||||
# it in both places, and to the tracker page and the capture userscript.
|
||||
#
|
||||
|
||||
Reference in New Issue
Block a user