Git Product home page Git Product logo

py-unrar2's People

Contributors

kyegupov avatar pombreda avatar

Watchers

James Cloos avatar

py-unrar2's Issues

Python 2.6 - Unable to move or delete RAR archive with shutil

What steps will reproduce the problem?
1. Open the Python script I attached, drop the attached archive into it and 
press enter.

What is the expected output? What do you see instead?
I expect the text file to be extracted to the desktop, and the archive to be 
moved to My Documents.

Instead, the file IS extracted but the archive is just copied to My Documents, 
with the original file staying wherever you placed it, and raises a 
WindowsError.


What version of the product are you using? On what operating system?
Windows XP Home SP3

Please provide any additional information below.
Traceback (most recent call last):
  File "C:/Documents and Settings/*******/Desktop/Error.py", line 54, in <module>
    checkExtension()
  File "C:/Documents and Settings/********/Desktop/Error.py", line 18, in checkExtension
    unrar()
  File "C:/Documents and Settings/*********/Desktop/Error.py", line 47, in unrar
    shutil.move(filename , desktop)
  File "C:\Python26\lib\shutil.py", line 265, in move
    os.unlink(src)
WindowsError: [Error 32] The process cannot access the file because it is being 
used by another process: 'Tester.rar'

Original issue reported on code.google.com by [email protected] on 18 Jun 2010 at 2:02

Attachments:

Need a way to filter read_files for multiple file types, file extensions

What steps will reproduce the problem?
1. Define a string or list with multiple file types (e.g.
['.jpg','.jpeg','.gif','.png']
2. Pass string to RarFile.read_files()

What is the expected output? What do you see instead?
I expect to get a list of files back that match any of the given
extensions. Instead, I get no matches found.

What version of the product are you using? On what operating system?
0.96 on windows xp

Please provide any additional information below.

Original issue reported on code.google.com by [email protected] on 21 Jan 2010 at 9:38

read_files() return [] when trying to read from a file name contain bracket "[ ]"

What steps will reproduce the problem?
1. open a rar file include a file name with bracket"[ ]"
2.
3.

What is the expected output? What do you see instead?
RarFile.read_files(fname) should return content of the file, but return [] 
instead


What version of the product are you using? On what operating system?
0.99.2 windows xp


Please provide any additional information below.
I attached a test file for your info

Original issue reported on code.google.com by [email protected] on 28 Jan 2011 at 5:05

Attachments:

Nothing extracted after infoiter loop on Windows

What steps will reproduce the problem?

Run this code:

rar = UnRAR2.RarFile("test.rar")
print "Check archive contents:"
for info in rar.infoiter():
    print info.filename

print "Extract files:"
infos = rar.extract()
for info in infos:
    print info.filename

What is the expected output? What do you see instead?

extract() method fails to extract anything just like there are no files in 
archive. 

What version of the product are you using? On what operating system?
py-unrar2 v.0.99.1, Windows XP SP3


Please provide any additional information below.
My program worked fine in Linux before. Porting to Windows poped this bug up.

Original issue reported on code.google.com by [email protected] on 9 Sep 2010 at 11:47

info needs to be shifted

For my system when setting data['datetime'] using time.strptime(info[37:51], 
'%d-%m-%y %H:%M'), it raises a value error.  Shifting info to 38:52 resolves 
the issue.


What steps will reproduce the problem?
python test_UnRAR2

What version of the product are you using? On what operating system?
POWERTUX ~ % uname -a                                                           

 2010-07-18  7:29pm
Linux POWERTUX 2.6.34-ARCH #1 SMP PREEMPT Mon Jul 5 21:03:38 UTC 2010 i686 AMD 
Athlon(tm) 64 X2 Dual Core Processor 4800+ AuthenticAMD GNU/Linux
POWERTUX ~ % python --version                                                   

 2010-07-18  7:29pm
Python 2.6.5
POWERTUX ~ % locale                                                             

 2010-07-18  7:29pm
LANG=en_US.utf8
LC_CTYPE="en_US.utf8"
LC_NUMERIC="en_US.utf8"
LC_TIME="en_US.utf8"
LC_COLLATE=C
LC_MONETARY="en_US.utf8"
LC_MESSAGES="en_US.utf8"
LC_PAPER="en_US.utf8"
LC_NAME="en_US.utf8"
LC_ADDRESS="en_US.utf8"
LC_TELEPHONE="en_US.utf8"
LC_MEASUREMENT="en_US.utf8"
LC_IDENTIFICATION="en_US.utf8"
LC_ALL=


Please provide any additional information below.

POWERTUX ~/Downloads/pyUnRAR2-0.98 % python test_UnRAR2.py                      

 2010-07-18  7:30pm
Traceback (most recent call last):
  File "test_UnRAR2.py", line 16, in <module>
    UnRAR2.RarFile('test.rar').extract()
  File "/usr/lib/python2.6/site-packages/UnRAR2/__init__.py", line 156, in extract
    return RarFileImplementation.extract(self, checker, path, withSubpath, overwrite)
  File "/usr/lib/python2.6/site-packages/UnRAR2/unix.py", line 132, in extract
    for info in self.infoiter():
  File "/usr/lib/python2.6/site-packages/UnRAR2/__init__.py", line 118, in infoiter
    for params in RarFileImplementation.infoiter(self):
  File "/usr/lib/python2.6/site-packages/UnRAR2/unix.py", line 102, in infoiter
    data['datetime'] = time.strptime(info[38:52], '%d-%m-%y %H:%M')
  File "/usr/lib/python2.6/_strptime.py", line 454, in _strptime_time
    return _strptime(data_string, format)[0]
  File "/usr/lib/python2.6/_strptime.py", line 325, in _strptime
    (data_string, format))
