Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not downloading Daily reports from MacAppStore #279

Open
Lymes opened this issue Nov 8, 2015 · 11 comments
Open

Not downloading Daily reports from MacAppStore #279

Lymes opened this issue Nov 8, 2015 · 11 comments

Comments

@Lymes
Copy link

Lymes commented Nov 8, 2015

ReportDownloadOperation.m,
-(void)main

NSData *reportData = [NSURLConnection sendSynchronousRequest:reportDownloadRequest returningResponse:&response error:NULL];
NSString *errorMessage = [[response allHeaderFields] objectForKey:@"Errormsg"];
if ( errorMessage )
{
        NSLog( @"  %@", errorMessage );
}
else if ( reportData )

After 5 November 2015 always prints the following error message:

AppSalesMobile[29627:925630] Daily reports are only available for past 365 days. Please enter a new date.

Before that date the app worked fine. I've checked out the query params

NSString *reportDownloadBodyString = [NSString stringWithFormat:@"USERNAME=%@&PASSWORD=%@&VNDNUMBER=%@&TYPEOFREPORT=%@&DATETYPE=%@&REPORTTYPE=%@&REPORTDATE=%@",
                                                  escapedUsername, escapedPassword, vendorID, @"Sales", dateType, @"Summary", reportDateString]; 

and the params seem to be correct.

@ddaddy
Copy link

ddaddy commented Nov 8, 2015

Reports since 5th November are not available. See iTC reports section for the notice.

Reports for 5th were actually released but then removed. So if you have a 5th report you should delete it until Apple release a corrected one.

@Lymes
Copy link
Author

Lymes commented Nov 8, 2015

Oh man, thank you. BTW, I've forked your repository, great job!

@ddaddy
Copy link

ddaddy commented Nov 8, 2015

👍🏼
Apple also say reports between 26th Oct - 2nd Nov are also wrong and will eventually be reissued.

@Morpheus2002
Copy link

@ddaddy stupid question: how do I redownload old reports in ITC? I don't see any option for that. Now, that reports between 26th Oct - 2nd Nov are corrected I would like to replace the wrong ones.

@ddaddy
Copy link

ddaddy commented Nov 23, 2015

You just delete the ones you have. Press and hold on a bar to delete.

@dave256
Copy link
Contributor

dave256 commented Nov 23, 2015

I think we'll also need to edit the file: ReportDownloadOperation.m and edit the line:
NSInteger maxNumberOfAvailableReports = [dateType isEqualToString:@"Daily"] ? 14 : 13;

You'll want to change the 14 to about 28-30 to make it look for the earlier dates. I haven't done this yet, but plan to try it later today.

@ddaddy
Copy link

ddaddy commented Nov 23, 2015

I'm not sure if that's different in my fork, but mine downloaded them no problem.

@dave256
Copy link
Contributor

dave256 commented Nov 23, 2015

@ddaddy yes, it is set to 30 in your fork. As I suspected, it did not work with 14, but changing it to 30 allowed me to re-download the new reports after deleting them.

@Morpheus2002
Copy link

Thank you guys! It worked for AppSales. But still don't see the option for manual report download in ITC.

@ddaddy
Copy link

ddaddy commented Nov 24, 2015

In iTC it's slightly hidden.
Go to the Sales and Trends page, then press at the top left where it says Top Content and you can change it to reports.

@Morpheus2002
Copy link

@ddaddy you are the best! 😊

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants