shelve

Can I unshelve to a different branch in tfs 2008?

Let's assume that some developer in my team shelved his changes that he did in branch A. And I am working on branch B. Can I unshelve his changes into branch B? (By GUI or command prompt) ...

Python shelve module question

Does the Python shelve module have any protection built in to make sure two processes aren't writing to a file at the same time? ...

What is the difference between shelve and check in in TFS?

What is the concept of each? When is it ok to shelve your changes instead of checking in? ...

What is Shelving in TFS? just a soft checkin so others can see code?

Hi, Is shelving in TFS merely a soft checkin so other team members can see the source code? i.e. the shelved code will not be compiled right? ...

In svn, can I revert a change and shelve it for later?

I have some changes commited a few commits back in my svn repository. Let's say HEAD is at r750 and I want to revert r745 without losing r746-r750. Is this possible? And, can I somehow save r745 and reapply it later (as a new revision)? ...

Is there an easy way to use a python tempfile in a shelve (and make sure it cleans itself up)?

Basically, I want an infinite size (more accurately, hard-drive rather than memory bound) dict in a python program I'm writing. It seems like the tempfile and shelve modules are naturally suited for this, however, I can't see how to use them together in a safe manner. I want the tempfile to be deleted when the shelve is GCed (or at guara...

Problem with shelve module?

Using the shelve module has given me some surprising behavior. keys(), iter(), and iteritems() don't return all the entries in the shelf! Here's the code: cache = shelve.open('my.cache') # ... cache[url] = (datetime.datetime.today(), value) later: cache = shelve.open('my.cache') urls = ['accounts_with_transactions.xml', 'targets.xml'...

Any way to use a tuple as key in a shelf? (Python)

Hi, I want to use a tuple (1,2,3) as a key using the shelve module in Python. I can do this with dictionaries: d = {} d[(1,2,3)] = 4 But if i try it with shelve: s = shelve.open('myshelf') s[(1,2,3)] = 4 I get: "TypeError: String or Integer object expected for key, tuple found" Any suggestions? ...

Is there a overview of my existing shelves available in Visual Studio 2008 when shelving?

I'm using Visual Studio 2008 and discovered the shelve/unshelve function for me and became a great fan of it. But there is one thing that annoys me. The shelve dialog lags a overview of my existing shelves. So each time I want to shelve I first open the unshelve dialog which lists all my existing shelves. After closing the dialog I ope...

Really weird issue with shelve (python)

I create a file called foo_module.py containing the following code: import shelve, whichdb, os from foo_package.g import g g.shelf = shelve.open("foo_path") g.shelf.close() print whichdb.whichdb("foo_path") # => dbhash os.remove("foo_path") Next to that file I create a directory called foo_package than contains an empty __init__....

Python shelve OutOfMemory error

I have some data stored in a DB that I want to process. DB access is painfully slow, so I decided to load all data in a dictionary before any processing. However, due to the huge size of the data stored, I get an out of memory error (I see more than 2 gigs being used). So I decided to use a disk data structure, and found out that using s...

Unshelving in TFS: What does it mean?

Here's the part I get: When you shelve in TFS, it makes a server copy of the changes so they are not lost, but does not check them into the source code trunk/branch you are working on. Question: Under what circumstances would you use the "unshelve" feature? Does it mean it will remove the shelveset from the TFS server? Can you do a get...

Visual Studio 2008 TFS Shelve/Unshelve changes stopped working and hangs VS

Greetings. This is second time I've actually spotted this problem with VS 2008 TS with TFS addon installed on top. The problem is that at some point, when you actively work with Shelve/Unshelve changes from TFS, the Shelve changes window (when you hit "Shelve" button) hangs and hangs whole VS. After that, if you restart studio, the Sh...

shelve gives strange error

Hi, I'm trying to put some sites i crawled into a shelve, but the shelve won't accept any Site-objects. It will accept lists, strings, tuples, what have you, but as soon as i put in a Site-object, it crashes when i try to get the contents of the shelve So when i fill up my shelve like this: def add_to_shelve(self, site): db = sh...

Does Python's shelve module use memory-mapped IO?

Does anyone know if Python's shelve module uses memory-mapped IO? Maybe that question is a bit misleading. I realize that shelve uses an underlying dbm-style module to do its dirty work. What are the chances that the underlying module uses mmap? I'm prototyping a datastore, and while I realize premature optimization is generally fro...

hg unshelve not working

Our team is just getting started with Mercurial. One of the first things we've started to play with is hg shelve. Locally, I have no problem shelving changes. It all works perfectly from what I can tell. However, when I try to unshelve, I get the restoring backup files message, but when I run hg diff, there are no changes, and my changes...

assign a shelved changlist in perforce?

I'm really excited about Perforce's new shelve command. They say that you should be able to "reassign" the changelist to someone else, who can then unshelve it. How do I reassign a shelved changelist? Is there a way to do it in p4v, or only at the commandline? ...

Viewing Python's shelve objects in PHP

I am using Python for indexing utilizing the shelve functionality and I was wondering whether it was possible to open and read the files in PHP. I checked out the PHP Shelve option and it doesn't seem to be working on PHP 5.X I am getting (when running the example they gave me) PHP Fatal error: Cannot pass parameter 2 by reference i...

Accessing Dictionaries VS Accessing Shelves

Currently, I have a dictionary that has a number as the key and a Class as a value. I can access the attributes of that Class like so: dictionary[str(instantiated_class_id_number)].attribute1 Due to memory issues, I want to use the shelve module. I am wondering if doing so is plausible. Does a shelve dictionary act the exact same as a...

Working on Dictionary of Classes in Python

Hello. For this example, I have a dictionary, that when I call on it, "Ember Attack" is displayed. #import shelve class Pokemon(): """Each pokemon's attributes""" def __init__(self): self.id=[] self.var1=[] self.var2=[] self.var3=[] self.var4=[] self.var5=[] def __str__(self): showList=['id','var1', 'var2'...