Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix for https://developers.eveonline.com/blog/article/updates-for-equinox-developers-edition #177

Merged
merged 1 commit into from
Jul 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions staticdump/load.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,16 @@ func FindLastStaticDumpChecksum(client *pester.Client) (string, error) {

switch resp.StatusCode {
case 200, 304:
return string(body), nil
lines := strings.Split(string(body), "\n")
for _, line := range lines {
if strings.Contains(line, "sde.zip") {
parts := strings.Fields(line)
if len(parts) > 0 {
return parts[0], nil
}
}
}
return "", errors.New("Checksum for sde.zip not found")
case 404:
return "", errors.New("Could not find latest static dump checksum (404)")
default:
Expand Down Expand Up @@ -123,14 +132,14 @@ func loadtypes(staticDataPath string) ([]typedb.EveType, error) {
defer r.Close()

var allTypes map[int64]Type
err = loadDataFromZipFile(r, "sde/fsd/typeIDs.yaml", &allTypes)
err = loadDataFromZipFile(r, "fsd/types.yaml", &allTypes)
if err != nil {
return nil, err
}
log.Printf("Loaded %d types", len(allTypes))

var allBlueprints map[int64]Blueprint
err = loadDataFromZipFile(r, "sde/fsd/blueprints.yaml", &allBlueprints)
err = loadDataFromZipFile(r, "fsd/blueprints.yaml", &allBlueprints)
if err != nil {
return nil, err
}
Expand Down
Loading