Comments (6)
Yay I fixed it! I think the issue had to do with the FilePath
being passed to SetMetadataXML from Set-FakkuMetadata not being a full path, but just the name of the file. There was also the issue of SetMetadataXML using $NewName
as the DestinationPath
flag for Compress-Archive
, but if the archive did not contain any brackets, $NewName
is never defined. This was why the ComicInfo.xml was always left in the parent directory for me since my archives do not contain brackets. I can send the code if needed, but I'm not sure if this is an isolated fix/issue still or if my diagnosis is even correct tbh lol.
Edit: Also realizing that, at least for me, Compress-Archive
doesn't like .cbz extensions and only works with .zip.
from fkulibrary.
Not sure why I'm encountering this issue, but it seems that it doesn't write the ComicInfo.xml to the archive but rather the directory the book is in
I wouldn't think that Windows 11 is affecting it, but I don't have an environment to test for myself unfortunately. I tested locally on my W10 machine and it's still working as expected. When setting -FilePath
are you using a network path (e.g. //server/path
) or a mounted path (e.g. F:\path
)? I don't think it should make a difference but if you're using a network path try to mount it. If you look at the Set-MetadataXML, the module first creates the XML file within the directory using Set-Content ... [Line 12]
and then adding it to the archive via Compress-Archive ... [Line 21]
. You could probably troubleshoot by running the Set-MetadataXML
function line by line to see where it's not working as expected.
While running, it also says it can't find the book (WARNING xyz not found on FAKKU/panda.chaika), but the ComicInfo.xml seems to be pulling the correct info.
If it gives you the not found on Fakku...
warning, then it will automatically fall back to pulling metadata from panda.chaika.moe. If that's not found, then it should give you an additional warning about not being found on panda.chaika. The ones not found on panda.chaika should be empty, but if not that's strange.
Though I'll be honest, I don't really have the motivation to continue supporting this project in its current form and would recommend you take a look at more mature solutions such as lanraragi or happypandax to manage your doujinshi metadata. There are probably other projects out there but those are the two that I have tried and found reasonably useful.
from fkulibrary.
Thanks for the reply! It's a mounted drive. I'll try testing on a spare laptop since I'm really at a loss as to why it's acting so weird on my system (i.e. the metadata warning). It fails for both FAKKU/panda, but also still has the correct metadata pulled from FAKKU, so I'll see what I can look at to as why it's behaving that way. I think it's failing to add it to the archive for some reason, but I can't ask of you to diagnose that since it's not your system lol. Thanks for the advice! I've looked at happypandax, but my main reservation, much like I think you or the somebody else mentioned in #2, is that unlike writing a ComicInfo.xml, the metadata isn't saved locally and I'd like the collection to be as flexible/platform agnostic as possible. I kinda figured you were finished with the project, but I appreciate the help nonetheless. Appreciate the quick response as well! Cheers.
from fkulibrary.
Awesome! I'm glad you were able to resolve it.
There was also the issue of SetMetadataXML using $NewName as the DestinationPath flag for Compress-Archive, but if the archive did not contain any brackets, $NewName is never defined.
That seems to be an oversight on my part.. good catch. I probably didn't catch it because the majority of manga that come from the torrents have brackets in them.
I can send the code if needed, but I'm not sure if this is an isolated fix/issue still or if my diagnosis is even correct tbh lol.
Your diagnosis does seem correct! I'll gladly accept a PR if you're up to it.
Edit: Also realizing that, at least for me, Compress-Archive doesn't like .cbz extensions and only works with .zip.
The Get-LocalArchives function does currently detect multiple archive extension types including .cbz
, but I'm surprised Compress-Archive
doesn't work for you. I just tested on my system and it does work. You could probably add a workaround in Set-FakkuMetadata
to update the extension to .zip
before the Compress-Archive
and then change it back after.
from fkulibrary.
Honestly I changed like two lines of code so I'm don't it's worth a PR lol. That and there's issues I'm encountering that I can't fully confirm if they're purely personal or not since you said it's properly working for you.
I added an else clause on line 19 of SetMetadataXML else { $NewName = $FilePath }
to account for bracketless names. To fix the file path issue, on line 91 and 107 of Set-FakkuMetadata, I just used Set-MetadataXML -FilePath $File.FullName -XMLPath $XMLPath -Content $xml
instead of Set-MetadataXML -FilePath $File.Name -XMLPath $XMLPath -Content $xml
since Compress-Archive
needs a full path and $File.Name
would only pass the name.
I've also encountered issues with Get-FakkuUrl not properly sterilizing artist names in brackets. It seems in this commit, on line 11, you changed the regex matching which broke the deletion of text inside the brackets. I just reverted it to what you had previously and it fixed it and scraped proper links. As is, I was getting the artist name included in the links which doesn't abide by FAKKU naming convention (at least right now, not sure if it used to be). Hope this helps!
from fkulibrary.
I opened a PR that addresses this as well as a few other things. Hope you can take a look!
from fkulibrary.
Related Issues (3)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fkulibrary.