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

nixos/syncthing: add versioning #73405

Merged
merged 1 commit into from
Nov 19, 2019

Conversation

mrVanDalo
Copy link
Contributor

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
Notify maintainers

cc @FRidh

@mrVanDalo mrVanDalo mentioned this pull request Nov 14, 2019
10 tasks
@ofborg ofborg bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` labels Nov 14, 2019
@FRidh
Copy link
Member

FRidh commented Nov 14, 2019

Note you can test whether the issue still occurs with

$ nix-build -A metrics pkgs/top-level/release.nix 

@mrVanDalo mrVanDalo force-pushed the feature/synthing-versioning branch 2 times, most recently from 4c86171 to 74b0495 Compare November 14, 2019 15:59
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild 10.rebuild-linux: 0 This PR does not cause any packages to rebuild labels Nov 14, 2019
@mrVanDalo
Copy link
Contributor Author

Note you can test whether the issue still occurs with

$ nix-build -A metrics pkgs/top-level/release.nix 

which issue?

@FRidh
Copy link
Member

FRidh commented Nov 14, 2019

the lack of descriptions broke the metrics job, preventing a channel from advancing

@FRidh
Copy link
Member

FRidh commented Nov 14, 2019

Basically, when changing a module, it's good not to just test the module (which I am sure you did), but also this job.

@mrVanDalo
Copy link
Contributor Author

I see, when I have some more time (I guess on Monday or Sunday), I will have a look at this metrics job. Never heard of it before, also @GrahamcOfBorg did not post anything. Is this party of https://hydra.nixos.org ? I also couldn't find any information about this in the https://github.com/NixOS/nixpkgs/blob/master/.github/CONTRIBUTING.md.

Btw I think the pull request can be merged now.

@FRidh
Copy link
Member

FRidh commented Nov 16, 2019

ofborg does not evaluate NixOS tests unfortunately. NixOS/ofborg#315
The metrics job is a channel requirement https://hydra.nixos.org/job/nixpkgs/trunk/unstable#tabs-constituents

@mrVanDalo
Copy link
Contributor Author

mrVanDalo commented Nov 17, 2019

@FRidh thank your explanation and your links. When I ran the command, you posted, in the branch of my changes, I get this error :

running nix-env -f /nix/store/xq9xlwifn82gvvkqbh6xam7sfyrx7b04-nixpkgs -qa
error: executing '': No such file or directory
{
  "cpuTime": 6.69466,
  "envs": {
    "number": 2508238,
    "elements": 6373342,
    "bytes": 91118544
  },
  "list": {
    "elements": 2231186,
    "bytes": 17849488,
    "concats": 147348
  },
  "values": {
    "number": 8350889,
    "bytes": 200421336
  },
  "symbols": {
    "number": 308128,
    "bytes": 13451059
  },
  "sets": {
    "number": 1506164,
    "bytes": 669575824,
    "elements": 27396938
  },
  "sizes": {
    "Env": 16,
    "Value": 24,
    "Bindings": 8,
    "Attr": 24
  },
  "nrOpUpdates": 897367,
  "nrOpUpdateValuesCopied": 21716914,
  "nrThunks": 6835863,
  "nrAvoided": 3856394,
  "nrLookups": 1944563,
  "nrPrimOpCalls": 895598,
  "nrFunctionCalls": 2133214,
  "gc": {
    "heapSize": 990572544,
    "totalBytes": 1272965408
  }
}
6.85user 0.64system 0:07.49elapsed 99%CPU (0avgtext+0avgdata 1448796maxresident)k
0inputs+72outputs (0major+365520minor)pagefaults 0swaps

parse error: Invalid numeric literal at line 1, column 6
builder for '/nix/store/3y9azq795wf3q99cv2zmm3szzhx6jgfp-nixpkgs-metrics.drv' failed with exit code 4
error: build of '/nix/store/3y9azq795wf3q99cv2zmm3szzhx6jgfp-nixpkgs-metrics.drv' failed

I also get this error on the current origin/master. So I expect it not to be my fault.

@FRidh
Copy link
Member

FRidh commented Nov 17, 2019

I noticed it as well, even though the test passes on Hydra! Will need to investigate this further.

Copy link
Member

@Lassulus Lassulus left a comment

Choose a reason for hiding this comment

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

so lets try this again?

@Lassulus Lassulus merged commit dcdf4ce into NixOS:master Nov 19, 2019
@mrVanDalo
Copy link
Contributor Author

looks like it worked. https://hydra.nixos.org/job/nixpkgs/trunk/metrics

@contrun
Copy link
Contributor

contrun commented Sep 24, 2021

It seems that syncthing is now using the following format

        <versioning type="staggered">
            <param key="cleanInterval" val="3600"></param>
            <param key="maxAge" val="31536000"></param>
            <cleanupIntervalS>3600</cleanupIntervalS>
            <fsPath>~/.cache/syncthing_versioning/calibre</fsPath>
            <fsType>basic</fsType>
        </versioning>

This stanza is generated from GUI. The GUI generates xml like this by pull request syncthing/syncthing#7407 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild 10.rebuild-linux: 0 This PR does not cause any packages to rebuild
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants