Solved <dateadded>1</dateadded> in advanced settings is ignored
#1
Hey...

So i have been pulling my hair trying to figure out why stuff shows up in the recently added when it shouldn't and it looks to me like it's a bug.

I even tried to force it in advancedsettings.xml :
Code:
<videolibrary>
        <hideallitems>true</hideallitems>
        <recentlyaddeditems>300</recentlyaddeditems>
        <cleanonupdate>true</cleanonupdate>
        <dateadded>1</dateadded>
    </videolibrary>

i removed the whole Family Guy, set all the file dates for the videos, thumbs and nfos to each episode's airdate, and then re-imported it.

it showed up in the recently added and when i queried the MySQL files table and the dateadded rows are all set to today's date.

I tried with a whole bunch of other shows and it's the same thing.

I am running Kodi Helix 14.2 beta

-Pr.

EDIT: This is now fixed in the latest nightly!: http://mirrors.kodi.tv/test-builds/win32...getime.exe
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#2
This was broken by a really silly change which should never have made it past any kind of QA. Whoever did it has also done us the solid of going into hiding for several months. More background and original bug report here.
Reply
#3
And another bug... As far as I can tell Kodi (since at least Windows version 13 which is the first version I started using at) has never read/utilized the dateadded field from the local nfo. Kodi is supposed to use any info in the nfo first over all other data inputs... but it doesn't for the dateadded field for whatever reason.
Reply
#4
You´re sure there´s not exFAT involved? Will try to ping the win32 guys again so we can try to reproduce again.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#5
No there is no exFat involved all drives are formatted as NTFS. TV server is on Windows 7 x64 Ultimate, Movie server is on Windows 7 x64 Ultimate, Other Media Server is on Windows 8.1 x64 Pro and the MySQL DB server that does the scanning is on Windows 7 x64 Ultimate.

All media is accessed through SMB shares
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#6
So what do you expect by setting dateadded to 1? This setting defaults to 1 and this means it is using the modification time when adding.

EDIT: Sorry, misread first post. This sounds like a complete different issue than the one beesway linked to.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#7
(2015-03-09, 16:37)Bogi Wrote: And another bug... As far as I can tell Kodi (since at least Windows version 13 which is the first version I started using at) has never read/utilized the dateadded field from the local nfo. Kodi is supposed to use any info in the nfo first over all other data inputs... but it doesn't for the dateadded field for whatever reason.

That is correct. Dateadded is not read from nfo files.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#8
(2015-03-09, 18:12)mkortstiege Wrote:
(2015-03-09, 16:37)Bogi Wrote: And another bug... As far as I can tell Kodi (since at least Windows version 13 which is the first version I started using at) has never read/utilized the dateadded field from the local nfo. Kodi is supposed to use any info in the nfo first over all other data inputs... but it doesn't for the dateadded field for whatever reason.

That is correct. Dateadded is not read from nfo files.

Yeah, I've no idea why the nfo guy posted here, that's completely unrelated but the thread I linked to is related to the same bug that Pr.Sinister is experiencing. Pr.Sinister is scanning in new content (or maybe content he's moved, doesn't really matter) and he's correctly expecting the dateAdded column in SQL to be set to the NTFS file modified date. He's even manually setting those NTFS timestamps, probably using a tool like Attribute Changer or similar but is actually getting a completely different date. As per my posts in the linked thread, the date the bugged version of Kodi often pulls out of it's ass (or from the MFT) is today's date i.e. the date the scan is performed hence that show/movie jumps to the top of Recently Added.

As I've said in the linked thread though, it seems you've fixed it so I suggest OP grabs a copy of that 14.2 nightly and gives it a go!
Reply
#9
Here is an easy way for you guys to reproduce the problem:
  • Download FileTouch to quickly change file dates from the command-line/batch files
  • Download Xidel to extract the airdate from your NFOs and pass it on to filetouch
  • Put both .exe somewhere in your defined PATH so yu can call them from anywhere

Create a batch file with the following code:

Code:
@Echo off
REM **********************************************
REM Set File Dates from NFO Airdates
REM **********************************************
for /R %%l in (*.nfo) do (
for /F "tokens=1,2,3 delims=-" %%a in ('xidel -q "%%~pnxl" --extract //aired') do (
set year=%%a
set month=%%b
set day=%%c
filetouch /W /A /C /D %%b-%%c-%%a "%%~pnl*.*"
)
)

Save the batch file in your PATH too

Run the batch file inside a command windows from a TV Show folder.

It will go through all the .nfo files, extract the aired date for each episode and set the videofile, nfo file and thumb file's Creation Date, Modified Date and Last Access Date to the Airdate found in each NFO.

Here is an example of a file's attributes and the resulting row in the database:

File Attributes:

Image

Row in database:

Image[/quote]
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#10
I guess you missed the bit where I said they already fixed it
Reply
#11
(2015-03-09, 18:07)mkortstiege Wrote: So what do you expect by setting dateadded to 1? This setting defaults to 1 and this means it is using the modification time when adding.

EDIT: Sorry, misread first post. This sounds like a complete different issue than the one beesway linked to.

No it is not a different issue... <dateadded>1</dateadded> was added after i saw it wasn't using the modification time. So the 1st thing to try is to see if maybe the default is NOT set to 1 so i forced it to 1 just to be sure THAT wasn't the bug.

In any case, by default, it should use the modtime but as you can see from previous post, all times are set to September 28th 2014 but the dateadded is set to March 8th 2015

-Pr.
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#12
(2015-03-09, 18:59)beeswax Wrote: I guess you missed the bit where I said they already fixed it

NICE!!!

I am a work now but i will try to remote in and try it... or else i'll let you guys know tonight!
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#13
It works!

But now comes the dreaded part where i am so anal that i need to delete my whole library and rescan... It'll take 2 full days at least... 6500 Movies and 49000 episodes...

Sigh...
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#14
I just brought up the <dateadded> field that's in the NFO because the OP mentioned in the first post that he manually set that field in the NFO before scraping. I just wanted to let the OP know that I've never gotten it to work that way. I could have made my post a bit more clear to not cause confusion.
Reply

Logout Mark Read Team Forum Stats Members Help
<dateadded>1</dateadded> in advanced settings is ignored0