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

Merge upstream changes up to 3554c527954441fd924586a49c7d99a89101ac7e #2339

Merged
merged 101 commits into from
Jul 30, 2023

Conversation

ClearlyClaire
Copy link

@ClearlyClaire ClearlyClaire commented Jul 30, 2023

This one includes many redesigns to the vanilla UI (which were, for the most part, not applied to the glitch flavor yet), as well as a new interaction modal, and a few important bugfixes.

Postponed changes (recap)

Merge upstream changes up to 1e3b192

Conflicts

  • app/models/account.rb:
    Upstream added new validations close to lines on which glitch-soc had modified validations to handle custom limits set through environment variables.
    Ported upstream changes.
  • config/initializers/content_security_policy.rb:
    Upstream added AZURE_ALIAS_HOST. Glitch-soc's version of the file is completely different.
    Added AZURE_ALIAS_HOST to our version of the file.

Ported changes

Merge upstream changes up to 144a406

Conflicts

  • app/views/layouts/application.html.haml:
    Upstream removed the crossorigin attribute from preload_pack_asset. Glitch-soc had different calls to preload_pack_asset because of the different theming system.
    Ported the change.
  • app/views/layouts/embedded.html.haml:
    Upstream removed the crossorigin attribute from preload_pack_asset. Glitch-soc had different calls to preload_pack_asset because of the different theming system.
    Ported the change.

Merge upstream changes up to 5b45796

Conflicts

  • config/initializers/content_security_policy.rb:
    Upstream fixed an issue that was not present in glitch-soc.
    Kept our version.

Ported changes

Postponed changes

Merge upstream changes up to cfd50f3

Conflicts

None

Ported changes

Postponed changes

Merge upstream changes up to ce1f35d

Conflicts

  • db/schema.rb:
    Upstream regenerated the schema file using Rails 7, the conflicts are caused by our extra columns.
    Applied upstream's changes, but keeping our extra columns.

Ported changes

Postponed changes

  • 4d01d1a not sure this is a good idea (16:9 cropping)
  • 6b2952d too much I dislike in this for now (link previews redesign)
  • 4299208 follow-up to 6b2952d (link previews redesign)

Skipped changes

Merge upstream changes up to 1814990

Conflicts

None

Ported changes

Merge upstream changes up to 3554c52

Conflicts

  • app/controllers/authorize_interactions_controller.rb:
    Small conflict due to our theming system.
  • streaming/index.js:
    Upstream refactored part of the streaming server. We had some extra logic for handling local-only posts.
    Applied the refactor.

Additional changes

Ported changes

Postponed changes

  • bbea052 (emoji picker fix, dependent on onboarding changes)
  • 1e4ccc6 (role badges redesign)

mjankowski and others added 30 commits July 19, 2023 08:44
ClearlyClaire and others added 7 commits July 30, 2023 15:54
…oc/merge-upstream

Conflicts:
- `app/controllers/authorize_interactions_controller.rb`:
  Small conflict due to our theming system.
- `streaming/index.js`:
  Upstream refactored part of the streaming server.
  We had some extra logic for handling local-only posts.
  Applied the refactor.
Port b4e739f to glitch-soc

Co-authored-by: Eugen Rochko <[email protected]>
Signed-off-by: Claire <[email protected]>
@ClearlyClaire ClearlyClaire changed the title Merge upstream changes Merge upstream changes up to 3554c527954441fd924586a49c7d99a89101ac7e Jul 30, 2023
@ClearlyClaire ClearlyClaire marked this pull request as ready for review July 30, 2023 15:36
@Plastikmensch
Copy link

I think some CSS is missing/broken with the new interaction modal:

Screenshot_2023-07-30_18-01-47

@ClearlyClaire
Copy link
Author

You're right 😩

Seems like it's using the search popout redesign…

@Plastikmensch
Copy link

You're right 😩

Seems like it's using the search popout redesign…

In that case merging #2333 first would solve that.
Or it could be postponed.

Copy link

@Plastikmensch Plastikmensch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GitHub is incredibly unresponsive for me and some changes I can't really test for, but everything seems to work.

Not sure I like the interaction modal querying the peers api when it's disabled, but that's an upstream issue.

Oh wait, the "Take me home" button doesn't seem to do anything.
Seems like a script is blocked by CSP.
Not sure if that's a dev vs prod thing again though.

@ClearlyClaire
Copy link
Author

Oh wait, the "Take me home" button doesn't seem to do anything.
Seems like a script is blocked by CSP.
Not sure if that's a dev vs prod thing again though.

I'm not able to reproduce this. What's the error?

@Plastikmensch
Copy link

Plastikmensch commented Jul 30, 2023

I'm not able to reproduce this. What's the error?

Refused to load the script 'http://localhost:3000/packs/js/common-bbc7fe25912a9e972eea.js'
because it violates the following Content Security Policy directive: "default-src 'none'".
Note that 'script-src-elem' was not explicitly set, so 'default-src' is used as a fallback.

Refused to load the script 'http://localhost:3000/packs/js/core/remote_interaction_helper-1b9b83882afd9c767fc3.chunk.js'
because it violates the following Content Security Policy directive: "default-src 'none'".
Note that 'script-src-elem' was not explicitly set, so 'default-src' is used as a fallback.

Then it's probably a dev vs prod thing again...
Thank you for looking into it though.

And also for skipping some of the design regressions.

@ClearlyClaire
Copy link
Author

Ah, this may very well be a dev env thing, unlike upstream we don't set a default CSP in the development environment, so the override will disable everything, and there is no default script-src to fall back to.

We may want to reuse upstream's CSP definition at some point…

@ClearlyClaire ClearlyClaire merged commit e96a904 into glitch-soc:main Jul 30, 2023
35 of 36 checks passed
@Plastikmensch
Copy link

Plastikmensch commented Jul 30, 2023

Sorry, I missed that, but 09ebf7e should've been also applied to app/javascript/flavours/glitch/features/ui/components/favourite_modal.jsx

It makes no functional difference and the check-i18n workflow is broken anyway, but I wanted to mention it.

Another thing I missed because of GitHub's unresponsiveness is that aa1789f added .orig files. I don't think that was intentional?

@Leatherface75
Copy link

Anyone else getting 500 error after latest upstream update?
When i revert back it works as it should again.

@ClearlyClaire
Copy link
Author

As always, when getting 500 errors, look at mastodon-web logs.

@Leatherface75
Copy link

Tried so see in logs from systemd but didn't find anything useful but i can check again later.

@ClearlyClaire
Copy link
Author

The most likely reason is that you forgot to run database migrations, but the errors will shed more light! On 500 errors, what you want to look at is journalctl -u mastodon-web

@Leatherface75
Copy link

Leatherface75 commented Aug 11, 2023

The most likely reason is that you forgot to run database migrations, but the errors will shed more light! On 500 errors, what you want to look at is journalctl -u mastodon-web

Well if that was needed then you're right that's probably the reason.
I thought it was only needed in next big update upstream.

I just did this

bundle install
yarn install
RAILS_ENV=production bundle exec rails assets:precompile

@Leatherface75
Copy link

Ok it seems to work not thanks for the help.

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

Successfully merging this pull request may close these issues.