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: trigger bug fixes #36

Merged
merged 5 commits into from
Nov 15, 2022
Merged

fix: trigger bug fixes #36

merged 5 commits into from
Nov 15, 2022

Conversation

ronenkapelian
Copy link
Contributor

@ronenkapelian ronenkapelian commented Nov 9, 2022

Question Answer
Bug fix
New feature
Breaking change
Deprecations
Documentation
Tests added
Chore

updating logic for returning callbacks on case of existing (naive cache)
scenarios:

Send GPKG request

1.No job is in progress with those parameters - create new

2.Job is In progress - return “In Progress“

3.Job completed not cleaned return callback response

4.Job completed - cleaned - same as “a”


Bug fixes:

  1. Fix sanitized bbox calculation - new version from mc-utils
  2. Fix adding new callbacks to cllbacks array (for different url's or BBOX)
  3. Fix return of callback when job is completed

@ronenkapelian ronenkapelian self-assigned this Nov 9, 2022
@ronenkapelian ronenkapelian marked this pull request as ready for review November 10, 2022 15:57
@asafMasa asafMasa changed the title Is cleaned validation fix: trigger bug fixes Nov 13, 2022
const jobCreated = await this.jobManagerClient.create(workerInput);
return jobCreated;
} else if (duplicationExist.status === OperationStatus.COMPLETED) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i would have written
if (duplicationExist && duplicationExist.status === OperationStatus.COMPLETED) { // for completed
const completeResponseData = duplicationExist as ICallbackResponse;
completeResponseData.bbox = bbox;
return duplicationExist;
} else if (duplicationExist) { // for in progress
return duplicationExist;
}

// else rest of the code (not duplicationExist) without an if
const batches: ITileRange[] = [];
for (let i = 0; i <= zoomLevel; i++) {
...
...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

src/index.ts Show resolved Hide resolved
return duplicationExist;
} else if (duplicationExist) {
return duplicationExist;
} else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you don't need the "else { " condition - remove it as it's obvious

@ronenkapelian ronenkapelian merged commit b035fe2 into master Nov 15, 2022
@ronenkapelian ronenkapelian deleted the is-cleaned-validation branch November 15, 2022 06:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants