Questions tagged [duplication]

181 questions
3
votes
1 answer

Why does Aptana (eclipse) create duplicate python packages/files?

A picture says more then thousand words: I created one src foulder and one webscraper folder with one file named dblp.py in it. Why is Aptana/Eclipse showing the duplicates?
Aufwind
  • 22,034
  • 33
  • 94
  • 149
3
votes
1 answer

Direct3D Desktop Duplication: How to Recover From Changing Screen Resolution?

I'm developing a desktop application that uses the IDXGIOutputDuplication interface to take screen pictures several times per second. Whenever I call its AcquireNextFrame method, I check if the returned HRESULT is DXGI_ERROR_ACCESS_LOST to see if…
Aaron Ong
  • 171
  • 9
3
votes
2 answers

Stop Scrapy crawling the same URLs

I've written a basic Scrapy spider to crawl a website which seems to run fine other than the fact it doesn't want to stop, i.e. it keeps revisiting the same urls and returning the same content - I always end up having to stop it. I suspect it's…
prbens
  • 33
  • 1
  • 5
3
votes
1 answer

grid.arrange plotting same graphic for all plots in list

I am running R version 3.1.1. in RStudio and am having difficulties with grid.arrange. I am reading sales data for over 100 stores and plotting the sales over time. I am also trying to group the plots to display a set number at a time. However,…
3
votes
3 answers

CQRS code duplication in commands

I have a question about code duplication in the command side of the CQRS principle. Been following the articles from: https://www.cuttingedge.it/blogs/steven/pivot/entry.php?id=91 https://www.cuttingedge.it/blogs/steven/pivot/entry.php?id=92 It…
3
votes
1 answer

Duplicate dijit widget instead of recreating it

Is there a way by which I can duplicate or clone dijit widgets? Basically, idea is to improve page rendering performance by minimizing widget creation time. We have a single page web application and we do not reload the entire page whenever the…
Brij
  • 173
  • 1
  • 12
3
votes
2 answers

Reusing "i" for JavaScript for loops

I recently started using PHP Storm (love it) and noticed that it flags declarations of "var i" in for loops as duplicate in JavaScript. I learned that apparently the scope of that variable exists outside of the loop. for (var i = 0; i < 10; i++) { …
Captain Stack
  • 3,102
  • 5
  • 25
  • 51
3
votes
1 answer

How to detect duplicate text with some fuzzyness

Some thing ago, I write small script using Text::DeDupe to remove duplicates of blog posts before I have to lay my eyes on them. After reading Syntactic Clustering of the Web paper on which implementation is based, I would love to have ability to…
dpavlin
  • 1,242
  • 2
  • 9
  • 18
3
votes
1 answer

How to handle mirrored(duplicated) iptables traffic after TEE?

I have a question about mirrored with TEE option iptables traffic. The main goal is to copy all traffic for service on server A (port 1935) to same service running on server B on same port (port 1935). For example: If I start streaming video to…
user3284527
  • 31
  • 1
  • 2
3
votes
1 answer

python variables - discord across modules

I switch program mode by modifying a global value in my main module. The change is reflected in following function calls originating inside that module, but not when other modules call the same functions. Is the main module using an…
fivecode
  • 35
  • 5
3
votes
5 answers

How to duplicate list element more than one time with jQuery

i have i little question. Is there any option to duplicate more than one element with jquery? I have one element list, can i clone, duplicate it f.e. 7 times?
    data
and some jquery, i have no…
Lukas
  • 6,464
  • 16
  • 61
  • 114
2
votes
3 answers

duplicating arrays javascript splicing

I have come across a strange bug in my code and I cannot understand why it happens. I have an array array1. I duplicate array1 by making array2 equal to array1. I then modify array2 using splice to add a number. Array1 should not be touched? But…
myol
  • 6,385
  • 18
  • 64
  • 110
2
votes
1 answer

How to avoid operator's or method's code duplication for const and non-const objects?

Possible Duplicate: How do I remove code duplication between similar const and non-const member functions? My task is to implement c++ vector analogue. I've coded operator[] for 2 cases. T myvector::operator[](size_t index) const {//case 1, for…
karlicoss
  • 2,361
  • 3
  • 22
  • 26
2
votes
1 answer

Ajax Design/Refactoring help when rendering new content - like list items and divs

I consistently come across this code smell where I am duplicating markup, and I'm not really sure how to fix it. Here's a typical use case scenario: Let's say we'd like to post comments to some kind of article. Underneath the article, we see a bunch…
egervari
  • 21,108
  • 30
  • 115
  • 171
2
votes
1 answer

Sonarqube: Is it possible to adapt duplication metric for javascript code?

At the moment the duplication metric for JavaScript Code in SonarQube code is defined as followed: “There should be at least 100 successive and duplicated tokens. Those tokens should be spread at least on 10 lines of code.” Is there a way to…
Stelos10
  • 421
  • 2
  • 6
  • 15
1 2
3
12 13