|
I have had similar issues after updating a WCF reference. I do a "clean" and then manually delete the obj subfolder. Then I rebuild. Works every time I try it.
|
|
|
|
|
MS' standard approach to everything these days seems to be to make something that sometimes works and can possibly be made to work eventually, with luck. Nobody seems to give a damn if anything is *correct*. Your particular story sounds like a corrupted build cache. Ever noticed the "clean" menu item? That is specifically for working around when VS has messed up it's caches and make sure everything gets made from scratch.
Granted, having a build cache does help a lot with build speed in many cases, as VS sometimes manages to correctly work out what has changed and must be rebuilt, and what hasn't and can be taken from the cache. I'll also grant that it may not be completely trivial to ensure the cache status is always correct, given that you may change files in all sorts of ways besides within VS, and given that build actions nowadays may encompass all sorts of things besides just compiling some code (e.g. code generators often execute immediately prior to build).
Even so, it does amaze me how VS sometimes manages to mess it up all by itself. The simplest solution consisting of a single console application project with a single Program.cs file and doing absolutely nothing outside of VS may still cause it to stubmle. But this sort of thing is perfectly in tune with how VS behaves in other respects. It can't modify a file because "another process" is using it, and it turns out it's VS blocking VS. It confidently asserts "all files are up to date" when solution explorer shows a folder with hundreds of files, and your working folder is empty. And for most of these, what do they do? Fix it, so VS behaves correctly? Oh no. They add a special menu option and name stuff so it seems as if YOU are at fault rather than VS. I chuckle whenever I need "get special version" in order to get the latest version and the dialog offers me the choice to fetch files even when the local version matches the specified version. Now what could *possibly* be the point of spending time to replace a file with an identical file? Clearly, MS knew full well about the problem, but was too embarrassed to honestly state "get file even if VS believes it already has it, as it sometimes mistakenly thinks so"....
I'm sure others could add many other examples of this general pattern of sketchy workarounds on top of semi-working base functionality. At least the glory days of VSS have passed - some people lost their entire source history due to it's tendency to occasionally corrupt it's own database files...
|
|
|
|
|
Not in VS 2012, but over the years, yes.
Browsers have cached my files and reused their cached files rather than my new ones.
Clocks have gone wacky on me, resulting in derived files (e.g. executables) with future dates.
Network file systems on machines with wildly different clocks have resulted in future date issues.
Revision control system have restored a file's date.. from a server with a skewed clock.
Precompiled headers have cached old code, which then got used in the build instead of the modified code in the source file.
I've even been the problem on occasion, doing stupid things that caused files not to be rebuilt after changes.
Clearing cached files, and cleaning all derived files and rebuilding, has fixed it for me. However, VS is historically deficient in deleting all derived files, so you may have to find and remove them by hand to truly get everything to rebuild.
We can program with only 1's, but if all you've got are zeros, you've got nothing.
|
|
|
|
|
It sounds to me as though what happened is this: after you'd made your changes, there was a bug in the result - a syntax error or something - and when you came to run it, VS ran the previously-compiled version without telling you... so it looked as though your changes weren't taking effect when in fact, the new code was never compiled. There's something in the options to make it not do that - can't remember where - but by default, that's what it does. It's caught me by surprise a couple of times, too...
|
|
|
|
|
We call them ghosts in the machine...
|
|
|
|
|
Lmao, Ghosts is about right. This had me going for weeks. I just thought it would be something interesting to post and see what encounters other people have had. I seem to find all sorts of bugs with computers and Visual Studios though. The other day my computer told me it couldn't find an operating system, then I restarted it and it worked fine. I thought maybe a good line of work would be penetration testing, considering I'm good at finding bugs, and loopholes.
|
|
|
|
|
If you have two or more projects open, for copying, there could be a memory leak if both have been debugged.
You are probably not notified of orphaned files when recreating a project. When copying a backup project to replace a project in another location you would be asked whether to overwrite files. This would be the easiest way to remove orphaned files; by deleting the project again. These files would not be visible in explorer if the project were deleted but an explorer search for the project would probably find the orphaned file.
Unless you are certain of how to deal with dependent files such as interfaces it is best not to rename, but recreate.
|
|
|
|
|
"Has anyone else come across the bug in Visual Studios 2012 where it runs code that isn't there?"
Ok, with just that statement alone, this had to be said:
I assume you're not referring to the MS bug in general where others tend to inject hacks into your system and run code that neither you, nor any other legitimate vendor, wrote.
|
|
|
|
|
Someone sent me a screenshot of Snipping Tool containing another screenshot. I'm still trying to puzzle out the thought process that led to that.
|
|
|
|
|
How did they even manage it? I can't get it to open twice, and it hides as soon as you start selecting a region (unless they PrintScreen'd the snipping tool)
|
|
|
|
|
1. CTRL+PRINTSCREEN
2. WIN+R => "pbrush"
3. CTRL+V
4. Crop
5. CTRL+S (alternatively, CTRL+A,C if your mail client lets you paste images into mail)
|
|
|
|
|
Right...I said Print Screen was an option...
I generally see the pattern that a person usually uses one method or the other of getting screen shots, not both. So if they were using the snipping tool, I would assume they somehow used the snipping tool to get the screen shot of the snipping tool.
|
|
|
|
|
Yes. And I think someone was wide awake and wanted to create this littly mystery. AFAIK you can only run one instance of snipping tool.
One other possibility I can think of is a remote desktop session. You could pull up the tool on the remote computer and then be distracted, say by an email, and then fire up the tool on the local machine. The tool captures remote desktop output just as easily as anything else on screen, so I suppose this way you could end up with a capture of snipping tool showing it's fresh capture.
|
|
|
|
|
BotCar wrote: I'm still trying to puzzle out the thought process that led to that.
I think their brain hadn't been powered on at the time, so no thought process was active.
brisingr_aerowing@Gryphon-PC $ rake in_the_dough
Raking in the dough
brisingr_aerowing@Gryphon-PC $ make lots_of_money
Making lots_of_money
|
|
|
|
|
Can you make a screen shot of that?
The signature is in building process.. Please wait...
|
|
|
|
|
A screen shot? They are modern! We received photographs of screens taken with a digital camera.
At least they did not use an analog camera and then faxed the photo (after scanning the photo, doing some photoshop, and printing it again).
|
|
|
|
|
Bernhard Hiller wrote: We received photographs of screens taken with a digital camera
Ugh, don't remind me: I've seen those too. I've also seen documents being emailed, printed out, scanned, and then emailed again for no good reason.
Bernhard Hiller wrote: At least they did not use an analog camera and then faxed the photo (after scanning the photo, doing some photoshop, and printing it again).
I dread the day when I see that happening, and I probably will.
|
|
|
|
|
BotCar wrote: I dread the day when I see that happening, and I probably will.
Dunno - the average luser would be hard-pressed to find real film stock any more...I certainly haven't seen any for ten years or so!
The universe is composed of electrons, neutrons, protons and......morons. (ThePhantomUpvoter)
|
|
|
|
|
Bernhard Hiller wrote: We received photographs of screens taken with a digital camera
I see I am not the only one. Was for fun: when I installed Windows 8 (the setup screem) I photographed it with my phone and published it on Facebook (obviously not working on PC during setup)
The signature is in building process.. Please wait...
|
|
|
|
|
Another one here.
Here[^]
**see the first Picture
I am sorry i can't post direct url of that image, my network not allowed me to do that.
Thanks
--RA
|
|
|
|
|
Bernhard Hiller wrote: We received photographs of screens taken with a digital camera.
I've been guilty of that when I need to quickly make some data portable (for my own use only, I would never send that to someone else, if you're going to use email a screenshot would be easier anyways)
|
|
|
|
|
That's nothing! We lived for three months in a brown paper bag in a septic tank...
Python references aside, I think I can top that. I've actually seen a *system* where they did something about as clever: One program generated contracts from document templates and some data. The resulting doc was then turned into a TIFF image by automating Word, server-side, and print it using a TIFF printer driver. This image file was then run through OCR logic to extract from the document the data that you originally started with in order to generate the document.
The reason for this wonderful design? Everything else that was to happen whenever a contract was entered into was tightly coupled to a scanning solution from a time when all contracts were received physically by snail-mail and scanned in order to be processed by computer. The scanning solution wasn't actually very old, but the people who owned it had more influence than the people owning documents.
It's amazing what convoluted silliness can survive out there in the wild. And that, in part, is why I can believe Elon Musk when he says it's perfectly possible to build a transportation system that costs 1/10th of a bullet train to set up, is safe, runs on solar, and about twice as fast as an airplane...
Of course, our industry still easily gets the top spot for wasteful idiocy. Taking a few bytes of character data and turning it into a TIFF image of millions of bytes most of which are not even related to the data of interest, then doing OCR to get (most of) the data back again (most of the time) is surely serveral million times more complicated, and several million times more work, than almost any straightforward mechanism.
Maybe there is hope for the future. If we can be this crazy in software, who's to say existing transport systems, or energy useage in general, isn't simply the result of narrow thinking and attempts to improve what already exists? By starting with a clean sheet, it may well be possible to do radically better in a lot of areas.
|
|
|
|
|
|
I can't view TinyPic links at the office, so it'll have to wait a few hours. In the meantime, here's[^] an example of how it looks.
|
|
|
|
|
I have made a similar picture and uploaded to TinyPic. I have snipped the picture of this thread in IE11 on Windows 8.1 running in VirtualBox with the W8.1 Snipping Tool and snipped again with the Snipping Tool of the W7 host
|
|
|
|