ValueError: time data '0-06-03 01:59 ' does not match format '%d-%m-%y %H:%M'


Original issue reported on code.google.com by [email protected] on 19 Jul 2010 at 1:29

File remains locked once open

What steps will reproduce the problem?
1. rar = RarFile(rarFileName)
2. print(rar.read_files())
3. del rar
4. os.remove(rarFileName)

What is the expected output? What do you see instead?

I expect it to remove successfully, but it says 

WindowsError: [Error 32] The process cannot access the file because it is
being used by another process: ...

Also note I am using a UNC path.

What version of the product are you using? On what operating system?

Windows XP

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 29 Apr 2009 at 4:43

Files in protected archive are silently skipped if password is None

What steps will reproduce the problem?

>>> try:
>>>    UnRAR2.RarFile('test_protected_files.rar').extract()
>>> except IncorrectRARPassword:
>>>    errored = True

What is the expected output?

>>> print errored
True
>>> print os.path.exists('test'+os.sep+'top_secret_xxx_file.txt')
False

What do you see instead?

>>> print errored
False
>>> print os.path.exists('test'+os.sep+'top_secret_xxx_file.txt')
False

What version of the product are you using?

0.99.3

On what operating system?

Windows 7

Please provide any additional information below.

Python 2.7

Original issue reported on code.google.com by [email protected] on 17 Mar 2014 at 12:03

Doesn't work with unrar 5.0

What steps will reproduce the problem?
1. Have unrar 5.x installed
2. Try to use pyunrar2


What is the expected output? What do you see instead?
I should be able to create a RarFile object. Instead it explodes, because the 
lines iterator runs out of lines before finding its comment.


What version of the product are you using? On what operating system?
Current version, as part of sickbeard, in linux.


Please provide any additional information below.

Original issue reported on code.google.com by dkowis on 22 Oct 2013 at 2:34

does not support RAR files with encrypted block headers

The module does not seem to support RAR files with encrypted block headers. 
With these RAR archives, the filelisting, as well as the archive contents, are 
encrypted.

What is the expected output? What do you see instead?

>>> pyunrar2.RarFile("protected2.rar")

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "pyunrar2/__init__.py", line 98, in __init__
    RarFileImplementation.init(self, password)
  File "pyunrar2/unix.py", line 76, in init
    line = source.next()
StopIteration


What version of the product are you using? On what operating system?
13:119276e3b3cf on Ubuntu Linux 10.10.

Original issue reported on code.google.com by martey on 29 Jul 2010 at 12:40

missing data in `str contents` portion?

What steps will reproduce the problem?
1. Pass my ReadRarFiles function a rar file:
http://pastebin.com/YQ8X4vwG

What is the expected output? What do you see instead?
I expect to see data in the `str contents` portion of my `extracts`
variable when I print it as a string, after calling read_files() (with no
parameters, should grab everything, as it appears to be doing).

Instead I get:
http://pastebin.com/H0dEVNL0

It can't identify the image file because there is no data in the file data
section.

What version of the product are you using? On what operating system?
0.96, Win7 x64

I can provide more info if needed.

Original issue reported on code.google.com by [email protected] on 14 Apr 2010 at 12:39

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.