Originally created by @NickBusey on GitHub (Jun 29, 2018).
Trying to import a 1password export (.1pif) file results in an error.
Docker logs show:
POST /api/ciphers/import application/json; charset=utf-8:
=> Matched: POST /api/ciphers/import
=> Warning: Data left unread. Force closing network stream.
=> Error: Couldn't parse JSON body: Error("EOF while parsing a string", line: 1, column: 1048576)
=> Outcome: Failure
=> Warning: Responding with 400 Bad Request catcher.
=> Error: Failed to write response: Os { code: 32, kind: BrokenPipe, message: "Broken pipe" }.
Originally created by @NickBusey on GitHub (Jun 29, 2018).
Trying to import a 1password export (.1pif) file results in an error.
Docker logs show:
```
POST /api/ciphers/import application/json; charset=utf-8:
=> Matched: POST /api/ciphers/import
=> Warning: Data left unread. Force closing network stream.
=> Error: Couldn't parse JSON body: Error("EOF while parsing a string", line: 1, column: 1048576)
=> Outcome: Failure
=> Warning: Responding with 400 Bad Request catcher.
=> Error: Failed to write response: Os { code: 32, kind: BrokenPipe, message: "Broken pipe" }.
```
Can you provide some file to test this? I've got a feeling that this might be limited to very specific item in the export.
@mprasil commented on GitHub (Jun 29, 2018):
Can you provide some file to test this? I've got a feeling that this might be limited to very specific item in the export.
I think the issue here is our web server limits the size of the JSON input to 1 MB (Note how the number in column is equal to 1024 * 1024 bytes), so when an input exceeds the limit the server stops accepting more and the JSON we get is malformed.
I've increased the limit to 10 MB, which I think is probably enough, but if it isn't, you can increase it more by modifying the Rocket.toml file.
@dani-garcia commented on GitHub (Jun 29, 2018):
I think the issue here is our web server limits the size of the JSON input to 1 MB (Note how the number in column is equal to 1024 * 1024 bytes), so when an input exceeds the limit the server stops accepting more and the JSON we get is malformed.
I've increased the limit to 10 MB, which I think is probably enough, but if it isn't, you can increase it more by modifying the `Rocket.toml` file.
I can confirm it was file size. My import was 1.3MB, deleting half the contents worked.
I'm not sure the Rocket.toml is being included correctly in the docker image, or maybe I did something wrong when I tried to rebuild it. So I couldn't test your fix, but shrinking the file size worked. Thanks!
@NickBusey commented on GitHub (Jun 29, 2018):
I can confirm it was file size. My import was 1.3MB, deleting half the contents worked.
I'm not sure the Rocket.toml is being included correctly in the docker image, or maybe I did something wrong when I tried to rebuild it. So I couldn't test your fix, but shrinking the file size worked. Thanks!
AFAIK Rocket.toml is not included in the docker image.
But if I understand the Rocket documentation right, you should also be able to also set the limit by setting environment variable:
ROCKET_LIMITS={json=10485760}
@mprasil commented on GitHub (Jun 29, 2018):
AFAIK Rocket.toml is not included in the docker image.
But if I understand the Rocket documentation right, you should also be able to also set the limit by setting environment variable:
`ROCKET_LIMITS={json=10485760}`
I just tested it, and what @mprasil said works. I added the rocket.toml file to the docker image anyway, so it should work now without any changes.
@dani-garcia commented on GitHub (Jun 29, 2018):
I just tested it, and what @mprasil said works. I added the rocket.toml file to the docker image anyway, so it should work now without any changes.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Originally created by @NickBusey on GitHub (Jun 29, 2018).
Trying to import a 1password export (.1pif) file results in an error.
Docker logs show:
@mprasil commented on GitHub (Jun 29, 2018):
Can you provide some file to test this? I've got a feeling that this might be limited to very specific item in the export.
@dani-garcia commented on GitHub (Jun 29, 2018):
I think the issue here is our web server limits the size of the JSON input to 1 MB (Note how the number in column is equal to 1024 * 1024 bytes), so when an input exceeds the limit the server stops accepting more and the JSON we get is malformed.
I've increased the limit to 10 MB, which I think is probably enough, but if it isn't, you can increase it more by modifying the
Rocket.tomlfile.@NickBusey commented on GitHub (Jun 29, 2018):
I can confirm it was file size. My import was 1.3MB, deleting half the contents worked.
I'm not sure the Rocket.toml is being included correctly in the docker image, or maybe I did something wrong when I tried to rebuild it. So I couldn't test your fix, but shrinking the file size worked. Thanks!
@mprasil commented on GitHub (Jun 29, 2018):
AFAIK Rocket.toml is not included in the docker image.
But if I understand the Rocket documentation right, you should also be able to also set the limit by setting environment variable:
ROCKET_LIMITS={json=10485760}@dani-garcia commented on GitHub (Jun 29, 2018):
I just tested it, and what @mprasil said works. I added the rocket.toml file to the docker image anyway, so it should work now without any changes.