Public

Thread: Only thing I can think of is the nix

29 Discord messages from πŸ“ - Designing/πŸ“-project-template/threads/only-thing-i-can-think-of-is-the-nix.md.

Category: πŸ“ - Designing Parent channel: #πŸ“-project-template Thread ID: 1512739634692489366

Messages: 29

message-1512740256057790485

2026-06-06T08:49:42.399+00:00 β€” Leo Moser (mole99) (@mole99)

Reply/reference

<details> <summary>Reference data</summary>
{
  "channelId": "1423348662318272592",
  "guildId": "1361349522684510449",
  "messageId": "1512739634692489366"
}
</details>

Content

<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {
    "mentions": [
      {
        "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
        "color": null,
        "discriminator": "0000",
        "id": "691780627338625077",
        "isBot": false,
        "name": "rebelmike",
        "nickname": "RebelMike",
        "roles": []
      }
    ]
  }
}
</details>

message-1512740258649870336

2026-06-06T08:49:43.017+00:00 β€” Leo Moser (mole99) (@mole99)

Content

Your flake.nix and flake.lock matches the ones in the repo? Does a `nix flake update` change anything in flake.lock?
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {}
}
</details>

message-1512740858733006949

2026-06-06T08:52:06.088+00:00 β€” RebelMike (@rebelmike)

Content

Weirdly the XOR stage ran fine on `librelane --smoke-test`
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512741036781469696

2026-06-06T08:52:48.538+00:00 β€” RebelMike (@rebelmike)

Content

`nix flake update` didn't change anything - flake.lock is still clean
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512741465149673502

2026-06-06T08:54:30.669+00:00 β€” Leo Moser (mole99) (@mole99)

Content

That's very strange. Are you running on Linux, macOS, or WSL?
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {}
}
</details>

message-1512741571718807642

2026-06-06T08:54:56.077+00:00 β€” Leo Moser (mole99) (@mole99)

Content

Can you share a reproducible with me? I can try it locally on my end.
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {}
}
</details>

message-1512742803216666735

2026-06-06T08:59:49.689+00:00 β€” RebelMike (@rebelmike)

Content

Linux, Ubuntu 24.04.  I've just tried wiping the pdk as that's the only other thing I can think of, so will see if that works

Reactions

<details> <summary>Reactions data</summary>
[
  {
    "count": 1,
    "emoji": {
      "code": "fingers_crossed",
      "id": "",
      "imageUrl": "2026-06_media/1f91e-2A114.svg",
      "isAnimated": false,
      "name": "🀞"
    },
    "users": [
      {
        "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
        "color": null,
        "discriminator": "0000",
        "id": "323371864074485771",
        "isBot": false,
        "name": "mole99",
        "nickname": "Leo Moser (mole99)"
      }
    ]
  }
]
</details><details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512744090360348792

2026-06-06T09:04:56.568+00:00 β€” RebelMike (@rebelmike)

Content

How do I create a reproducible?  Or is one already hiding in the run directory somewhere?
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512745792946044968

2026-06-06T09:11:42.496+00:00 β€” bailey (@bailey8889)

Content

@RebelMike can you try to open `/home/mdb36/wafer-space/ws02-tinyQV/librelane/runs/RUN_2026-06-06_09-45-39/56-magic-streamout/chip_top.magic.gds` in klayout?
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/0-EB806.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {
    "mentions": [
      {
        "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
        "color": null,
        "discriminator": "0000",
        "id": "691780627338625077",
        "isBot": false,
        "name": "rebelmike",
        "nickname": "RebelMike",
        "roles": []
      }
    ]
  }
}
</details>

message-1512745899644682351

2026-06-06T09:12:07.935+00:00 β€” bailey (@bailey8889)

Content

If that doesn't work, can you try in magic?
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/0-EB806.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512746963123175525

2026-06-06T09:16:21.488+00:00 β€” RebelMike (@rebelmike)

Content

Ah no - the chip_top.magic.gds is zero size - that'll do it πŸ˜„
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {
    "inlineEmojis": [
      {
        "code": "smile",
        "id": "",
        "imageUrl": "2026-06_media/1f604-BF863.svg",
        "isAnimated": false,
        "name": "πŸ˜„"
      }
    ]
  }
}
</details>

message-1512747853397758002

2026-06-06T09:19:53.746+00:00 β€” bailey (@bailey8889)

Content

Is the klayout data ok? Can you figure out why the magic gds file size is zero?
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/0-EB806.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512748074630381580

2026-06-06T09:20:46.492+00:00 β€” RebelMike (@rebelmike)

Content

```
File /home/mdb36/wafer-space/ws02-tinyQV/gf180mcu/gf180mcuD/libs.ref/gf180mcu_ocd_ip_sram/mag/pmos_5p04310591302058_3v512x8m81.mag couldn't be read
Failure to read entire subtree of the cell.
Failed on cell pmos_5p04310591302058_3v512x8m81.
```
So maybe redownloading the pdk will have fixed it?  That file is there now and looks plausible.  The design takes a while to route so it's still going
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512750413579943946

2026-06-06T09:30:04.141+00:00 β€” RebelMike (@rebelmike)

Content

No, it's failed in the exact same way.  That is very weird
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512752512325914797

2026-06-06T09:38:24.521+00:00 β€” RebelMike (@rebelmike)

Content

I have no idea why this would be different on github to locally.  I am patching the pdk with a version from the latest build artfiact in Tholin's repo, but that should be unrelated - and is done the same way on github as locally.
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512764418419851297

2026-06-06T10:25:43.155+00:00 β€” Leo Moser (mole99) (@mole99)

Content

You can try this PR: https://github.com/wafer-space/gf180mcu-project-template/pull/61
It updates the PDK to include Tholin's latest SCL updates.

Embeds

<details> <summary>Embeds data</summary>
[
  {
    "color": "#1E2327",
    "description": "",
    "fields": [],
    "images": [],
    "inlineEmojis": [],
    "timestamp": null,
    "title": "Update PDK by mole99 Β· Pull Request #61 Β· wafer-space/gf180mcu-pr...",
    "url": "https://github.com/wafer-space/gf180mcu-project-template/pull/61"
  }
]
</details><details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {}
}
</details>

message-1512774355271286895

2026-06-06T11:05:12.285+00:00 β€” RebelMike (@rebelmike)

Content

Thanks, I’m out for the day but will try this this evening. I’ll also try building the vanilla project template as logically that should also show the issue

Reactions

<details> <summary>Reactions data</summary>
[
  {
    "count": 1,
    "emoji": {
      "code": "thumbsup",
      "id": "",
      "imageUrl": "2026-06_media/1f44d-27259.svg",
      "isAnimated": false,
      "name": "πŸ‘"
    },
    "users": [
      {
        "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
        "color": null,
        "discriminator": "0000",
        "id": "323371864074485771",
        "isBot": false,
        "name": "mole99",
        "nickname": "Leo Moser (mole99)"
      }
    ]
  }
]
</details><details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512912751641628845

2026-06-06T20:15:08.551+00:00 β€” RebelMike (@rebelmike)

Content

I've upgraded to the new project template and got rid of my hacky update of the pdk - thanks!  I've verified that the vanilla project template builds ok - it does.  But on two different machines here the magic streamout fails at that point.  This is incredibly strange because the build does work on github!  My next attempt is to blow away the nix cache, clone a clean copy of my project and try that but I'm very much grasping at straws.
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512926876690288751

2026-06-06T21:11:16.225+00:00 β€” RebelMike (@rebelmike)

Content

Well unsurprisingly that didn't work.  It must be an environment thing but I can't work out what.  I'm going to see if I can get github to store the full logs from the run
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1512928409787830514

2026-06-06T21:17:21.744+00:00 β€” Leo Moser (mole99) (@mole99)

Content

Now that you are mentioning the environment, magic did have issues with the max open file descriptor limit in the past. Maybe you can try increasing that?

Reactions

<details> <summary>Reactions data</summary>
[
  {
    "count": 1,
    "emoji": {
      "code": "thumbsup",
      "id": "",
      "imageUrl": "2026-06_media/1f44d-27259.svg",
      "isAnimated": false,
      "name": "πŸ‘"
    },
    "users": [
      {
        "avatarUrl": "2026-06_media/0-EB806.png",
        "color": null,
        "discriminator": "0000",
        "id": "738396032295108721",
        "isBot": false,
        "name": "bailey8889",
        "nickname": "bailey"
      }
    ]
  }
]
</details><details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {}
}
</details>

message-1512928877289410680

2026-06-06T21:19:13.205+00:00 β€” Leo Moser (mole99) (@mole99)

Content

If that's not it, I'll send you the instructions to create the reproducible tomorrow and will give it a try on my machine.
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {}
}
</details>

message-1512933027733573744

2026-06-06T21:35:42.748+00:00 β€” RebelMike (@rebelmike)

Content

I feel like that could be it!  Running now πŸ™‚
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {
    "inlineEmojis": [
      {
        "code": "slight_smile",
        "id": "",
        "imageUrl": "2026-06_media/1f642-83E8A.svg",
        "isAnimated": false,
        "name": "πŸ™‚"
      }
    ]
  }
}
</details>

message-1512940953390940160

2026-06-06T22:07:12.372+00:00 β€” RebelMike (@rebelmike)

Content

Increasing max open file descriptors to 4k worked πŸŽ‰   Thank you!
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {
    "inlineEmojis": [
      {
        "code": "tada",
        "id": "",
        "imageUrl": "2026-06_media/1f389-5C738.svg",
        "isAnimated": false,
        "name": "πŸŽ‰"
      }
    ]
  }
}
</details>

message-1512941014598291659

2026-06-06T22:07:26.965+00:00 β€” RebelMike (@rebelmike)

Content

(Failed at the default of 1024)
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1513088068775575652

2026-06-07T07:51:47.413+00:00 β€” Leo Moser (mole99) (@mole99)

Content

This is great to hear! πŸ™Œ
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {
    "inlineEmojis": [
      {
        "code": "raised_hands",
        "id": "",
        "imageUrl": "2026-06_media/1f64c-7C820.svg",
        "isAnimated": false,
        "name": "πŸ™Œ"
      }
    ]
  }
}
</details>

message-1513088146986893402

2026-06-07T07:52:06.06+00:00 β€” Leo Moser (mole99) (@mole99)

Content

I remember now that there was a solution to the problem that I never got around to implementing πŸ˜…
Magic keeps the files open to "lock" them. Disabling this behavior using `locking disable` should solve the issue once and for all.

I opened a PR here: https://github.com/librelane/librelane/pull/959
Maybe you could give this a try with the default of 1024 descriptors.

Simply edit `flake.nix` to point to the LibreLane branch you want to use: https://github.com/wafer-space/gf180mcu-project-template/blob/7cbd17465ca1446b4daf93f543f899fb1b3489c3/flake.nix#L12
And update `flake.lock` by running `nix flake update`.
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {
    "inlineEmojis": [
      {
        "code": "sweat_smile",
        "id": "",
        "imageUrl": "2026-06_media/1f605-42B43.svg",
        "isAnimated": false,
        "name": "πŸ˜…"
      }
    ]
  }
}
</details>

message-1513092627862392923

2026-06-07T08:09:54.384+00:00 β€” RebelMike (@rebelmike)

Content

Thanks, I'll give that a try
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {}
}
</details>

message-1513101793800753212

2026-06-07T08:46:19.714+00:00 β€” RebelMike (@rebelmike)

Content

Looks like that worked πŸ™‚
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/49aaff687e56f04e7bbdedf0077bab75-7DDB4.png",
    "discriminator": "0000",
    "isBot": false
  },
  "message": {
    "inlineEmojis": [
      {
        "code": "slight_smile",
        "id": "",
        "imageUrl": "2026-06_media/1f642-83E8A.svg",
        "isAnimated": false,
        "name": "πŸ™‚"
      }
    ]
  }
}
</details>

message-1513103759100870686

2026-06-07T08:54:08.278+00:00 β€” Leo Moser (mole99) (@mole99)

Content

Thanks for testing! I'll get this merged asap.
<details> <summary>Other message metadata</summary>
{
  "author": {
    "avatarUrl": "2026-06_media/3c7c17f3225f6e56f4dccd83f14383f2-73F83.png",
    "discriminator": "0000",
    "isBot": false,
    "roles": [
      {
        "color": null,
        "id": "1423020172595298314",
        "name": "Mod",
        "position": 4
      }
    ]
  },
  "message": {}
}
</details>