Remix app pim Integration deployed on fly.io

Remix app pim Integration deployed on fly.io

GlennAppsal
Shopify Partner
8 1 4

I am creating an app that integrates a pim system through their api with a Shopify store. It’s a one way import from pim to Shopify with auto sync. I’m partly finished and it’s working fine in development. I have deployed the app to fly.io 

when I run an import I get an invalid session error. If I click import again it normally works on second or third click. Anyone know how to fix this? I have not changed any settings regarding database or proxy. It’s just from the default remix template. Here is the error: │ [shopify-app/INFO] Authenticating admin request
16:27:15 │ remix │ [shopify-app/INFO] Authenticating admin request
16:27:15 │ remix │ [shopify-app/INFO] No valid session found
16:27:15 │ remix │ [shopify-app/INFO] Requesting offline access token
16:27:15 │ remix │ [shopify-app/INFO] No valid session found
16:27:15 │ remix │ [shopify-app/INFO] Requesting offline access token
16:27:15 │ remix │ error Response {
16:27:15 │ remix │ size: 0,
16:27:15 │ remix │ [Symbol(Body internals)]: {
16:27:15 │ remix │ body: null,
16:27:15 │ remix │ type: null,
16:27:15 │ remix │ size: 0,
16:27:15 │ remix │ boundary: null,
16:27:15 │ remix │ disturbed: false,
16:27:15 │ remix │ error: null
16:27:15 │ remix │ },
16:27:15 │ remix │ [Symbol(Response internals)]: {
16:27:15 │ remix │ url: undefined,
16:27:15 │ remix │ status: 500,
16:27:15 │ remix │ statusText: 'Internal Server Error',
16:27:15 │ remix │ headers: {},
16:27:15 │ remix │ counter: 0,
16:27:15 │ remix │ highWaterMark: undefined
16:27:15 │ remix │ }
16:27:15 │ remix │ }

Replies 3 (3)

Kyle_liu
Shopify Partner
421 53 77

Hi @GlennAppsal 

 

1. Have you tried reinstalling the app in the store?
2. If you don't want to try reinstalling, can you migrate the session data from the development environment to the fly.io environment together, what database are you using? You can find it in the session table of the database.

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to contact me Email Me Buy Me A Coffee
GlennAppsal
Shopify Partner
8 1 4

Have not tried to reinstall it. I am just using the SQLite default configuration that was setup in the scaffolded app. Do I need to setup a custom database for production? I’m not sure how the session work in remix

Kyle_liu
Shopify Partner
421 53 77

Can you check the session table in the sqllite data in fly.io.

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to contact me Email Me Buy Me A Coffee