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

ucm presents out-of-date current namespace to user #4921

Open
aryairani opened this issue May 7, 2024 · 0 comments
Open

ucm presents out-of-date current namespace to user #4921

aryairani opened this issue May 7, 2024 · 0 comments
Labels

Comments

@aryairani
Copy link
Contributor

aryairani commented May 7, 2024

Downloadable transcript:
https://gist.github.com/aryairani/7d6ab9b6d35b8f9ce45a9540c73ac148
This reproduction requires #4910.

It shouldn't say "old foo - old foo" at the end, but it does. However, if you were to close and reopen ucm, and display bar again, it would correctly say "new foo - new foo", I'm told.

Input:

## Simple update propagation

Updates that occur in one branch are propagated to the other. In this example, Alice updates `foo`, while Bob adds a new dependent `bar` of the original `foo`. When Bob's branch is merged into Alice's, her update to `foo` is propagated to his `bar`.

```ucm:hide
.> project.create-empty project
project/main> builtins.mergeio
```

Original branch:
```unison:hide
foo : Text
foo = "old foo"
```

```ucm:hide
project/main> add
project/main> branch alice
```

Alice's updates:
```unison:hide
foo : Text
foo = "new foo"
```

```ucm:hide
project/alice> update
project/main> branch bob
```

Bob's adds:
```unison:hide
bar : Text
bar = foo ++ " - " ++ foo
```
```ucm
project/bob> display bar
```

```ucm:hide
project/bob> add
```
Merge result:
```ucm
project/alice> merge /bob
project/alice> view foo bar
project/alice> display bar
```

```ucm:hide
.> project.delete project
```

Output:

## Simple update propagation

Updates that occur in one branch are propagated to the other. In this example, Alice updates `foo`, while Bob adds a new dependent `bar` of the original `foo`. When Bob's branch is merged into Alice's, her update to `foo` is propagated to his `bar`.

Original branch:
```unison
foo : Text
foo = "old foo"
```

Alice's updates:
```unison
foo : Text
foo = "new foo"
```

Bob's adds:
```unison
bar : Text
bar = foo ++ " - " ++ foo
```

```ucm
project/bob> display bar

  "old foo - old foo"

```
Merge result:
```ucm
project/alice> merge /bob

  I merged bob into alice.

project/alice> view foo bar

  bar : Text
  bar =
    use Text ++
    foo ++ " - " ++ foo
  
  foo : Text
  foo = "new foo"

project/alice> display bar

  "old foo - old foo"

```
@aryairani aryairani added the bug label May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant