question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Torque layer dependencies not correctly registered

See original GitHub issue

Context

Due to a confusion with the meaning of Layer.data_layer and Map.data_layers (they are not the same), there are a bunch of pieces of code that are incorrect. This ticket illustrates one of them.

Steps to Reproduce

  1. Create a map
  2. Add a torque layer on dataset P
  3. Add a join analysis to the torque layer, with dataset Q
  4. Try to delete dataset Q

Current Result

You are not warned of a dependency with the map .

Expected result

You should be warned.

Additional info

The problem is that Carto::Map.update_dataset_dependencies calls data_layers which does not include torque layers. This mistake is repeated throughout the code (I’m thinking that the layer node style cache might also be affected).

My suggestion here would be to bite the bullet, and instead of fixing this specific issue (it’s as easy as changing data_layers to carto_and_torque_layers), changing the behaviour of data_layers so it behaves consistently with Layer.data_layer?.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
javitoninocommented, Feb 16, 2017

This is the current status of the layer kind methods:

                  | Map models                   | Layer models
base              | all                          | tiled/bg/google/wms
data              | carto                        | carto/torque
user              | tiled/bg/google/wms          | tiled/bg/google/wms
carto_and_torque  | carto/torque                 | N/A
torque            | torque                       | torque
other             | torque                       | N/A
named_map         | carto/tiled/bg/google/wms    | carto/tiled/bg/google/wms
basemap           | N/A                          | tiled/google

My proposal is to standardize so:

base              | tiled/bg/google/wms
data              | carto/torque
user              | *Remove*
carto_and_torque  | *Remove*
torque            | torque
other             | *Remove*
named_map         | carto/tiled/bg/google/wms
basemap           | tiled/google

Alternatively, we could just fix the bug. Looking at how costly would be to change this.

0reactions
javitoninocommented, Feb 16, 2017

For sure. I forgot about visualization model until I started implementing this. I created the follow up issue here: https://github.com/CartoDB/cartodb/issues/11553 and reflected the need to update the visualization models as well.

Read more comments on GitHub >

github_iconTop Results From Across the Web

TORQUE Resource Manager - Adaptive
Welcome to the TORQUE Administrator Guide, version 4.2.6. This guide is intended as a reference for both users and system administrators. Note: Advanced...
Read more >
Dependence of spin-orbit torque effective fields on ... - Nature
In this work, we report on the dependence of the SOT effective fields on the magnetization uniformity in the wires comprising of Ta/Co/Pt...
Read more >
Interfacial spin–orbit torques - AIP Publishing - Scitation
Spin–orbit torques offer a promising mechanism for electrically controlling magnetization dynamics in nanoscale heterostructures. While spin–orbit torques ...
Read more >
Using layers with your Lambda function - AWS Documentation
Configuring functions to use layers. You can add up to five layers to a Lambda function. The total unzipped size of the function...
Read more >
Diverse high-torque bacterial flagellar motors assemble wider ...
However, the molecular mechanism by which different motors might produce different torques has not been investigated.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found