Skip to content

Fix dynaconf's django integration#7892

Merged
ggainey merged 1 commit into
pulp:3.115from
pedro-psb:experiment-hotfix
Jul 21, 2026
Merged

Fix dynaconf's django integration#7892
ggainey merged 1 commit into
pulp:3.115from
pedro-psb:experiment-hotfix

Conversation

@pedro-psb

@pedro-psb pedro-psb commented Jul 21, 2026

Copy link
Copy Markdown
Member

Apparently it works if we follow the docs instructions to not set anything after the integration code. I'm probably the number one to blame on not having taken that seriously enough 🙈

Test PR: pulp/pulp_rpm#4521

📜 Checklist

  • Commits are cleanly separated with meaningful messages (simple features and bug fixes should be squashed to one commit)
  • A changelog entry or entries has been added for any significant changes
  • Follows the Pulp policy on AI Usage
  • (For new features) - User documentation and test coverage has been added

See: Pull Request Walkthrough

@pedro-psb
pedro-psb force-pushed the experiment-hotfix branch 3 times, most recently from 6b2ed2d to 6a940f2 Compare July 21, 2026 21:42
Comment thread pulpcore/app/settings.py
file=settings.DB_ENCRYPTION_KEY, err=ex
)
)
return {}

@pedro-psb pedro-psb Jul 21, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

In general, if on setting depend on another setting, it should be inside a hook, and not after the dynaconf instantiation. For instance, FORBIDDEN_CHECKSUMS was not picking up the user provided ALLOWED_CONTENT_CHECKSUMS.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Didn't realize this was a PR on 3.115 - we need this on main, please

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yeah, I should have opened against main and then added the backport label.
Was caught in moment.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@pedro-psb
pedro-psb force-pushed the experiment-hotfix branch 2 times, most recently from 41ad4d4 to c22c750 Compare July 21, 2026 22:06
Thre should be no settings activity after dyanconf's instantiation.

Assisted-by: Claude (Claude Code)
@pedro-psb
pedro-psb force-pushed the experiment-hotfix branch from c22c750 to 0a06d30 Compare July 21, 2026 22:08
@pedro-psb
pedro-psb marked this pull request as ready for review July 21, 2026 22:10

@ggainey ggainey left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Great catch - and much cleaner than we were!

@ggainey
ggainey merged commit 3f395c1 into pulp:3.115 Jul 21, 2026
14 checks passed
@patchback

patchback Bot commented Jul 21, 2026

Copy link
Copy Markdown

Backport to 3.115: 💔 cherry-picking failed — conflicts found

❌ Failed to cleanly apply 3f395c1 on top of patchback/backports/3.115/3f395c1d25effcab0a5a69cc2d96b52cf559f42f/pr-7892

Backporting merged PR #7892 into 3.115

  1. Ensure you have a local repo clone of your fork. Unless you cloned it
    from the upstream, this would be your origin remote.
  2. Make sure you have an upstream repo added as a remote too. In these
    instructions you'll refer to it by the name upstream. If you don't
    have it, here's how you can add it:
    $ git remote add upstream https://github.com/pulp/pulpcore.git
  3. Ensure you have the latest copy of upstream and prepare a branch
    that will hold the backported code:
    $ git fetch upstream
    $ git checkout -b patchback/backports/3.115/3f395c1d25effcab0a5a69cc2d96b52cf559f42f/pr-7892 upstream/3.115
  4. Now, cherry-pick PR Fix dynaconf's django integration #7892 contents into that branch:
    $ git cherry-pick -x 3f395c1d25effcab0a5a69cc2d96b52cf559f42f
    If it'll yell at you with something like fatal: Commit 3f395c1d25effcab0a5a69cc2d96b52cf559f42f is a merge but no -m option was given., add -m 1 as follows instead:
    $ git cherry-pick -m1 -x 3f395c1d25effcab0a5a69cc2d96b52cf559f42f
  5. At this point, you'll probably encounter some merge conflicts. You must
    resolve them in to preserve the patch from PR Fix dynaconf's django integration #7892 as close to the
    original as possible.
  6. Push this branch to your fork on GitHub:
    $ git push origin patchback/backports/3.115/3f395c1d25effcab0a5a69cc2d96b52cf559f42f/pr-7892
  7. Create a PR, ensure that the CI is green. If it's not — update it so that
    the tests and any other checks pass. This is it!
    Now relax and wait for the maintainers to process your pull request
    when they have some cycles to do reviews. Don't worry — they'll tell you if
    any improvements are necessary when the time comes!

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

@ggainey

ggainey commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Backport to 3.115: 💔 cherry-picking failed — conflicts found

Can't backport to 3.115 when it's on 3.115 - who knew?!? :)

@pedro-psb
pedro-psb deleted the experiment-hotfix branch July 22, 2026 10:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants