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

Make one request when creating initial tiles for resources #1564

Open
jacobtylerwalls opened this issue Mar 25, 2024 · 0 comments
Open

Make one request when creating initial tiles for resources #1564

jacobtylerwalls opened this issue Mar 25, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@jacobtylerwalls
Copy link
Member

The project name step creates two tiles, and issues requests to the tile API serially. After archesproject/arches#10662, one of the tiles will be saved with a context of "resource created", but not the other, because we sent two requests. This has the potential to be confusing later, because all but one will appear in the edit log stream.

Suggesting a refactor to issue one request (if the tile API can't do this, then use the resource API, or something?)

return self.saveTile(nameTileData, nameNodeGroupId, self.projectResourceId(), nameTileId())
.then(function(data) {
nameTileId(data.tileid);
self.projectResourceId(data.resourceinstance_id);
return self.saveTile(typeTileData, typeNodeGroupId, data.resourceinstance_id, typeTileId());
})

@chiatt chiatt moved this to 🔖 Ready in afs-pipeline Mar 27, 2024
@chiatt chiatt added the bug Something isn't working label Jul 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 🔖 Ready
Development

No branches or pull requests

2 participants