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.

History: Prevent polluting history

See original GitHub issue

Feature Description

Currently, history is polluted for example by props that are added async in the background. Such props are for example:

  'resource.baseColor',
  'resource.isMuted',
  'resource.poster',
  'resource.posterId',

There might be more. In #9822, logic is put in place to allow excluding properties from creating separate history entries. Once we have both that and #9577 merged, we should have everything in place to not pollute history anymore.

Alternatives Considered

Additional Context

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7

github_iconTop GitHub Comments

2reactions
miinacommented, Jan 18, 2022

Adding these values to be ignored means that the values will be ignored only if only that value changes, if the change is included in a larger change, the value will still be saved. E.g. if only isMuted changes, it won’t cause a separate history entry, however, if isMuted is included within other changes, it will still be saved.

Some testing showed that adding the following to the ignore list don’t seem to cause issues:

  'resource.baseColor',
  'resource.id',
  'resource.isMuted',
  'resource.posterId',
  'resource.poster,'

If I understand correctly then resource.poster does not change when manually changing the poster – element.poster will be change in that case, element.resource.poster is always the original poster. Thus it should be ok to ignore this value changing causing a new history entry. LMK if that’s incorrect.

I’ll do some more testing tomorrow. With these ignored values, two clicks of “Undo” are needed to undo uploading a new video to the Page (as opposed to 5 on main), will try to track down what’s still causing the extra step.

1reaction
spacedmonkeycommented, Jan 12, 2022

I would also add 'resource.blurHash' 'resource.id'

Read more comments on GitHub >

github_iconTop Results From Across the Web

A Brief History: Pollution Tutorial
By the 1800s, people began to understand that unsanitary living conditions and water contamination contributed to disease epidemics. This new awareness prompted ...
Read more >
History of Air Pollution | US EPA
States began passing legislation to reduce air pollution. And in 1970, a milestone year, Congress passed the Clean Air Act Amendments which led ......
Read more >
Water and Air Pollution
In the 1960s, an environmental movement began to emerge that sought to stem the tide of pollutants flowing into the planet's ecosystems. Out...
Read more >
Pollution Lessons from History
Today, the problem of life-threatening pollution has been solved for the most part in U.S. and Europe. While pollution still exists to some ......
Read more >
Can the history of pollution shape a better future?
Historians François Jarrige and Thomas Le Roux unpick the broader social, economic and political factors underpinning our despoilment of the ...
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