Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
dependencies[] = drupal:token
is not correct, as token in D7 isn't a core module.
Tasks:
- Remove dependency declaration
Comment | File | Size | Author |
---|---|---|---|
#7 | token_example-2841202-7.patch | 759 bytes | navneet0693 |
| |||
#2 | token_example-2841202-2.patch | 960 bytes | navneet0693 |
Comments
Comment #2
navneet0693 CreditAttribution: navneet0693 as a volunteer and at QED42 commentedComment #3
navneet0693 CreditAttribution: navneet0693 as a volunteer and at QED42 commentedComment #5
navneet0693 CreditAttribution: navneet0693 as a volunteer and at QED42 commentedComment #6
Torenware CreditAttribution: Torenware as a volunteer and commentedIf you are intending to put a dependency on the Token module in Contrib, DON'T DO THAT. Examples should ONLY depend upon Drupal Core itself. Why do you need Token?
Comment #7
navneet0693 CreditAttribution: navneet0693 as a volunteer and at QED42 commentedYou are right, we can opt out from putting a dependency on token. We actually don't need it. I am removing the dependency completely ! We previously opted to enable it with the module itself to provide token browser.
Comment #8
navneet0693 CreditAttribution: navneet0693 as a volunteer and at QED42 commentedComment #9
BerdirYeah, as commented in the other issue, the current definition makes no sense. Drupal core does not have a token module, just an include file, you can not depend on that.
That means you can also remove the bogus system test dependency, which didn't make sense either, it claims that is there to have support for version dependencies, but of course if you wouldn't have that, then it wouldn't work at all and couldn' tell you that you need a newer version.
Comment #11
Mile23It's the token example. :-)
IIRC Token was in core, and then it wasn't, and then we decided to leave it in examples, or some similar decision process.
We should provide the token browser, since our goal is to educate and illustrate.
So we have a couple options: 1) Figure out the right dependency, 2) Remove the example.
Let's go with 1.
We have a couple things, however. I added the namespaced dependency as a branch fix: http://cgit.drupalcode.org/examples/commit/?h=7.x-1.x&id=2a58f549b6850da...
That branch fix passed the branch test, which is very weird, because now we have tests which are failing as a consequence: https://www.drupal.org/pift-ci-job/565769 and https://www.drupal.org/pift-ci-job/566409
We can't run a test here because, as pointed out by @Mixologic, the way project_dependencies and the composer facade work, we can't patch dependencies.
So I will push the change to token/token without review, because Drupal. :-)
Marking this as fixed. We should keep an eye on the branch test, however. I predict it will fail, because the Great Dependency Resolution Machine STILL thinks we want drupal/token. Once it fails, we'll talk to @Mixologic and he'll force that machine to update for examples, and maybe it'll all be better.
Comment #12
Mile23As predicted: Phail. https://www.drupal.org/pift-ci-job/566433
So we'll retest after the dependency machine has had a chance to think things through.
Comment #13
Mile23And now passed: https://www.drupal.org/pift-ci-job/566434
You may resume working on other issues.
Comment #14
navneet0693 CreditAttribution: navneet0693 as a volunteer and at QED42 commented@Mile23 Awesome!
Comment #15
MixologicCool. and also dang. Theres some kinda racey condition happening on first commit that changes dependencies. Its like they are one commit behind or something: I opened this to investigate: #2841222: Possible race condition in dependency calculation
Comment #16
navneet0693 CreditAttribution: navneet0693 as a volunteer and at QED42 commentedOOps, forgot to unassign.