This repository was archived by the owner on Sep 11, 2024. It is now read-only.
  
  
  - 
          
 - 
                Notifications
    
You must be signed in to change notification settings  - Fork 815
 
Ask to refresh timeline when historical messages are imported (MSC2716) #8354
          
     Closed
      
      
            MadLittleMods
  wants to merge
  85
  commits into
  develop
from
madlittlemods/refresh-timeline-when-we-see-msc2716-marker-events-v2
  
      
      
   
      
    
  
     Closed
                    Changes from all commits
      Commits
    
    
            Show all changes
          
          
            85 commits
          
        
        Select commit
          Hold shift + click to select a range
      
      66ea757
              
                Ask to refresh timeline when historical messages are imported (MSC2716)
              
              
                MadLittleMods 6dba3df
              
                Back to false after getting screenshot
              
              
                MadLittleMods 12b0115
              
                Fix lints
              
              
                MadLittleMods eb5e899
              
                Fix room not showing refresh timeline banner if not switched to the r…
              
              
                MadLittleMods a50e011
              
                Fix type lints
              
              
                MadLittleMods ed910bb
              
                Remove parenthesis change
              
              
                MadLittleMods 8d61226
              
                Raw refreshLiveTimeline usage that seems to work
              
              
                MadLittleMods d8f94ed
              
                Clean up raw commit
              
              
                MadLittleMods c43d309
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods 623960b
              
                Clean up event usage
              
              
                MadLittleMods d9001ce
              
                Remove unreadable image descriptions
              
              
                MadLittleMods b4c81e1
              
                Fix up lints
              
              
                MadLittleMods 361675e
              
                Add tests for RoomStatusBar
              
              
                MadLittleMods bf8555f
              
                Fix lints
              
              
                MadLittleMods 886b676
              
                Fix lints
              
              
                MadLittleMods 65cacbb
              
                Match case of other room events
              
              
                MadLittleMods cef6d3c
              
                Add types and fix up mis-type
              
              
                MadLittleMods f571107
              
                Fix snapshots with using string value case
              
              
                MadLittleMods a926252
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods c2895ff
              
                WIP: Cypress tests
              
              
                MadLittleMods f580947
              
                Register virtual users
              
              
                MadLittleMods 4c53f34
              
                All assertions
              
              
                MadLittleMods ee10ae2
              
                Best practice Cypress test selectors
              
              
                MadLittleMods 2bdb165
              
                Don't assert text that could change
              
              
                MadLittleMods 64e7e28
              
                Send live events sequentially to avoid them all having the same depth
              
              
                MadLittleMods 6dbe331
              
                Better self describing message
              
              
                MadLittleMods 18adde8
              
                Use function scoped to the tests where it is only used
              
              
                MadLittleMods a661bf6
              
                WIP: Test to make sure racing sync that resolve before /context finis…
              
              
                MadLittleMods ae5338d
              
                The racey sync test does pass, not sure if testing the right thing
              
              
                MadLittleMods f9a525c
              
                Better comments and state of things
              
              
                MadLittleMods b45be5b
              
                More robust to failurse and user feedback
              
              
                MadLittleMods c14cc18
              
                All Cypress tests passing
              
              
                MadLittleMods 5286641
              
                Some test cleanup
              
              
                MadLittleMods 9ae6483
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods 7848501
              
                Fix some lints
              
              
                MadLittleMods 47ecf3b
              
                Remove unused import
              
              
                MadLittleMods 2ef47f9
              
                Fix unexpected 'this' lints
              
              
                MadLittleMods e9861c7
              
                Smaller padding
              
              
                MadLittleMods 54268ba
              
                Better comment
              
              
                MadLittleMods 3defe30
              
                Update snapshots
              
              
                MadLittleMods 8461a96
              
                Add test for refreshing the timeline multiple times
              
              
                MadLittleMods 4af71c2
              
                Add context into intercepted request error so it's more obvious why y…
              
              
                MadLittleMods 0dae43e
              
                Fill in comment doc
              
              
                MadLittleMods e75d92a
              
                Update spapshots after removing last marker processed from js-sdk
              
              
                MadLittleMods b7eb441
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods 7eb0576
              
                Add comments describing why mxSettingsStore is useful
              
              
                MadLittleMods 8ed948d
              
                Fix being able to reference Preset
              
              
                MadLittleMods 75fc3d4
              
                Save the file
              
              
                MadLittleMods 1f4d3b5
              
                Comment out so typescript doesn't go as crazy. Still need to solve th…
              
              
                MadLittleMods 17d3203
              
                Remove debug logging
              
              
                MadLittleMods 0c5c0b5
              
                Add comment doc to test functions
              
              
                MadLittleMods 641d37c
              
                Add snapshot tests for error states
              
              
                MadLittleMods daa0ca7
              
                Fix lints
              
              
                MadLittleMods 6c7df4e
              
                Use correct public_baseurl (COPYME template is wrong)
              
              
                MadLittleMods 0fac6b2
              
                Only getBot should respond to invites by joining the room
              
              
                MadLittleMods fc0d474
              
                Use spacing variables
              
              
                MadLittleMods 0c89bcb
              
                Type unintitialized variable
              
              
                MadLittleMods 2008696
              
                Fix minor spacing typo in comments
              
              
                MadLittleMods 34ebd08
              
                Make sure sentences are properly spaced apart
              
              
                MadLittleMods df0522c
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods b9c86ca
              
                Some type cleanup
              
              
                MadLittleMods 9d7eec3
              
                Update from Modal.createTrackedDialog to Modal.createDialog
              
              
                MadLittleMods 32952e3
              
                Update snapshots with Matrix client changes
              
              
                MadLittleMods 7b5ee36
              
                Fix markerEventId typo
              
              
                MadLittleMods 0e923b7
              
                Fix eventIdWhileRefrshingTimeline typo
              
              
                MadLittleMods c9270d8
              
                Add test when we fail to refresh and latest event is a threaded message
              
              
                MadLittleMods b44f6a1
              
                Remove the test only
              
              
                MadLittleMods ac998bd
              
                Use fire-forget pattern
              
              
                MadLittleMods 50da54e
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods bbc060f
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods c6e91a1
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods 8c78dd5
              
                Make test more robust
              
              
                MadLittleMods 3d259de
              
                Fix joinRoom duplication
              
              
                MadLittleMods e64e59b
              
                Fix duplicate command
              
              
                MadLittleMods 1ff2c78
              
                Fix some lints
              
              
                MadLittleMods ef58f45
              
                Migrate away from enzyme
              
              
                MadLittleMods 012d27f
              
                Fix more strict errors
              
              
                MadLittleMods d2e300b
              
                Update i18n
              
              
                MadLittleMods eb815cc
              
                Workaround lint
              
              
                MadLittleMods b9cd0a6
              
                More strict lints
              
              
                MadLittleMods 43f90f6
              
                Use supported room version
              
              
                MadLittleMods 131af45
              
                Fix lints
              
              
                MadLittleMods 280ddb5
              
                Fix `Error: TypeError: (0 , _jestMock.mocked)(...).mockReturnValue is…
              
              
                MadLittleMods 1726830
              
                Update snapshots with small change and lots of quote escaping differe…
              
              
                MadLittleMods 939a6ef
              
                Merge branch 'develop' into madlittlemods/refresh-timeline-when-we-se…
              
              
                MadLittleMods File filter
Filter by extension
Conversations
          Failed to load comments.   
        
        
          
      Loading
        
  Jump to
        
          Jump to file
        
      
      
          Failed to load files.   
        
        
          
      Loading
        
  Diff view
Diff view
There are no files selected for viewing
        
          
  
    
      
          
            819 changes: 819 additions & 0 deletions
          
          819 
        
  cypress/e2e/x-msc2716-historical-import/historical-import.spec.ts
  
  
      
      
   
        
      
      
    Large diffs are not rendered by default.
      
      Oops, something went wrong.
      
    
  
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
        
          
  
    
      
          
            1 change: 1 addition & 0 deletions
          
          1 
        
  cypress/plugins/synapsedocker/templates/msc2716-historical-import/README.md
  
  
      
      
   
        
      
      
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1 @@ | ||
| Start Synapse with `msc2716_enabled` and an application service configured | 
        
          
  
    
      
          
            16 changes: 16 additions & 0 deletions
          
          16 
        
  cypress/plugins/synapsedocker/templates/msc2716-historical-import/as-registration.yaml
  
  
      
      
   
        
      
      
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| id: my_application_service_id | ||
| hs_token: hs_token123 | ||
| as_token: as_token123 | ||
| url: 'http://localhost:0000' | ||
| sender_localpart: gitter-badger | ||
| namespaces: | ||
| users: | ||
| - exclusive: false | ||
| regex: .* | ||
| aliases: | ||
| - exclusive: false | ||
| regex: .* | ||
| rooms: | ||
| - exclusive: false | ||
| regex: .* | ||
| rate_limited: false | 
        
          
  
    
      
          
            80 changes: 80 additions & 0 deletions
          
          80 
        
  cypress/plugins/synapsedocker/templates/msc2716-historical-import/homeserver.yaml
  
  
      
      
   
        
      
      
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,80 @@ | ||
| server_name: "localhost" | ||
| pid_file: /data/homeserver.pid | ||
| # XXX: This won't actually be right: it lets docker allocate an ephemeral port, | ||
| # so we have a chicken-and-egg problem | ||
| public_baseurl: "{{PUBLIC_BASEURL}}" | ||
| # Listener is always port 8008 (configured in the container) | ||
| listeners: | ||
| - port: 8008 | ||
| tls: false | ||
| bind_addresses: ['::'] | ||
| type: http | ||
| x_forwarded: true | ||
| 
     | 
||
| resources: | ||
| - names: [client, federation] | ||
| compress: false | ||
| 
     | 
||
| # An sqlite in-memory database is fast & automatically wipes each time | ||
| database: | ||
| name: "sqlite3" | ||
| args: | ||
| database: ":memory:" | ||
| 
     | 
||
| # Needs to be configured to log to the console like a good docker process | ||
| log_config: "/data/log.config" | ||
| 
     | 
||
| rc_messages_per_second: 10000 | ||
| rc_message_burst_count: 10000 | ||
| rc_registration: | ||
| per_second: 10000 | ||
| burst_count: 10000 | ||
| 
     | 
||
| rc_login: | ||
| address: | ||
| per_second: 10000 | ||
| burst_count: 10000 | ||
| account: | ||
| per_second: 10000 | ||
| burst_count: 10000 | ||
| failed_attempts: | ||
| per_second: 10000 | ||
| burst_count: 10000 | ||
| 
     | 
||
| media_store_path: "/data/media_store" | ||
| uploads_path: "/data/uploads" | ||
| enable_registration: true | ||
| enable_registration_without_verification: true | ||
| disable_msisdn_registration: false | ||
| # These placeholders will be be replaced with values generated at start | ||
| registration_shared_secret: "{{REGISTRATION_SECRET}}" | ||
| report_stats: false | ||
| macaroon_secret_key: "{{MACAROON_SECRET_KEY}}" | ||
| form_secret: "{{FORM_SECRET}}" | ||
| # Signing key must be here: it will be generated to this file | ||
| signing_key_path: "/data/localhost.signing.key" | ||
| email: | ||
| enable_notifs: false | ||
| smtp_host: "localhost" | ||
| smtp_port: 25 | ||
| smtp_user: "exampleusername" | ||
| smtp_pass: "examplepassword" | ||
| require_transport_security: False | ||
| notif_from: "Your Friendly %(app)s homeserver <[email protected]>" | ||
| app_name: Matrix | ||
| notif_template_html: notif_mail.html | ||
| notif_template_text: notif_mail.txt | ||
| notif_for_new_users: True | ||
| client_base_url: "http://localhost/element" | ||
| 
     | 
||
| trusted_key_servers: | ||
| - server_name: "matrix.org" | ||
| suppress_key_server_warning: true | ||
| 
     | 
||
| # A list of application service config files to use | ||
| # | ||
| app_service_config_files: | ||
| - /data/as-registration.yaml | ||
| 
     | 
||
| experimental_features: | ||
| msc2716_enabled: true | 
        
          
  
    
      
          
            50 changes: 50 additions & 0 deletions
          
          50 
        
  cypress/plugins/synapsedocker/templates/msc2716-historical-import/log.config
  
  
      
      
   
        
      
      
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| # Log configuration for Synapse. | ||
| # | ||
| # This is a YAML file containing a standard Python logging configuration | ||
| # dictionary. See [1] for details on the valid settings. | ||
| # | ||
| # Synapse also supports structured logging for machine readable logs which can | ||
| # be ingested by ELK stacks. See [2] for details. | ||
| # | ||
| # [1]: https://docs.python.org/3.7/library/logging.config.html#configuration-dictionary-schema | ||
| # [2]: https://matrix-org.github.io/synapse/latest/structured_logging.html | ||
| 
     | 
||
| version: 1 | ||
| 
     | 
||
| formatters: | ||
| precise: | ||
| format: '%(asctime)s - %(name)s - %(lineno)d - %(levelname)s - %(request)s - %(message)s' | ||
| 
     | 
||
| handlers: | ||
| # A handler that writes logs to stderr. Unused by default, but can be used | ||
| # instead of "buffer" and "file" in the logger handlers. | ||
| console: | ||
| class: logging.StreamHandler | ||
| formatter: precise | ||
| 
     | 
||
| loggers: | ||
| synapse.storage.SQL: | ||
| # beware: increasing this to DEBUG will make synapse log sensitive | ||
| # information such as access tokens. | ||
| level: INFO | ||
| 
     | 
||
| twisted: | ||
| # We send the twisted logging directly to the file handler, | ||
| # to work around https://github.com/matrix-org/synapse/issues/3471 | ||
| # when using "buffer" logger. Use "console" to log to stderr instead. | ||
| handlers: [console] | ||
| propagate: false | ||
| 
     | 
||
| root: | ||
| level: INFO | ||
| 
     | 
||
| # Write logs to the `buffer` handler, which will buffer them together in memory, | ||
| # then write them to a file. | ||
| # | ||
| # Replace "buffer" with "console" to log to stderr instead. (Note that you'll | ||
| # also need to update the configuration for the `twisted` logger above, in | ||
| # this case.) | ||
| # | ||
| handlers: [console] | ||
| 
     | 
||
| disable_existing_loggers: false | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
      
      Oops, something went wrong.
        
    
  
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
Uh oh!
There was an error while loading. Please reload this page.