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

Couldn't Save [anything] after clean install #176

Closed
MattWilcox opened this issue Sep 28, 2020 · 9 comments
Closed

Couldn't Save [anything] after clean install #176

MattWilcox opened this issue Sep 28, 2020 · 9 comments
Labels
bug Something isn't working

Comments

@MattWilcox
Copy link

MattWilcox commented Sep 28, 2020

Describe the bug

Unable to save any Settings.

To reproduce

Install a new copy of the plugin, go to the settings page. Hit save.
"Couldn't save" flash warning. Happens for all settings panes, regardless of what values are in there.

We often have an issue on our local environment with permissions; but our classic sudo chmod -R 777 vendor/ storage/ config/ composer.* does not fix this issue.

Versions

  • Plugin version: 1.15.7
  • Craft version: Craft Pro 3.5.11.1

web.log

Is attached; emptied it out before just hitting the Save button.
web.log

@MattWilcox MattWilcox added the bug Something isn't working label Sep 28, 2020
@bencroker
Copy link
Collaborator

Are you perhaps using a campaign.php config file to override any required settings? Do any of the settings panes show required fields (with a red asterisk) that are blank?

@MattWilcox
Copy link
Author

Nope not yet - this is a clean install. First time I've used the plugin so literally; installed, clicked the link in the welcome screen, tried to toggle "test mode" on... error. So toggled it back off and tried saving again. Error.

@MattWilcox
Copy link
Author

MattWilcox commented Sep 28, 2020

No red required fields anywhere.
I have a warning about using @web in an Asset volume, the Email Settings > From Names and Emails are pre-populated with $SENDER_NAME and $SYSTEM_EMAIL_ADDRESS which... may be the issue? I'm not sure those are set in my .env files... Yes, they are.

@MattWilcox
Copy link
Author

Wait, I can get a red message. If I go to Email Settings and change nothing, but hit save there; I get "invalid Email was entered" - this does not show as a red message if I try saving in General Settings, so I'm guessing the red messages only appear when you try to save on a specific section - but may be blocking all other saves?

Regardless; the pre-populated value there is $SYSTEM_EMAIL_ADDRESS which exists in my .env and maps to a value of "website@REDACTED.website.local" ... which has been fine elsewhere in Craft wherever that's used. Or at least, hasn't produced any visible errors.

@MattWilcox
Copy link
Author

MattWilcox commented Sep 28, 2020

Huh. I replaced those placeholder environment variables with plain strings and it's worked.

Looks like the plugin is not parsing the variables and just breaks seeing them as strings. So, either a glitch in the default configuration to include those env variables, or a glitch with the plugin not parsing those fields.

@bencroker
Copy link
Collaborator

bencroker commented Sep 28, 2020

Ah so when using environment variables it probably wasn't parsing them correctly when validating, checking this now.

@MattWilcox
Copy link
Author

Yep, that's what it looks like - but that's how it's shipping out of the box with those variables pre-populated in the Email Settings row. Ok - sorted for me then, cheers!

@bencroker
Copy link
Collaborator

Fixed in a3bc590 for the next release, thanks!

@bencroker
Copy link
Collaborator

Released in version 1.16.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants