Closed pulse-mind closed 2 months ago
Hi @pulse-mind, sorry to hear you have issues. Could you try issuing this command and see what happens please?
fido -sigs update
I'll look into what might be a packaging issue in the coming two weeks.
Hi @carlwilson , thank you for your reply. I'am not sure to understand properly your request. So this is what I've done :
fido -sigs update
fido -sigs update
usage: fido [-h] [-v] [-q] [-recurse] [-zip] [-noextension] [-nocontainer] [-pronom_only] [-input INPUT] [-filename FILENAME]
[-useformats INCLUDEPUIDS] [-nouseformats EXCLUDEPUIDS] [-matchprintf FORMATSTRING] [-nomatchprintf FORMATSTRING] [-bufsize BUFSIZE]
[-container_bufsize CONTAINER_BUFSIZE] [-loadformats XML1,...,XMLn] [-confdir CONFDIR]
[FILE ...]
fido: error: unrecognized arguments: -sigs
For your information I'm working on MACOS (latest version) - Apple chip.
Hi @pulse-mind , it's not clear to me that you are running v1.6 of Fido which I suspect is the problem. Here's the output from a fresh virtualenv install on my workstation:
fido -v
zsh: correct 'fido' to 'id' [nyae]? n
FIDO v1.6.1 (formats-v109.xml, container-signature-20200121.xml, format_extensions.xml)
❯ fido -h
usage: fido [-h] [-v] [-q] [-recurse] [-zip] [-noextension] [-nocontainer] [-pronom_only] [-input INPUT] [-filename FILENAME] [-useformats INCLUDEPUIDS] [-nouseformats EXCLUDEPUIDS]
[-matchprintf FORMATSTRING] [-nomatchprintf FORMATSTRING] [-bufsize BUFSIZE] [-sigs SIG_ACT] [-container_bufsize CONTAINER_BUFSIZE] [-loadformats XML1,...,XMLn]
[-confdir CONFDIR]
[FILE ...]
Note the -sigs
option in the help output. Please just try a fido -v
and check/paste the output please.
Hi @carlwilson Thank you for your reply and the time spent on it.
I start with a fresh virtualenv using 1.4.1 and then running the install requirements with 1.6.0 and this is the output (I probably did not take care about last time):
WARNING: The candidate selected for download or install is a yanked version: 'opf-fido' candidate (version 1.6.0 at https://files.pythonhosted.org/packages/7f/2e/77ea6a904ea150159a0afdf7f36246d20f488b2b7ad54a2915e435b0751c/opf_fido-1.6.0-py2.py3-none-any.whl (from https://pypi.org/simple/opf-fido/))
Reason for being yanked: Incorrect packaging
Installing collected packages: importlib-resources, opf-fido
Attempting uninstall: opf-fido
Found existing installation: opf-fido 1.4.1
Uninstalling opf-fido-1.4.1:
Successfully uninstalled opf-fido-1.4.1
Successfully installed importlib-resources-5.12.0 opf-fido-1.6.0
I never had this kind of warning in the past.
If I do a pip list
I have opf-fido 1.6.0
And now if I do fido -v :
(myproject) ➜ myproject git:(master) ✗ fido -v
FIDO v1.6.0 (formats-v109.xml, container-signature-20200121.xml, format_extensions.xml)
And then ```fido -h````
fido -h
usage: fido [-h] [-v] [-q] [-recurse] [-zip] [-noextension] [-nocontainer] [-pronom_only] [-input INPUT] [-filename FILENAME]
[-useformats INCLUDEPUIDS] [-nouseformats EXCLUDEPUIDS] [-matchprintf FORMATSTRING] [-nomatchprintf FORMATSTRING] [-bufsize BUFSIZE]
[-sigs SIG_ACT] [-container_bufsize CONTAINER_BUFSIZE] [-loadformats XML1,...,XMLn] [-confdir CONFDIR]
[FILE ...]
And finally fido -sigs update
that was not working last time which is working now...
fido -sigs update
Your signature files are up to date, current version is v109
At the end I still have the same Error
FileNotFoundError: [Errno 2] No such file or directory: '/Users/pmind/.virtualenvs/myproject/lib/python3.10/site-packages/fido/conf/formats-v104.xml'
Thanks for that detailed feedback. That's enough for me to do a little more investigation. It will be next week when I get back to you with some progress hopefully.
Hi @carlwilson did you find the time to investigate ?
Hi @pulse-mind, apologies for the time taken. Could you please let me know your Python and Pip versions please?
❯ python --version
Python 3.11.3
❯ pip --version
pip 23.1.2 from .venvs/fido/lib/python3.11/site-packages/pip (python 3.11)
Hello,
At this day :
> python --version
Python 3.10.4
> pip --version
pip 23.1.2 from /Users/.../.virtualenvs/.../lib/python3.10/site-packages/pip (python 3.10)
I think it was the same few weeks or month ago except minor version.
Hi @carlwilson
Did you find the time to investigate ?
Have a good day. Fred
Hi @carlwilson , Any chance for an investigation on this issue ?
@carlwilson In fido.py, the defaults contains v104 instead of v109
defaults = {
'bufsize': 128 * 1024, # (bytes)
'regexcachesize': 2084, # (bytes)
'printmatch': "OK,%(info.time)s,%(info.puid)s,\"%(info.formatname)s\",\"%(info.signaturename)s\",%(info.filesize)s,\"%(info.filename)s\",\"%(info.mimetype)s\",\"%(info.matchtype)s\"\n",
'printnomatch': "KO,%(info.time)s,,,,%(info.filesize)s,\"%(info.filename)s\",,\"%(info.matchtype)s\"\n",
'format_files': [
'formats-v104.xml',
'format_extensions.xml'
],
Instead of
defaults = {
'bufsize': 128 * 1024, # (bytes)
'regexcachesize': 2084, # (bytes)
'printmatch': "OK,%(info.time)s,%(info.puid)s,\"%(info.formatname)s\",\"%(info.signaturename)s\",%(info.filesize)s,\"%(info.filename)s\",\"%(info.mimetype)s\",\"%(info.matchtype)s\"\n",
'printnomatch': "KO,%(info.time)s,,,,%(info.filesize)s,\"%(info.filename)s\",,\"%(info.matchtype)s\"\n",
'format_files': [
'formats-v109.xml',
'format_extensions.xml'
],
If I modify this it works fine.
Do you want me to do a pull request for this ?
I've merged this at last @pulse-mind apologies, I've been stretched too thin over too many things and somethings had to give. We will endeavour to get a release out soon.
Thank you, have a good day.
Hello,
I am using django and I migrate from 1.4.1 to 1.6.0. I have this error :
In https://github.com/openpreserve/fido/tree/master/fido/conf there is only formats-v109.xml
Would you like to help me about that please ?
Best regards, Fred