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
Ticket printing issue and attachments not storing/opening correctly #579
Comments
I was able to solve the printing ticket issue by cleaning the headers by adding the following to class.pdf.php after line 51. Would someone please verify the code and add if necessary. 50 //report header...most stuff are hard coded for now... |
Just following this, but we're seeing a corruption issue on all attachments coming through email pipe. Tested with .docx, .pdf, .jpg, .png, .psd, .xlsx file sizes ranging from 10KB through to 22MB |
I have confirmed .zip files as well. I also tried a number of sizes and it does not seem to matter what size the document is it corrupts the document. Although I am able to get ALL sized pdf files to work. |
Seems to be fine if we retrieve the emails via POP3. We've experienced attachment corruption issues on other software when the email was piped directly to it (it added odd characters to the end of the file, which is what we're seeing in the file chunks OsTicket creates), turned out to be due to the MIME encoding of the email/attachment, might be similar problem here... |
How did you guys come across this issue? Is this a streamed (git tracking) upgrade or a fresh install? I'm just wondering where I should go and start looking for culprits? |
My issue came up when I did a gitpul upgrade. Prior to the last update everything worked flawless. |
I found this attachment corruption on piped emails issue on a fresh 1.7.0 install from osticket.com an update from github about 6hrs ago didn't change it. |
I am able to replicate this issue via regardless of pull/creation method IMAP/POP3 or uploading to the public portal directly. So it must have something to do with FILE CHUNKS! |
I just did a fresh install and was able to replicate the issue also. Greezybacon were you able to replicate? Fourfoot what version of MySQL re you using? |
MySQL version is 5.1.69-cll. However, for me on the fresh install uploads via the /scp/ panel are fine, and emailed via POP3 are fine - just when they're directly piped that's causing me an issue. Using the same files for testing each time. Are you experiencing the issue with ALL methods on the fresh install? |
It is happening on all methods with mine on upgrade and fresh install. I also tested it on a backup of a fully working version and then upgraded. Tickets that were created prior to the upgrade open properly and once the upgrade is completed the previously created/closed ticket attachments no longer open attachments properly. All previous PDF files open correctly. Errors are still created opening .xls, .tiff, .jpg, .png. Perhaps the issue lies in the pull/fetch request? |
I am on MySQL 5.0.77 |
Greezybacon did you replicate? |
Josh, honestly I haven't had time to review it yet. My hunch is that the problem is in the http response code rather than the database fetch code |
Greezybacon did you change the http response code in Ny recent updates? |
I believe this is fixed in #583, can someone verify |
Confirmed fixed. |
@josh1856, the fix is merged, and I added a test to find leading and trailing whitespace in the code in hopes of avoiding this issue again in the future. |
Glad we got it fixed and I could help. Did you commit the print issue? |
#536 is a different issue. The email address does not fit in the space given on the PDF output |
After updating to the latest version via pull. Started receiving random errors:
The text was updated successfully, but these errors were encountered: