Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

refactor(devshell): improve devshell experience#1977

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
jfroche wants to merge52 commits intoupdate-nixpkgs
base:update-nixpkgs
Choose a base branch
Loading
fromfix/default-devshell

Conversation

@jfroche
Copy link
Collaborator

The current development shell include a large number of packages which
leads to a very large closure size (5 Gb) and slow startup times.
To improve the situation we defer installing large packages to devshell
commands which only get installed when needed.
We introduce the use of devshell to define the commands in a
declarative way as well as to improve the overall developer experience.
The closure of the default devshell is now down to 2 Gb (which still could be improved later on).

Included changes:

  • Add organized command menu with categories (check, ami, extension, postgres)
  • Add watch command using watchexec + nix-fast-build for continuous checking
  • Expose common tasks as named commands: fmt, check, lint, watch
  • Add aws-vault to development tools

yvan-sraka reacted with thumbs up emoji
jfrocheand others added30 commitsDecember 11, 2025 17:17
These overlay packages will be removed once the extensions are updatedto use the new `buildPgrxExtension` function.
The previously used version was failing to build:/build/source/src/common/get_check_data.c: In function 'pgr_SPI_getText':/build/source/src/common/get_check_data.c:307:28: error: passing argument 1 of 'DatumGetCString' makes integer from pointer without a cast [-Wint-conversion]  307 |     return DatumGetCString(SPI_getvalue(*tuple, *tupdesc, info.colNumber));      |                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~      |                            |      |                            char *In file included from /build/source/include/c_common/postgres_connection.h:29,                 from /build/source/src/common/get_check_data.c:27:/nix/store/nn6vpjqlsxxmynwcrsib9agb3hpr5cqj-postgresql-17.4/include/server/postgres.h:335:23: note: expected 'Datum' {aka 'long unsigned int'} but argument is of type 'char *'  335 | DatumGetCString(Datum X)      |                 ~~~~~~^make[2]: *** [src/common/CMakeFiles/common.dir/build.make:149: src/common/CMakeFiles/common.dir/get_check_data.c.o] Error 1
We cannot use nodejs.libv8 as it is too new for plv8 3.1.We will be able to use it with plv8 3.2.
dbmate 2.27 is now using a varchar for the version column in theschema_migrations table.Seeamacneil/dbmate#641
Updated nixpkgs, rust-overlay, and nix-fast-build to latest versions.
Removed duplicate substituteInPlace calls that were redundantly applied during previous merge operations. Cleaned up the patch application to avoid duplicate substitutions.
yvan-srakaand others added20 commitsDecember 11, 2025 17:17
Updated cargo-pgrx buildPgrxExtension with rustc wrapper to handle emptypostmaster_stub.rs files that cause duplicate symbol errors.(first two filenames are `` and`/build/tmp.*/postmaster_stubs/nix/store/*/bin/postmaster_stub.rs`)pg_jsonschema cargo checks fails on specific versions (0.2.0, 0.3.1, 0.3.3).
Remove deprecated functions that were removed in newer pgrouting versions(_pgr_betweennesscentrality and _pgr_contractionhierarchies).
Improves reproducibility and avoids evaluation-time network access byusing a proper flake input instead of fetchTarball for the older nixpkgsneeded by pg_net and plv8.
…64-darwinVersion 0.19.5 has a dangling pointer issue in src/core.c:177 that causescompilation to fail on aarch64-darwin with newer clang versions. This adds-Wno-error=dangling-assignment to allow compilation to proceed.The flag is restricted to aarch64-darwin only since GCC on Linux doesn'trecognize this warning option.
Add -headerpad_max_install_names linker flag to prevent 'install_name_tool:changing install names or rpaths can't be redone' errors on macOS. Thisallocates sufficient header space for install_name_tool to modify theshared library during post-install processing.
… extensionsTest assertions were inconsistent: expecting {version}.so and {extension_name}-{version}.sopatterns while actual libraries use {lib_name}-{version}.so (e.g. pg_partman_bgw-5.3.1.so,timescaledb-loader-2.16.1.so). Updated PostgresExtensionTest to accept Optional[str] lib_nameparameter and use consistent {lib_name}-{version}.so assertions throughout.Added missing timescaledb-loader.so symlink creation and updated the switch script tomaintain both symlinks when switching versions.Fixes 'Expected timescaledb version 2.16.1, but found timescaledb-loader-2.16.1.so' and'Expected pg_partman version 5.3.1, but found pg_partman_bgw-5.3.1.so' test failures.
Use overlay instead of passing full nixpkgs-oldstable to avoid exposingentire old nixpkgs attribute set. Now provides specific packages(curl_8_4, v8_oldstable) through overlay.
Keep revision support that was accidentally simplified during nixpkgs update.Restores conditional logic to support building orioledb from specific gitrevision hashes instead of only tags.
These files were moved to subdirectories and the old .nix files should beremoved since they were moved to new directory structure with default.nix files.
Remove nixpkgs-go124 dependency since current nixpkgs has Go 1.25.4which is sufficient for packer. Remove nix-fast-build input as unusedand add follows directives to resolve duplicate dependencies.
Run flake-linter to eliminate duplicate dependencies, and remove unusedcargo-pgrx / rustc versions hashes.
Move pgrouting.nix to pgrouting/default.nix and groonga package topgroonga/groonga.nix. Update imports and fix relative paths for versions.jsonand patch files.
Replace inline bash script generation with writeShellScriptBin for rustcwrapper that filters empty postmaster_stub.rs arguments. Apply wrapper onlyfor pgrx < 0.12 since issue was fixed upstream in pgrx#1435 and pgrx#1441.
Move nixpkgs-oldstable import to a let binding to avoid importing itthree times...
Remove supabase-groonga from global flake packages and import it locallyin pgroonga extension instead. Other components access groonga viapgroonga.passthru.groonga since groonga is only used by pgroonga.
The current development shell include a large number of packages whichleads to a very large closure size (5 Gb) and slow startup times.To improve the situation we defer installing large packages to devshellcommands which only get installed when needed.We introduce the use of devshell to define the commands in adeclarative way as well as to improve the overall developer experience.Included changes:- Add organized command menu with categories (check, ami, extension, postgres)- Add watch command using watchexec + nix-fast-build for continuous checking- Expose common tasks as named commands: fmt, check, lint, watch- Add aws-vault to development tools
`writeShellApplication` avoids substitute commands, provides the correctpackage metadata and make sure that all scripts are shellcheked.
We don't need to maintain our own packer package anymore since we areusing a recently updated nixpkgs that includes packer.
@jfrochejfroche requested review froma team ascode ownersDecember 11, 2025 22:47
@yvan-srakayvan-sraka requested a review froma team as acode ownerDecember 12, 2025 09:06
@yvan-srakayvan-srakaforce-pushed theupdate-nixpkgs branch 2 times, most recently fromb48e4c3 to3df6c4aCompareDecember 12, 2025 10:07
Copy link
Collaborator

@samrosesamrose left a comment

Choose a reason for hiding this comment

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

let's hold off on this one until we complete nixpkgs update and some of our other critical items. We can definitely try to do this one, but we may need adjust a few things, and document it a bit more as well

@samrosesamroseforce-pushed theupdate-nixpkgs branch 3 times, most recently from771718f to4e32d5bCompareDecember 17, 2025 19:36
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@samrosesamrosesamrose requested changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

4 participants

@jfroche@samrose@yvan-sraka

[8]ページ先頭

©2009-2025 Movatter.jp