Log improvement

Log improvement

--- src/KNXLib/KnxConnection.cs
+++ src/KNXLib/KnxConnection.cs
@@ -1,6 +1,7 @@
-using System;
+using System;
 using System.Net;
 using System.Text;
+using System.Linq;
 using KNXLib.DPT;
 using KNXLib.Exceptions;
 using KNXLib.Log;
@@ -130,13 +131,21 @@
                 if (KnxConnectedDelegate != null)
                     KnxConnectedDelegate();
             }
-            catch
-            {
-                //ignore
-            }
-
-            Logger.Info(ClassName, "KNX is connected");
-            Logger.Debug(ClassName, "Unlocking send - {0} free locks", _lockManager.LockCount);
+            catch(Exception e)
+            {
+                Logger.Error(ClassName, e.Message);
+                Logger.Error(ClassName, e.ToString());
+                Logger.Error(ClassName, e.StackTrace);
+
+                if (e.InnerException != null)
+                {
+                    Logger.Error(ClassName, e.InnerException.Message);
+                    Logger.Error(ClassName, e.ToString());
+                    Logger.Error(ClassName, e.InnerException.StackTrace);
+                }
+            }
+
+            Logger.Debug(ClassName, "KNX is connected. Unlocking send - {0} free locks", _lockManager.LockCount);

             _lockManager.UnlockConnection();
         }
@@ -153,9 +162,18 @@
                 if (KnxDisconnectedDelegate != null)
                     KnxDisconnectedDelegate();
             }
-            catch
-            {
-                //ignore
+            catch (Exception e)
+            {
+                Logger.Error(ClassName, e.Message);
+                Logger.Error(ClassName, e.ToString());
+                Logger.Error(ClassName, e.StackTrace);
+
+                if (e.InnerException != null)
+                {
+                    Logger.Error(ClassName, e.InnerException.Message);
+                    Logger.Error(ClassName, e.ToString());
+                    Logger.Error(ClassName, e.InnerException.StackTrace);
+                }
             }

             Logger.Debug(ClassName, "KNX is disconnected");
@@ -168,12 +186,21 @@
             {
                 KnxEventDelegate(address, state);
             }
-            catch
-            {
-                //ignore
-            }
-
-            Logger.Debug(ClassName, "Device {0} sent event {1}", address, state);
+            catch (Exception e)
+            {
+                Logger.Error(ClassName, e.Message);
+                Logger.Error(ClassName, e.ToString());
+                Logger.Error(ClassName, e.StackTrace);
+
+                if (e.InnerException != null)
+                {
+                    Logger.Error(ClassName, e.InnerException.Message);
+                    Logger.Error(ClassName, e.ToString());
+                    Logger.Error(ClassName, e.InnerException.StackTrace);
+                }
+            }
+
+            Logger.Debug(ClassName, "Device {0} sent event 0x{1}", address, string.Join("", state.Select(c => ((int)c).ToString("X2"))));
         }

         internal void Status(string address, string state)
@@ -182,9 +209,18 @@
             {
                 KnxStatusDelegate(address, state);
             }
-            catch
-            {
-                //ignore
+            catch (Exception e)
+            {
+                Logger.Error(ClassName, e.Message);
+                Logger.Error(ClassName, e.ToString());
+                Logger.Error(ClassName, e.StackTrace);
+
+                if (e.InnerException != null)
+                {
+                    Logger.Error(ClassName, e.InnerException.Message);
+                    Logger.Error(ClassName, e.ToString());
+                    Logger.Error(ClassName, e.InnerException.StackTrace);
+                }
             }

             Logger.Debug(ClassName, "Device {0} has status {1}", address, state);
@@ -287,11 +323,11 @@
         /// <param name="data">Byte array value</param>
         public void Action(string address, byte[] data)
         {
-            Logger.Debug(ClassName, "Sending {0} to {1}.", data, address);
+            Logger.Debug(ClassName, "Sending 0x{0} to {1}.", BitConverter.ToString(data), address);

             _lockManager.PerformLockedOperation(() => KnxSender.Action(address, data));

-            Logger.Debug(ClassName, "Sent {0} to {1}.", data, address);
+            Logger.Debug(ClassName, "Sent 0x{0} to {1}.", BitConverter.ToString(data), address);
         }

         // TODO: It would be good to make a type for address, to make sure not any random string can be passed in


[Package Explorer] Enable gzip compression.

--- Tools/NuGet/NuGetPackageExplorer/Core/Utility/HttpClient.cs
+++ Tools/NuGet/NuGetPackageExplorer/Core/Utility/HttpClient.cs
@@ -20,6 +20,8 @@
             var httpRequest = request as HttpWebRequest;
             if (httpRequest != null) {
                 httpRequest.UserAgent = UserAgent;
+                httpRequest.Headers[HttpRequestHeader.AcceptEncoding] = "gzip, deflate";
+                httpRequest.AutomaticDecompression = DecompressionMethods.GZip | DecompressionMethods.Deflate;
             }

             request.UseDefaultCredentials = true;


Add comment for methods that are only supported on Windows.

--- src/Magick.NET/MagickNET.cs
+++ src/Magick.NET/MagickNET.cs
@@ -273,6 +273,7 @@

         /// <summary>
         /// Sets the directory that contains the Ghostscript file gsdll32.dll / gsdll64.dll.
+        /// This method is only supported on Windows.
         /// </summary>
         /// <param name="path">The path of the Ghostscript directory.</param>
         public static void SetGhostscriptDirectory(string path)
@@ -280,6 +281,7 @@

         /// <summary>
         /// Sets the directory that contains the Ghostscript font files.
+        /// This method is only supported on Windows.
         /// </summary>
         /// <param name="path">The path of the Ghostscript font directory.</param>
         public static void SetGhostscriptFontDirectory(string path)


Jeg kan faktisk ikke se at der er sket nogen ændring og der er ikke nogle fejl i programmet.... men den bliver committed da jeg bliver bedt om det

--- src/MidiGremlin/IMidiOut.cs
+++ src/MidiGremlin/IMidiOut.cs
@@ -1,31 +1,31 @@
-using System;
-using System.Collections.Generic;
-using MidiGremlin.Internal;
-
-namespace MidiGremlin
-{
-    ///
-    ///An interface that manages output of the music.
-    ///
-    public interface IMidiOut : IDisposable
-    {
+using System;
+using System.Collections.Generic;
+using MidiGremlin.Internal;
+
+namespace MidiGremlin
+{
+    ///
+    ///An interface that manages output of the music.
+    ///
+    public interface IMidiOut : IDisposable
+    {
 		///
 		/// Sets the BeatScheduler that is responsible for feeding this IMidiOut with MIDI messages. Setting this multiple times is an error.
 		///
-		/// <param name="source">The BeatScheduler</param>
-        void SetSource(BeatScheduler source);
-
+		/// <param name="source">The BeatScheduler</param>
+        void SetSource(BeatScheduler source);
+
 		///
 		/// Music speed in Beats per Minute. Setting this to sixty should make one beat take one secon.
-		///
-	    int BeatsPerMinute { get; set; }
-
-
-
-        ///
-        /// The number of beats elapsed since this instance was created.
-        ///
-        /// <returns>The number of beats elapsed since this instance was created.</returns>
-        double CurrentTime ();
-    }
-}
+		///
+	    int BeatsPerMinute { get; set; }
+
+
+
+        ///
+        /// The number of beats elapsed since this instance was created.
+        ///
+        /// <returns>The number of beats elapsed since this instance was created.</returns>
+        double CurrentTime ();
+    }
+}


Refine error recovery strategy when parsing identifiers

The parser currently only inserts tokens and skips all remaining tokens
when parsing EOF. Update the parser to also skip tokens in certain cases
in order to improve the editing experience.

--- src/NQuery/Syntax/Parser.cs
+++ src/NQuery/Syntax/Parser.cs
@@ -90,9 +90,79 @@

         private SyntaxToken Match(SyntaxKind kind)
         {
+            // Normally, our behavior is to insert missing tokens if the current token doesn't
+            // match our expected token. The root of the parser will make sure that after we've
+            // completed parsing the main element (i.e. query or expression) the only remaining
+            // token is EOF.
+            //
+            // If there are any tokens left, we report an error saying "we expected EOF but
+            // found <token>". That EOF token will contain all remaining tokens as skipped
+            // token trivia.
+            //
+            // However, there are cases where we expect an identifier but the currently typed
+            // identifier is a keyword.
+            //
+            // For example, consider this case:
+            //
+            //     SELECT  e.FirstName + ' ' + e.LastName AS Full|
+            //     FROM    Employees e
+            //
+            // The developer is typing "FullName" but as soon as he completes the second
+            // "l" the syntax is completely messed up.
+            //
+            // Here is another example:
+            //
+            //     SELECT   *
+            //     FROM     Or|
+            //
+            // In this case, the develope wants to type "Orders" but as soon as the "r" is
+            // typed the completion will stop working because the context of the "Or"
+            // keyword is no longer part of the table reference but part of the skipped
+            // token trivia contained in the EOF token.
+            //
+            // Both cases can be fixed by skipping the current token and inserting a missing
+            // token that contains the skipped token as trivia.
+            //
+            // You may wonder why we shouldn't do this for all cases where an identifier is
+            // expeted but a keyword is found.
+            //
+            // Consider this case:
+            //
+            //     SELECT   o.|
+            //     FROM     Orders
+            //
+            // If we were always eating the curent token, we would skip the FROM token which
+            // would cause the completion provider to think we've typed "o.FROM|" which is not
+            // what we want. So in essence we want to disambiguate this case:
+            //
+            //     SELECT   o.|
+            //     FROM     Orders
+            //
+            // from:
+            //
+            //     SELECT   o.From|
+            //
+            // The easiest is to use the line information -- if the current token is on the
+            // same line as the previous, then we skip (second case). Otherwise we insert
+            // a new token (frist case).
+
+            if (kind == SyntaxKind.IdentifierToken && Current.Kind.IsKeyword() && IsPreviousTokenOnSameLine())
+                return SkipAndInsertMissingToken(SyntaxKind.IdentifierToken);
+
             return Current.Kind == kind
                        ? NextToken()
-                       : CreateMissingToken(kind);
+                       : InsertMissingToken(kind);
+        }
+
+        private bool IsPreviousTokenOnSameLine()
+        {
+            var previous = Peek(-1);
+            if (previous == null)
+                return true;
+
+            var previousLine = _textBuffer.GetLineNumberFromPosition(previous.Span.Start);
+            var currentLine = _textBuffer.GetLineNumberFromPosition(Current.Span.Start);
+            return previousLine == currentLine;
         }

         private void SkipTokens(Func<SyntaxToken, bool> stopPredicate)
@@ -116,13 +186,26 @@
             _tokens[_tokenIndex] = current.WithLeadingTrivia(leadingTrivia);
         }

-        private SyntaxToken CreateMissingToken(SyntaxKind kind)
+        private SyntaxToken InsertMissingToken(SyntaxKind kind)
         {
             var missingTokenSpan = new TextSpan(Current.FullSpan.Start, 0);
             var diagnosticSpan = GetDiagnosticSpanForMissingToken();
             var diagnostics = new List<Diagnostic>(1);
             diagnostics.ReportTokenExpected(diagnosticSpan, Current, kind);
             return new SyntaxToken(_syntaxTree, kind, SyntaxKind.BadToken, true, missingTokenSpan, string.Empty, null, new SyntaxTrivia[0], new SyntaxTrivia[0], diagnostics);
+        }
+
+        private SyntaxToken SkipAndInsertMissingToken(SyntaxKind kind)
+        {
+            var skippedToken = Current;
+            var skippedTokensTrivia = new[] { CreateSkippedTokensTrivia(new[] { skippedToken }) };
+            NextToken();
+
+            var missingTokenSpan = new TextSpan(Current.FullSpan.Start, 0);
+            var diagnosticSpan = GetDiagnosticSpanForMissingToken();
+            var diagnostics = new List<Diagnostic>(1);
+            diagnostics.ReportTokenExpected(diagnosticSpan, skippedToken, kind);
+            return new SyntaxToken(_syntaxTree, kind, SyntaxKind.BadToken, true, missingTokenSpan, string.Empty, null, skippedTokensTrivia, new SyntaxTrivia[0], diagnostics);
         }

         private TextSpan GetDiagnosticSpanForMissingToken()


remove unused property

remove unused property

--- osu.Game/Overlays/BeatmapSet/Info.cs
+++ osu.Game/Overlays/BeatmapSet/Info.cs
@@ -142,7 +142,6 @@
         private class MetadataSection : FillFlowContainer
         {
             private readonly MetadataType type;
-            private readonly OsuSpriteText header;
             private readonly LinkFlowContainer textFlow;

             public string Text


Change in-line with framework

Change in-line with framework

--- osu.Game/Overlays/OnScreenDisplay.cs
+++ osu.Game/Overlays/OnScreenDisplay.cs
@@ -139,7 +139,7 @@

         private readonly List<IBindable> references = new List<IBindable>();

-        private void trackSetting<T>(Bindable<T> bindable, Bindable<T>.BindableValueChanged<T> action)
+        private void trackSetting<T>(Bindable<T> bindable, Action<T> action)
         {
             // we need to keep references as we bind
             references.Add(bindable);


Fix typo in comment in `IntroScreen`

Fix typo in comment in `IntroScreen`

--- osu.Game/Screens/Menu/IntroScreen.cs
+++ osu.Game/Screens/Menu/IntroScreen.cs
@@ -212,7 +212,7 @@
             if (!resuming)
             {
                 // generally this can never be null
-                // an exception is running ruleset tests, where the osu! ruleset may not be prsent (causing importing the intro to fail).
+                // an exception is running ruleset tests, where the osu! ruleset may not be present (causing importing the intro to fail).
                 if (initialBeatmap != null)
                     beatmap.Value = initialBeatmap;
                 Track = beatmap.Value.Track;


Fix OsuTestCase beatmap not having a correct default beatmap

--- osu.Game/Tests/Visual/OsuTestCase.cs
+++ osu.Game/Tests/Visual/OsuTestCase.cs
@@ -28,6 +28,9 @@
         protected override IReadOnlyDependencyContainer CreateChildDependencies(IReadOnlyDependencyContainer parent)
         {
             Dependencies = new DependencyContainer(base.CreateChildDependencies(parent));
+
+            // This is the earliest we can get OsuGameBase, which is used by the dummy working beatmap to find textures
+            beatmap.Default = new DummyWorkingBeatmap(Dependencies.Get<OsuGameBase>());

             Dependencies.CacheAs<BindableBeatmap>(beatmap);
             Dependencies.CacheAs<IBindableBeatmap>(beatmap);


Re-added linux include path that was removed by mistake.

--- src/Parser/ParserOptions.cs
+++ src/Parser/ParserOptions.cs
@@ -260,7 +260,10 @@
                     AddSystemIncludeDirs($"{headersPath}/usr/include/c++/{version}");
                     AddSystemIncludeDirs($"{headersPath}/usr/include/c++/{version}/backward");
                     foreach (var tripple in tripples)
+                    {
+                        AddSystemIncludeDirs($"{headersPath}/usr/include/{tripple}/c++/{version}");
                         AddSystemIncludeDirs($"{headersPath}/usr/include/c++/{version}/{tripple}");
+                    }
                 }
             }
             foreach (var tripple in tripples)


idn_to_ascii, idn_to_utf8

idn_to_ascii, idn_to_utf8

--- src/Peachpie.Library/Web.cs
+++ src/Peachpie.Library/Web.cs
@@ -806,5 +806,53 @@
         }

         #endregion
+
+        #region idn_to_ascii, idn_to_utf8
+
+        public const int IDNA_DEFAULT = 0;
+        public const int IDNA_ALLOW_UNASSIGNED = 1;
+        public const int IDNA_USE_STD3_RULES = 2;
+
+        public const int INTL_IDNA_VARIANT_2003 = 0;
+        public const int INTL_IDNA_VARIANT_UTS46 = 1;
+
+        /// <summary>
+        /// Convert domain name to IDNA ASCII form.
+        /// </summary>
+        [return: CastToFalse]
+        public static string idn_to_ascii(string domain, int options = IDNA_DEFAULT, int variant = INTL_IDNA_VARIANT_UTS46)
+        {
+            return new System.Globalization.IdnMapping().GetAscii(domain);
+        }
+
+        /// <summary>
+        /// Convert domain name to IDNA ASCII form.
+        /// </summary>
+        //[return: CastToFalse]
+        public static string idn_to_ascii(string domain, int options, int variant, ref PhpArray idna_info)
+        {
+            throw new NotImplementedException();
+        }
+
+        /// <summary>
+        /// Convert domain name from IDNA ASCII to Unicode
+        /// </summary>
+        //[return: CastToFalse]
+        public static string idn_to_utf8(string domain, int options = IDNA_DEFAULT, int variant = INTL_IDNA_VARIANT_UTS46)
+        {
+            return new System.Globalization.IdnMapping().GetUnicode(domain);
+        }
+
+        /// <summary>
+        /// Convert domain name from IDNA ASCII to Unicode
+        /// </summary>
+        //[return: CastToFalse]
+        public static string idn_to_utf8(string domain, int options, int variant, ref PhpArray idna_info)
+        {
+            throw new NotImplementedException();
+        }
+
+
+        #endregion
     }
 }


Added confirmation to the reparenting command.

This prevents accidental reparenting when it is enabled globally.

--- src/PhotoVersionCommands.cs
+++ src/PhotoVersionCommands.cs
@@ -198,7 +198,7 @@
 		{
 			string ok_caption = Catalog.GetString ("De_tach");
 			string msg = String.Format (Catalog.GetString ("Really detach version \"{0}\" from \"{1}\"?"), photo.DefaultVersion.Name, photo.Name.Replace("_", "__"));
-			string desc = Catalog.GetString ("This makes the verion appear as a separate photo in the library.");
+			string desc = Catalog.GetString ("This makes the verion appear as a separate photo in the library. To undo, drag the new photo back to its parent.");
 			try {
 				if (ResponseType.Ok == HigMessageDialog.RunHigConfirmation(parent_window, DialogFlags.DestroyWithParent,
 									   MessageType.Warning, msg, desc, ok_caption)) {
@@ -231,28 +231,51 @@
 	public class Reparent {
 		public bool Execute (PhotoStore store, Photo [] photos, Photo new_parent, Gtk.Window parent_window)
 		{
-			foreach (Photo photo in photos) {
-				new_parent.AddTag (photo.Tags);
-				foreach (uint version_id in photo.VersionIds) {
-					try {
-						new_parent.DefaultVersionId = new_parent.CreateReparentedVersion (photo.GetVersion (version_id) as PhotoVersion);
-						store.Commit (new_parent);
-					} catch (Exception e) {
-						Log.DebugException (e);
+			string ok_caption = Catalog.GetString ("Re_parent");
+			string msg = String.Format (Catalog.GetPluralString ("Really reparent selected photo as version of {1}?",
+			                                                     "Really reparent {0} selected photos as versions of {1}?", photos.Length),
+			                            photos.Length, new_parent.Name.Replace ("_", "__"));
+			string desc = Catalog.GetString ("The tags will be merged with the new parent.");
+
+			try {
+				if (ResponseType.Ok == HigMessageDialog.RunHigConfirmation(parent_window, DialogFlags.DestroyWithParent,
+									   MessageType.Warning, msg, desc, ok_caption)) {
+					foreach (Photo photo in photos) {
+						new_parent.AddTag (photo.Tags);
+						foreach (uint version_id in photo.VersionIds) {
+							try {
+								new_parent.DefaultVersionId = new_parent.CreateReparentedVersion (photo.GetVersion (version_id) as PhotoVersion);
+								store.Commit (new_parent);
+							} catch (Exception e) {
+								Log.DebugException (e);
+							}
+						}
+						uint [] version_ids = photo.VersionIds;
+						Array.Reverse (version_ids);
+						foreach (uint version_id in version_ids) {
+							try {
+								photo.DeleteVersion (version_id, true, true);
+							} catch (Exception e) {
+								Log.DebugException (e);
+							}
+						}
+						App.Instance.Database.Photos.Remove (photo);
 					}
+					return true;
 				}
-				uint [] version_ids = photo.VersionIds;
-				Array.Reverse (version_ids);
-				foreach (uint version_id in version_ids) {
-					try {
-						photo.DeleteVersion (version_id, true, true);
-					} catch (Exception e) {
-						Log.DebugException (e);
-					}
-				}
-				App.Instance.Database.Photos.Remove (photo);
-			}
-			return true;
+			}
+			catch (Exception e) {
+				Log.DebugException (e);
+				msg = Catalog.GetString ("Could not reparent photos");
+				desc = String.Format (Catalog.GetString ("Received exception \"{0}\". Unable to reparent to \"{1}\""),
+							     e.Message, new_parent.Name);
+				HigMessageDialog md = new HigMessageDialog (parent_window, DialogFlags.DestroyWithParent,
+									    Gtk.MessageType.Error, ButtonsType.Ok, msg, desc);
+				md.Run ();
+				md.Destroy ();
+			}
+
+			return false;
 		}
 	}
 }


Added validation to prevent rendering unserializable output

--- src/SME.VHDL/RenderState.cs
+++ src/SME.VHDL/RenderState.cs
@@ -121,6 +121,8 @@

 			Network = ParseProcesses.BuildNetwork(processes);

+			ValidateNetwork(Network);
+
 			TypeScope = new VHDLTypeScope(Network.Processes.First(x => x.MainMethod != null).MainMethod.SourceMethod.Module);

 			Types = Network
@@ -133,6 +135,25 @@
 			Network.Name = Naming.AssemblyToValidName(Processes);

 			Transformations.BuildTransformations.Transform(Network, this);
+		}
+
+		private static void ValidateNetwork(AST.Network network)
+		{
+			var sp = network.Processes.SelectMany(x => x.InternalBusses).FirstOrDefault(x => x.IsTopLevelInput || x.IsTopLevelOutput);
+			if (sp != null)
+				throw new Exception($"Cannot have an internal bus that is also toplevel input or output: {sp.Name}");
+
+			sp = network.Processes.SelectMany(x => x.InputBusses.Union(x.OutputBusses)).FirstOrDefault(x => x.IsTopLevelInput && x.IsTopLevelOutput);
+			if (sp != null)
+				throw new Exception($"Cannot have a bus that is both top-level input and top-level output: {sp.Name}");
+
+			sp = network.Processes.SelectMany(x => x.InputBusses.Select(y => new { Proc = x, Bus = y})).Where(x => !x.Bus.IsClocked && x.Proc.OutputBusses.Contains(x.Bus)).Select(x => x.Bus).FirstOrDefault();
+			if (sp != null)
+				throw new Exception($"A bus cannot simultaneously be input and output, unless it is clocked: {sp.Name}");
+
+			sp = network.Processes.SelectMany(x => x.OutputBusses.Select(y => new { Proc = x, Bus = y })).Where(x => !x.Bus.IsClocked && x.Proc.InputBusses.Contains(x.Bus)).Select(x => x.Bus).FirstOrDefault();
+			if (sp != null)
+				throw new Exception($"A bus cannot simultaneously be output and input, unless it is clocked: {sp.Name}");
 		}

 		/// <summary>


Fixed formatting issue with performance tester.

--- DtronixMessageQueue.Tests.Performance/Program.cs
+++ DtronixMessageQueue.Tests.Performance/Program.cs
@@ -238,7 +238,7 @@
 			};

-			Console.WriteLine("FrameBufferSize: {0}; SendAndReceiveBufferSize: {1}", config.FrameBufferSize, config.SendAndReceiveBufferSize);
+			Console.WriteLine("FrameBufferSize: {0}; SendAndReceiveBufferSize: {1}\r\n", config.FrameBufferSize, config.SendAndReceiveBufferSize);

 			var small_message = new MqMessage {
 				new MqFrame(RandomBytes(50), MqFrameType.More, config),


Revise method name to reflect actual behavior

--- SlicerConfiguration/UIFields/ComPortField.cs
+++ SlicerConfiguration/UIFields/ComPortField.cs
@@ -70,10 +70,10 @@

 			selectableOptions.Click += (s, e) =>
 			{
-				AddComMenuItems(selectableOptions);
+				RebuildMenuItems(selectableOptions);
 			};

-			AddComMenuItems(selectableOptions);
+			RebuildMenuItems(selectableOptions);

 			// Prevent droplist interaction when connected
 			PrinterConnection.Instance.CommunicationStateChanged.RegisterEvent((s, e) =>
@@ -99,7 +99,7 @@
 			selectableOptions.SelectedLabel = ActiveSliceSettings.Instance.Helpers.ComPort();
 		}

-		private void AddComMenuItems(DropDownList selectableOptions)
+		private void RebuildMenuItems(DropDownList selectableOptions)
 		{
 			selectableOptions.MenuItems.Clear();
 			string machineSpecificComPortValue = ActiveSliceSettings.Instance.Helpers.ComPort();


Recording previous journal data as default if change journal cannot be used

--- Duplicati/Library/Snapshots/UsnJournalService.cs
+++ Duplicati/Library/Snapshots/UsnJournalService.cs
@@ -61,14 +61,15 @@
             string filterHash, IEnumerable<USNJournalDataEntry> journalData)
         {
             // create lookup for journal data
-            var journalDataDict = journalData.ToDictionary(data => data.Volume);
-
-            // prepare result
+            var journalDataEntries = journalData.ToList();
+            var journalDataDict = journalDataEntries.ToDictionary(data => data.Volume);
+
+            // prepare result
             var result = new FilterData
             {
                 Files = new HashSet<string>(Utility.Utility.ClientFilenameStringComparer),
                 Folders = new List<string>(),
-                JournalData = new List<USNJournalDataEntry>()
+                JournalData = journalDataEntries.ConvertAll(p => p) // clone source data as default value
             };

             // iterate over volumes
@@ -89,6 +90,10 @@
                         ConfigHash = filterHash
                     };

+                    // remove default data
+                    result.JournalData.RemoveAll(e => e.Volume == volume);
+
+                    // add new data
                     result.JournalData.Add(nextData);

                     // only use change journal if:


Catch exceptions and return as message strings

--- SolidworksAddinFramework/MacroFeatureBase.cs
+++ SolidworksAddinFramework/MacroFeatureBase.cs
@@ -238,7 +238,16 @@
         {
             Init(app, modelDoc, feature);
             var modeller = (IModeler) SwApp.GetModeler();
-            return Regenerate(modeller);
+            try
+            {
+                return Regenerate(modeller);
+            }
+            catch (Exception e)
+            {
+
+            }
+
+
         }

         public object Security(object app, object modelDoc, object feature)


dfjksf

dfjksf

--- EngineLayer/ClassicSearch/ClassicSearchEngine.cs
+++ EngineLayer/ClassicSearch/ClassicSearchEngine.cs
@@ -19,7 +19,7 @@
         private readonly int? minPeptideLength;
         private readonly int? maxPeptideLength;
         private readonly int maximumVariableModificationIsoforms;
-        private readonly List<MassDiffAcceptor> massDiffAcceptors;
+        private readonly List<MassDiffAcceptor> searchModes;

         private readonly List<Protein> proteinList;

@@ -56,7 +56,7 @@
             this.minPeptideLength = minPeptideLength;
             this.maxPeptideLength = maxPeptideLength;
             this.maximumVariableModificationIsoforms = maximumVariableModificationIsoforms;
-            this.massDiffAcceptors = searchModes;
+            this.searchModes = searchModes;
             this.protease = protease;
             this.lp = lp;
             this.conserveMemory = conserveMemory;
@@ -77,8 +77,8 @@

             Status("Getting ms2 scans...", nestedIds);

-            var outerPsms = new PsmParent[massDiffAcceptors.Count][];
-            for (int aede = 0; aede < massDiffAcceptors.Count; aede++)
+            var outerPsms = new PsmParent[searchModes.Count][];
+            for (int aede = 0; aede < searchModes.Count; aede++)
                 outerPsms[aede] = new PsmParent[arrayOfSortedMS2Scans.Length];

             var lockObject = new object();
@@ -88,8 +88,8 @@
             Status("Starting classic search loop...", nestedIds);
             Parallel.ForEach(Partitioner.Create(0, totalProteins), partitionRange =>
             {
-                var psms = new PsmParent[massDiffAcceptors.Count][];
-                for (int searchModeIndex = 0; searchModeIndex < massDiffAcceptors.Count; searchModeIndex++)
+                var psms = new PsmParent[searchModes.Count][];
+                for (int searchModeIndex = 0; searchModeIndex < searchModes.Count; searchModeIndex++)
                     psms[searchModeIndex] = new PsmParent[arrayOfSortedMS2Scans.Length];
                 for (int i = partitionRange.Item1; i < partitionRange.Item2; i++)
                 {
@@ -119,9 +119,9 @@
                             Array.Sort(productMasses);
                             double[] matchedIonMassesListPositiveIsMatch = new double[productMasses.Length];

-                            for (int massDiffAcceptorIndex = 0; massDiffAcceptorIndex < massDiffAcceptors.Count; massDiffAcceptorIndex++)
+                            for (int massDiffAcceptorIndex = 0; massDiffAcceptorIndex < searchModes.Count; massDiffAcceptorIndex++)
                             {
-                                var massDiffAcceptor = massDiffAcceptors[massDiffAcceptorIndex];
+                                var massDiffAcceptor = searchModes[massDiffAcceptorIndex];
                                 foreach (ScanWithIndexAndNotchInfo scanWithIndexAndNotchInfo in GetAcceptableScans(correspondingCompactPeptide.MonoisotopicMass, massDiffAcceptor).ToList())
                                 {
                                     var score = PsmParent.MatchIons(scanWithIndexAndNotchInfo.theScan.TheScan, productMassTolerance, productMasses, matchedIonMassesListPositiveIsMatch);
@@ -141,7 +141,7 @@
                 }
                 lock (lockObject)
                 {
-                    for (int searchModeIndex = 0; searchModeIndex < massDiffAcceptors.Count; searchModeIndex++)
+                    for (int searchModeIndex = 0; searchModeIndex < searchModes.Count; searchModeIndex++)
                         for (int i = 0; i < outerPsms[searchModeIndex].Length; i++)
                             if (psms[searchModeIndex][i] != null)
                             {


[ci skip] Updating ServerBuildInfo_Dynamic.cs

1.22.3862.20210228041109-master-289d08f

--- Source/ACE.Server/ServerBuildInfo_Dynamic.cs
+++ Source/ACE.Server/ServerBuildInfo_Dynamic.cs
@@ -4,17 +4,17 @@
     public static partial class ServerBuildInfo
     {
         public static string Branch = "master";
-        public static string Commit = "447acaaf92e03b896c435fb242b04b69697de753";
+        public static string Commit = "289d08f4cd18815594afda5d79e1bf77c81956d4";

         public static string Version = "1.22";
-        public static string Build   = "3861";
+        public static string Build   = "3862";

         public static int BuildYear   = 2021;
         public static int BuildMonth  = 02;
-        public static int BuildDay    = 26;
-        public static int BuildHour   = 17;
-        public static int BuildMinute = 45;
-        public static int BuildSecond = 45;
+        public static int BuildDay    = 28;
+        public static int BuildHour   = 04;
+        public static int BuildMinute = 11;
+        public static int BuildSecond = 09;
     }
 }


[ci skip] Updating ServerBuildInfo_Dynamic.cs

1.31.4071.20211011175307-master-f64038f

--- Source/ACE.Server/ServerBuildInfo_Dynamic.cs
+++ Source/ACE.Server/ServerBuildInfo_Dynamic.cs
@@ -4,17 +4,17 @@
     public static partial class ServerBuildInfo
     {
         public static string Branch = "master";
-        public static string Commit = "4531a2ab402c83decf9edb722b446d7a587c692f";
+        public static string Commit = "f64038f7998c352fc04fb322313a1eb3e5d1fed3";

         public static string Version = "1.31";
-        public static string Build   = "4070";
+        public static string Build   = "4071";

         public static int BuildYear   = 2021;
         public static int BuildMonth  = 10;
         public static int BuildDay    = 11;
         public static int BuildHour   = 17;
-        public static int BuildMinute = 40;
-        public static int BuildSecond = 10;
+        public static int BuildMinute = 53;
+        public static int BuildSecond = 07;
     }
 }


[ci skip] Updating ServerBuildInfo_Dynamic.cs

1.15.3734.20201109060817-master-65eaddb

--- Source/ACE.Server/ServerBuildInfo_Dynamic.cs
+++ Source/ACE.Server/ServerBuildInfo_Dynamic.cs
@@ -4,17 +4,17 @@
     public static partial class ServerBuildInfo
     {
         public static string Branch = "master";
-        public static string Commit = "67d6a47e1390603da3bbd0507e8711d234d95e55";
+        public static string Commit = "65eaddb37a5001cd14afe917373e968b330cd559";

         public static string Version = "1.15";
-        public static string Build   = "3733";
+        public static string Build   = "3734";

         public static int BuildYear   = 2020;
         public static int BuildMonth  = 11;
-        public static int BuildDay    = 03;
+        public static int BuildDay    = 09;
         public static int BuildHour   = 06;
-        public static int BuildMinute = 42;
-        public static int BuildSecond = 31;
+        public static int BuildMinute = 08;
+        public static int BuildSecond = 17;
     }
 }


[ci skip] Updating ServerBuildInfo_Dynamic.cs

1.45.4247.20220723040320-master-0221a72

--- Source/ACE.Server/ServerBuildInfo_Dynamic.cs
+++ Source/ACE.Server/ServerBuildInfo_Dynamic.cs
@@ -4,17 +4,17 @@
     public static partial class ServerBuildInfo
     {
         public static string Branch = "master";
-        public static string Commit = "a1a0894980e3d120fe71da23abf2873dfcfe6916";
+        public static string Commit = "0221a72b100d7589d491b613907b6869540eafc2";

-        public static string Version = "1.44";
-        public static string Build   = "4245";
+        public static string Version = "1.45";
+        public static string Build   = "4247";

         public static int BuildYear   = 2022;
         public static int BuildMonth  = 07;
-        public static int BuildDay    = 22;
-        public static int BuildHour   = 17;
-        public static int BuildMinute = 29;
-        public static int BuildSecond = 05;
+        public static int BuildDay    = 23;
+        public static int BuildHour   = 04;
+        public static int BuildMinute = 03;
+        public static int BuildSecond = 20;
     }
 }


[ci skip] Updating ServerBuildInfo_Dynamic.cs

1.25.3969.20210629010018-master-771c5f6

--- Source/ACE.Server/ServerBuildInfo_Dynamic.cs
+++ Source/ACE.Server/ServerBuildInfo_Dynamic.cs
@@ -4,17 +4,17 @@
     public static partial class ServerBuildInfo
     {
         public static string Branch = "master";
-        public static string Commit = "70a6f18c03996c4ff9ead9d208d84960db4c4017";
+        public static string Commit = "771c5f64b87865ffb3d96825f0416499c5bbdbe0";

         public static string Version = "1.25";
-        public static string Build   = "3968";
+        public static string Build   = "3969";

         public static int BuildYear   = 2021;
         public static int BuildMonth  = 06;
-        public static int BuildDay    = 28;
-        public static int BuildHour   = 18;
-        public static int BuildMinute = 55;
-        public static int BuildSecond = 14;
+        public static int BuildDay    = 29;
+        public static int BuildHour   = 01;
+        public static int BuildMinute = 00;
+        public static int BuildSecond = 18;
     }
 }


[ci skip] Updating ServerBuildInfo_Dynamic.cs

1.9.3513.20200815144428-master-1eeddbe

--- Source/ACE.Server/ServerBuildInfo_Dynamic.cs
+++ Source/ACE.Server/ServerBuildInfo_Dynamic.cs
@@ -4,17 +4,17 @@
     public static partial class ServerBuildInfo
     {
         public static string Branch = "master";
-        public static string Commit = "13302eb9d0bde765a7adf9eba6261b9ccb74996f";
+        public static string Commit = "1eeddbead74f716922b1fc211547c63a004f2e46";

         public static string Version = "1.9";
-        public static string Build   = "3511";
+        public static string Build   = "3513";

         public static int BuildYear   = 2020;
         public static int BuildMonth  = 08;
         public static int BuildDay    = 15;
-        public static int BuildHour   = 12;
-        public static int BuildMinute = 32;
-        public static int BuildSecond = 41;
+        public static int BuildHour   = 14;
+        public static int BuildMinute = 44;
+        public static int BuildSecond = 28;
     }
 }


Don't flag new notebooks as dirty initially.

--- src/SqlNotebook/MainForm.cs
+++ src/SqlNotebook/MainForm.cs
@@ -77,8 +77,11 @@

             if (isNew) {
                 _manager.NewNote("Getting Started", Resources.GettingStartedRtf);
-                Load += (sender, e) => OpenItem(new NotebookItem(NotebookItemType.Note, "Getting Started"));
-                SetDirty();
+                Load += (sender, e) => {
+                    OpenItem(new NotebookItem(NotebookItemType.Note, "Getting Started"));
+                    _isDirty = false;
+                    SetTitle();
+                };
             }

             Load += (sender, e) => _manager.Rescan();


Fixed compiler error

Fixed compiler error

--- Source/csla.netcore.test/Basic/BasicTests.cs
+++ Source/csla.netcore.test/Basic/BasicTests.cs
@@ -366,7 +366,7 @@
     [TestMethod]
     public async Task ChildEditLevelClone()
     {
-      var list = await DataPortal.CreateAsync<RootList>();
+      var list = await Csla.DataPortal.CreateAsync<RootList>();
       list.BeginEdit();
       list.AddNew();
       var clone = (RootList)((ICloneable)list).Clone();


this should take care of setting default accounts

--- SpeckleCore/LocalData/SpeckleLocalContext.cs
+++ SpeckleCore/LocalData/SpeckleLocalContext.cs
@@ -142,15 +142,8 @@
     /// <param name="account"></param>
     public static void SetDefaultAccount( Account account )
     {
-      try
-      {
-        var currentDefault = GetDefaultAccount(); currentDefault.IsDefault = false;
-        Database.Update( currentDefault );
-      }
-      catch
-      {
-        // fail silently, it's not major
-      }
+
+      Database.Execute( "UPDATE Account SET IsDefault='false'" );

       account.IsDefault = true;
       Database.Update( account );


updated the ping pong code.

updated the ping pong code.

--- Src/PTester/Regressions/PingPong/PingPong.cs
+++ Src/PTester/Regressions/PingPong/PingPong.cs
@@ -132,7 +132,7 @@

             public override int NextInstanceNumber(PStateImpl app)
             {
-                return app.AllStateMachines.Where(m => m is Main).Count() + 1;
+                return app.NextMachineInstanceNumber(this.GetType());
             }

             public override string Name


Made changes to star spawn adding in star types

--- StarCatcherUnity/Assets/Scripts/StarSpawn.cs
+++ StarCatcherUnity/Assets/Scripts/StarSpawn.cs
@@ -27,7 +27,7 @@
     [Range(0.1f, 10.0f)]
     public float hardTimeToSpawn = 0;

-
+    private float[] SpawnRate;
     // set to durations between spawn events
     [Range(0.1f, 10.0f)]
     public float easyFallDuration = 5.0f;
@@ -107,14 +107,7 @@
             StartCoroutine("BetweenWaves");
         }

-
-        if (hardTimeToNextSpawn <= 0)
-        {
-           // SpawnHard();
-            hardTimeToNextSpawn = hardTimeToSpawn; ;
-        }
-
-
+

     }

@@ -123,12 +116,13 @@

         if (Score.LEVEL_ONE == Score.GetCurrentLevel())
         {
-
+            // do probability calc
         }

             throw new NotImplementedException();
-        // sets the type
+        // sets the corresponding spawn rate float from array
+        return SpawnRate[i];
     }

     IEnumerator BetweenWaves()


Fix wrong player is selected if no player is given

--- CupCake.World/WorldService.cs
+++ CupCake.World/WorldService.cs
@@ -300,10 +300,7 @@
         private void RaisePlaceWorld(WorldBlock b,  int userId = -1)
         {
             Player p;
-            if (userId == -1)
-                p = this._playerService.OwnPlayer;
-            else
-                this._playerService.TryGetPlayer(userId, out p);
+            this._playerService.TryGetPlayer(userId, out p);

             this.SynchronizePlatform.Do(() =>
                 this.Events.Raise(new PlaceWorldEvent(b, p)));


Correction bêtise

Correction bêtise

--- DataAccessLayer/DalManager.cs
+++ DataAccessLayer/DalManager.cs
@@ -69,7 +69,7 @@
         }
         public bool InsertJedi(Jedi _jedi)
         {
-            return bo.InsertJedi(_jedi);
+            return bd.InsertJedi(_jedi);
         }
         public int InsertStade(Stade _stade)
         {


Update to NewItemPageViewModel

Update to NewItemPageViewModel

--- KryptPadCSApp/Models/NewItemPageViewModel.cs
+++ KryptPadCSApp/Models/NewItemPageViewModel.cs
@@ -226,18 +226,18 @@
             {
                 item = new ApiItem();
             }
-
+
             // Set the properties of the item. If this was loaded from an existing item
             // then the properties will contain the name and category.
             item.Name = ItemName;
-
+
             try
             {
-            // Create or update the item
-            var resp = await KryptPadApi.CreateItemAsync(CurrentProfile.Id, Category.Id, item, AccessToken, Passphrase);
-
-            // Add the fields that do not exist
-                foreach(var field in Fields)
+                // Create or update the item
+                var resp = await KryptPadApi.CreateItemAsync(CurrentProfile.Id, Category.Id, item, AccessToken, Passphrase);
+
+                // Add the fields that do not exist
+                foreach (var field in Fields)
                 {
                     // Send the field to the API to be stored under the item


Added Date to the seeded games.

Added Date to the seeded games.

--- LesGamblers.Data/Migrations/Configuration.cs
+++ LesGamblers.Data/Migrations/Configuration.cs
@@ -34,252 +34,288 @@
             var game1 = new Game
             {
                 HostTeam = CountryType.France.ToString(),
-                GuestTeam = CountryType.Romania.ToString()
+                GuestTeam = CountryType.Romania.ToString(),
+                Date = new DateTime(2016, 6, 10)
             };
             context.Games.Add(game1);

             var game2 = new Game
             {
                 HostTeam = CountryType.Albania.ToString(),
-                GuestTeam = CountryType.Switzerland.ToString()
+                GuestTeam = CountryType.Switzerland.ToString(),
+                Date = new DateTime(2016, 6, 11)
             };
             context.Games.Add(game2);

             var game3 = new Game
             {
                 HostTeam = CountryType.Wales.ToString(),
-                GuestTeam = CountryType.Slovakia.ToString()
+                GuestTeam = CountryType.Slovakia.ToString(),
+                Date = new DateTime(2016, 6, 11)
             };
             context.Games.Add(game3);

             var game4 = new Game
             {
                 HostTeam = CountryType.England.ToString(),
-                GuestTeam = CountryType.Russia.ToString()
+                GuestTeam = CountryType.Russia.ToString(),
+                Date = new DateTime(2016, 6, 11)
             };
             context.Games.Add(game4);

             var game5 = new Game
             {
                 HostTeam = CountryType.Poland.ToString(),
-                GuestTeam = CountryType.Northern_Ireland.ToString()
+                GuestTeam = CountryType.Northern_Ireland.ToString(),
+                Date = new DateTime(2016, 6, 12)
             };
             context.Games.Add(game5);

             var game6 = new Game
             {
                 HostTeam = CountryType.Germany.ToString(),
-                GuestTeam = CountryType.Ukraine.ToString()
+                GuestTeam = CountryType.Ukraine.ToString(),
+                Date = new DateTime(2016, 6, 12)
             };
             context.Games.Add(game6);

             var game7 = new Game
             {
                 HostTeam = CountryType.Turkey.ToString(),
-                GuestTeam = CountryType.Croatia.ToString()
+                GuestTeam = CountryType.Croatia.ToString(),
+                Date = new DateTime(2016, 6, 12)
             };
             context.Games.Add(game7);

             var game8 = new Game
             {
                 HostTeam = CountryType.Spain.ToString(),
-                GuestTeam = CountryType.Czech_Republic.ToString()
+                GuestTeam = CountryType.Czech_Republic.ToString(),
+                Date = new DateTime(2016, 6, 13)
             };
             context.Games.Add(game8);

             var game9 = new Game
             {
                 HostTeam = CountryType.Republic_of_Ireland.ToString(),
-                GuestTeam = CountryType.Sweden.ToString()
+                GuestTeam = CountryType.Sweden.ToString(),
+                Date = new DateTime(2016, 6, 13)
             };
             context.Games.Add(game9);

             var game10 = new Game
             {
                 HostTeam = CountryType.Belgium.ToString(),
-                GuestTeam = CountryType.Italy.ToString()
+                GuestTeam = CountryType.Italy.ToString(),
+                Date = new DateTime(2016, 6, 13)
             };
             context.Games.Add(game10);

             var game11 = new Game
             {
                 HostTeam = CountryType.Austria.ToString(),
-                GuestTeam = CountryType.Hungary.ToString()
+                GuestTeam = CountryType.Hungary.ToString(),
+                Date = new DateTime(2016, 6, 14)
             };
             context.Games.Add(game11);

             var game12 = new Game
             {
                 HostTeam = CountryType.Portugal.ToString(),
-                GuestTeam = CountryType.Iceland.ToString()
+                GuestTeam = CountryType.Iceland.ToString(),
+                Date = new DateTime(2016, 6, 14)
             };
             context.Games.Add(game12);

             var game13 = new Game
             {
                 HostTeam = CountryType.Romania.ToString(),
-                GuestTeam = CountryType.Switzerland.ToString()
+                GuestTeam = CountryType.Switzerland.ToString(),
+                Date = new DateTime(2016, 6, 15)
             };
             context.Games.Add(game13);

             var game14 = new Game
             {
                 HostTeam = CountryType.France.ToString(),
-                GuestTeam = CountryType.Albania.ToString()
+                GuestTeam = CountryType.Albania.ToString(),
+                Date = new DateTime(2016, 6, 15)
             };
             context.Games.Add(game14);

             var game15 = new Game
             {
                 HostTeam = CountryType.Russia.ToString(),
-                GuestTeam = CountryType.Slovakia.ToString()
+                GuestTeam = CountryType.Slovakia.ToString(),
+                Date = new DateTime(2016, 6, 15)
             };
             context.Games.Add(game15);

             var game16 = new Game
             {
                 HostTeam = CountryType.England.ToString(),
-                GuestTeam = CountryType.Wales.ToString()
+                GuestTeam = CountryType.Wales.ToString(),
+                Date = new DateTime(2016, 6, 16)
             };
             context.Games.Add(game16);

             var game17 = new Game
             {
                 HostTeam = CountryType.Ukraine.ToString(),
-                GuestTeam = CountryType.Northern_Ireland.ToString()
+                GuestTeam = CountryType.Northern_Ireland.ToString(),
+                Date = new DateTime(2016, 6, 16)
             };
             context.Games.Add(game17);

             var game18 = new Game
             {
                 HostTeam = CountryType.Germany.ToString(),
-                GuestTeam = CountryType.Poland.ToString()
+                GuestTeam = CountryType.Poland.ToString(),
+                Date = new DateTime(2016, 6, 16)
             };
             context.Games.Add(game18);

             var game19 = new Game
             {
                 HostTeam = CountryType.Czech_Republic.ToString(),
-                GuestTeam = CountryType.Croatia.ToString()
+                GuestTeam = CountryType.Croatia.ToString(),
+                Date = new DateTime(2016, 6, 17)
             };
             context.Games.Add(game19);

             var game20 = new Game
             {
                 HostTeam = CountryType.Spain.ToString(),
-                GuestTeam = CountryType.Turkey.ToString()
+                GuestTeam = CountryType.Turkey.ToString(),
+                Date = new DateTime(2016, 6, 17)
             };
             context.Games.Add(game20);

             var game21 = new Game
             {
                 HostTeam = CountryType.Italy.ToString(),
-                GuestTeam = CountryType.Sweden.ToString()
+                GuestTeam = CountryType.Sweden.ToString(),
+                Date = new DateTime(2016, 6, 17)
             };
             context.Games.Add(game21);

             var game22 = new Game
             {
                 HostTeam = CountryType.Belgium.ToString(),
-                GuestTeam = CountryType.Republic_of_Ireland.ToString()
+                GuestTeam = CountryType.Republic_of_Ireland.ToString(),
+                Date = new DateTime(2016, 6, 18)
             };
             context.Games.Add(game22);

             var game23 = new Game
             {
                 HostTeam = CountryType.Iceland.ToString(),
-                GuestTeam = CountryType.Hungary.ToString()
+                GuestTeam = CountryType.Hungary.ToString(),
+                Date = new DateTime(2016, 6, 18)
             };
             context.Games.Add(game23);

             var game24 = new Game
             {
                 HostTeam = CountryType.Portugal.ToString(),
-                GuestTeam = CountryType.Austria.ToString()
+                GuestTeam = CountryType.Austria.ToString(),
+                Date = new DateTime(2016, 6, 18)
             };
             context.Games.Add(game24);

             var game25 = new Game
             {
                 HostTeam = CountryType.Romania.ToString(),
-                GuestTeam = CountryType.Albania.ToString()
+                GuestTeam = CountryType.Albania.ToString(),
+                Date = new DateTime(2016, 6, 19)
             };
             context.Games.Add(game25);

             var game26 = new Game
             {
                 HostTeam = CountryType.Switzerland.ToString(),
-                GuestTeam = CountryType.France.ToString()
+                GuestTeam = CountryType.France.ToString(),
+                Date = new DateTime(2016, 6, 19)
             };
             context.Games.Add(game26);

             var game27 = new Game
             {
                 HostTeam = CountryType.Russia.ToString(),
-                GuestTeam = CountryType.Wales.ToString()
+                GuestTeam = CountryType.Wales.ToString(),
+                Date = new DateTime(2016, 6, 20)
             };
             context.Games.Add(game27);

             var game28 = new Game
             {
                 HostTeam = CountryType.Slovakia.ToString(),
-                GuestTeam = CountryType.England.ToString()
+                GuestTeam = CountryType.England.ToString(),
+                Date = new DateTime(2016, 6, 20)
             };
             context.Games.Add(game28);

             var game29 = new Game
             {
                 HostTeam = CountryType.Ukraine.ToString(),
-                GuestTeam = CountryType.Poland.ToString()
+                GuestTeam = CountryType.Poland.ToString(),
+                Date = new DateTime(2016, 6, 21)
             };
             context.Games.Add(game29);

             var game30 = new Game
             {
                 HostTeam = CountryType.Northern_Ireland.ToString(),
-                GuestTeam = CountryType.Germany.ToString()
+                GuestTeam = CountryType.Germany.ToString(),
+                Date = new DateTime(2016, 6, 21)
             };
             context.Games.Add(game30);

             var game31 = new Game
             {
                 HostTeam = CountryType.Czech_Republic.ToString(),
-                GuestTeam = CountryType.Turkey.ToString()
+                GuestTeam = CountryType.Turkey.ToString(),
+                Date = new DateTime(2016, 6, 21)
             };
             context.Games.Add(game31);

             var game32 = new Game
             {
                 HostTeam = CountryType.Croatia.ToString(),
-                GuestTeam = CountryType.Spain.ToString()
+                GuestTeam = CountryType.Spain.ToString(),
+                Date = new DateTime(2016, 6, 21)
             };
             context.Games.Add(game32);

             var game33 = new Game
             {
                 HostTeam = CountryType.Italy.ToString(),
-                GuestTeam = CountryType.Republic_of_Ireland.ToString()
+                GuestTeam = CountryType.Republic_of_Ireland.ToString(),
+                Date = new DateTime(2016, 6, 22)
             };
             context.Games.Add(game33);

             var game34 = new Game
             {
                 HostTeam = CountryType.Sweden.ToString(),
-                GuestTeam = CountryType.Belgium.ToString()
+                GuestTeam = CountryType.Belgium.ToString(),
+                Date = new DateTime(2016, 6, 22)
             };
             context.Games.Add(game34);

             var game35 = new Game
             {
                 HostTeam = CountryType.Iceland.ToString(),
-                GuestTeam = CountryType.Austria.ToString()
+                GuestTeam = CountryType.Austria.ToString(),
+                Date = new DateTime(2016, 6, 22)
             };
             context.Games.Add(game35);

             var game36 = new Game
             {
                 HostTeam = CountryType.Hungary.ToString(),
-                GuestTeam = CountryType.Portugal.ToString()
+                GuestTeam = CountryType.Portugal.ToString(),
+                Date = new DateTime(2016, 6, 22)
             };
             context.Games.Add(game36);
             context.SaveChanges();


Fixed certain things not be loaded by our own content manager

This bug must have been around for months!

--- Libraries/Farmhand/Content/ContentManager.cs
+++ Libraries/Farmhand/Content/ContentManager.cs
@@ -17,7 +17,11 @@
     using Farmhand.Content.Injectors.Other;
     using Farmhand.Logging;

+    using Microsoft.Xna.Framework.Content;
+
     using StardewValley;
+
+    using xTile;

     /// <summary>
     ///     An override for the XNA ContentManager which deals with loading custom XNBs when mods have registered custom
@@ -30,10 +34,20 @@
         new[] { typeof(IServiceProvider), typeof(string) })]
     [HookRedirectConstructorFromBase("StardewValley.Game1", "LoadContent",
         new[] { typeof(IServiceProvider), typeof(string) })]
+    [HookRedirectConstructorFromBase("StardewValley.Game1", "setGameMode",
+        new[] { typeof(IServiceProvider), typeof(string) })]
+    [HookRedirectConstructorFromBase("StardewValley.Game1", "performTenMinuteClockUpdate",
+        new[] { typeof(IServiceProvider), typeof(string) })]
     [HookRedirectConstructorFromBase("StardewValley.LocalizedContentManager", "CreateTemporary",
         new[] { typeof(IServiceProvider), typeof(string), typeof(CultureInfo), typeof(string) })]
     public class ContentManager : LocalizedContentManager
     {
+        [Hook(HookType.Entry, "StardewValley.Game1", "LoadContent")]
+        internal static void CreateContentManager([ThisBind] Game1 @this)
+        {
+            Game1.game1.Content = new ContentManager(@this.Content.ServiceProvider, @this.Content.RootDirectory);
+        }
+
         /// <summary>
         ///     Initializes a new instance of the <see cref="ContentManager" /> class.
         /// </summary>
@@ -77,7 +91,7 @@
         /// </summary>
         public static List<IContentLoader> ContentLoaders { get; } = new List<IContentLoader>
                 {
-                    new ModXnbInjector(),
+                    new ModXnbLoader(),
                     new MonsterLoader(),
                     new DialogueLoader(),
                     new PortraitLoader(),
@@ -93,6 +107,8 @@
         public static List<IContentInjector> ContentInjectors { get; } =
             new List<IContentInjector>
                 {
+                    new ModXnbTextureInjector(),
+                    new ModXnbDictionaryInjector(),
                     new BlueprintInjector(),
                     new MonsterInjector(),
                     new CropInjector(),


name fix

name fix

--- LoadBalancer/Controllers/ValuesController.cs
+++ LoadBalancer/Controllers/ValuesController.cs
@@ -22,7 +22,7 @@
             return request.Id;
         }

-        public string Get(Guid host, int part)
+        public string Get(Guid task, int part)
         {
             /*найти хост, который обрабатывает данные
              * запросить данные


Add entities while enumerating

Add entities while enumerating

--- MadCat/NutEngine/Components/EntityManager.cs
+++ MadCat/NutEngine/Components/EntityManager.cs
@@ -8,8 +8,16 @@
         public List<Entity> Entities { get; } = new List<Entity>();
         private static Dictionary<Type, Type[]> Dependencies = new Dictionary<Type, Type[]>();

+        private List<Entity> toBeAdded = new List<Entity>();
+
         public void Update(float deltaTime)
         {
+            foreach (var entity in toBeAdded) {
+                entity.Manager = this;
+                Entities.Add(entity);
+            }
+            toBeAdded.Clear();
+
             foreach (var entity in Entities) {
                 entity.Update(deltaTime);
             }
@@ -26,8 +34,7 @@

         public void Add(Entity entity)
         {
-            entity.Manager = this;
-            Entities.Add(entity);
+            toBeAdded.Add(entity);
         }

         public static void AddDependency<T>(params Type[] types)


Version bump for MarkEmbling.Utils

Version bump for MarkEmbling.Utils

--- MarkEmbling.Utils/Properties/AssemblyInfo.cs
+++ MarkEmbling.Utils/Properties/AssemblyInfo.cs
@@ -32,5 +32,5 @@
 // You can specify all the values or you can default the Build and Revision Numbers
 // by using the '*' as shown below:
 // [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("0.0.1.0")]
-[assembly: AssemblyFileVersion("0.0.1.0")]
+[assembly: AssemblyVersion("0.0.2.0")]
+[assembly: AssemblyFileVersion("0.0.2.0")]


upped version because last one had a bug

--- NadekoBot.Core/Services/Impl/StatsService.cs
+++ NadekoBot.Core/Services/Impl/StatsService.cs
@@ -23,7 +23,7 @@
         private readonly IBotCredentials _creds;
         private readonly DateTime _started;

-        public const string BotVersion = "2.33.1";
+        public const string BotVersion = "2.33.2";
         public string Author => "Kwoth#2452";
         public string Library => "Discord.Net";


version upped

version upped

--- NadekoBot.Core/Services/Impl/StatsService.cs
+++ NadekoBot.Core/Services/Impl/StatsService.cs
@@ -23,7 +23,7 @@
         private readonly IBotCredentials _creds;
         private readonly DateTime _started;

-        public const string BotVersion = "2.35.4";
+        public const string BotVersion = "2.35.5";
         public string Author => "Kwoth#2452";
         public string Library => "Discord.Net";


Fix a warning.

Fix a warning.

2009-01-25  Gabriel Burt  <gabriel.burt@gmail.com>

	* src/Libraries/Hyena/Hyena.Data.Sqlite/HyenaSqliteConnection.cs: Fix a
	warning.

svn path=/trunk/banshee/; revision=4970

--- Hyena/Hyena.Data.Sqlite/HyenaSqliteConnection.cs
+++ Hyena/Hyena.Data.Sqlite/HyenaSqliteConnection.cs
@@ -134,7 +134,7 @@
         public IDataReader Query (HyenaSqliteCommand command)
         {
             command.CommandType = HyenaCommandType.Reader;
-            QueueCommand (command, null);
+            QueueCommand (command);
             return command.WaitForResult (this) as SqliteDataReader;
         }

@@ -190,7 +190,7 @@
         public T Query<T> (HyenaSqliteCommand command)
         {
             command.CommandType = HyenaCommandType.Scalar;
-            QueueCommand (command, null);
+            QueueCommand (command);
             object result = command.WaitForResult (this);
             return (T)SqliteUtils.FromDbFormat (typeof (T), result);
         }
@@ -217,7 +217,7 @@
         public int Execute (HyenaSqliteCommand command)
         {
             command.CommandType = HyenaCommandType.Execute;;
-            QueueCommand(command, null);
+            QueueCommand(command);
             return (int) command.WaitForResult (this);
         }

@@ -378,9 +378,15 @@
             QueueCommand (command, null, args);
         }

-        private void QueueCommand(HyenaSqliteCommand command, object arg)
+        // TODO optimize object vs object [] code paths?
+        /*private void QueueCommand(HyenaSqliteCommand command, object arg)
         {
             QueueCommand (command, arg, null);
+        }*/
+
+        private void QueueCommand(HyenaSqliteCommand command)
+        {
+            QueueCommand (command, null, null);
         }

         private void QueueCommand(HyenaSqliteCommand command, object arg, object [] args)


#1495 Change Formatting tests to do a second pass and verify 'steady state'

--- Nodejs/Tests/AnalysisTests/FormatterTests.cs
+++ Nodejs/Tests/AnalysisTests/FormatterTests.cs
@@ -2035,7 +2035,13 @@

         private static void TestCode(string code, string expected, FormattingOptions options = null) {
-            Assert.AreEqual(expected, FormatCode(code, options));
+            var firstFormat = FormatCode(code, options);
+            Assert.AreEqual(expected, firstFormat);
+
+            // a second call to format on a formatted code should have no changes
+            var secondFormat = FormatCode(firstFormat, options);
+            Assert.AreEqual(firstFormat, secondFormat, "First and Second call to format had different results...");
+
         }

         private static void TestCode(int position, char ch, string code, string expected, FormattingOptions options = null) {


Sort usings

Sort usings

--- NuPack.Core/PackageWalker/UninstallWalker.cs
+++ NuPack.Core/PackageWalker/UninstallWalker.cs
@@ -1,10 +1,10 @@
 namespace NuPack {
     using System;
     using System.Collections.Generic;
+    using System.Diagnostics.CodeAnalysis;
     using System.Globalization;
     using System.Linq;
     using NuPack.Resources;
-    using System.Diagnostics.CodeAnalysis;

     public class UninstallWalker : BasicPackageWalker, IDependencyResolver {
         private Stack<IPackage> _packages;


Update Saboteur.cs

Update Saboteur.cs

Add cover variants and fix AOE.

--- trunk/DefaultCombat/Routines/Advanced/Gunslinger/Saboteur.cs
+++ trunk/DefaultCombat/Routines/Advanced/Gunslinger/Saboteur.cs
@@ -57,7 +57,7 @@

 					//Movement
 					CombatMovement.CloseDistance(Distance.Ranged),
-
+					Spell.Buff("Crouch", ret => !Me.IsInCover() && !Me.IsMoving),

 					//Rotation
 					Spell.Cast("Distraction", ret => Me.CurrentTarget.IsCasting && !DefaultCombat.MovementDisabled),
@@ -81,11 +81,12 @@
 			{
 				return new Decorator(ret => Targeting.ShouldAoe,
 					new PrioritySelector(
-						Spell.CastOnGround("XS Freighter Flyby"),
+						Spell.CastOnGround("XS Freighter Flyby", ret => Me.IsInCover() && Me.EnergyPercent > 30),
+						Spell.CastOnGround("Sweeping Gunfire", ret => Me.IsInCover() && Me.EnergyPercent > 30),
 						Spell.Cast("Incendiary Grenade"),
 						Spell.Cast("Thermal Grenade")
 						));
 			}
 		}
 	}
-}+}


Experimental timeout

Experimental timeout

Having a quick look at limiting how long to try sending a message to
Raygun during app crash

--- Mindscape.Raygun4Net.Xamarin.iOS/RaygunClient.cs
+++ Mindscape.Raygun4Net.Xamarin.iOS/RaygunClient.cs
@@ -572,7 +572,7 @@

     private bool SendMessage(string message)
     {
-      using (var client = new WebClient())
+      using (var client = new TimeoutWebClient())
       {
         client.Headers.Add("X-ApiKey", _apiKey);
         client.Headers.Add("content-type", "application/json; charset=utf-8");
@@ -707,5 +707,15 @@
         System.Diagnostics.Debug.WriteLine(string.Format("Error saving message to isolated storage {0}", ex.Message));
       }
     }
+
+    private class TimeoutWebClient : WebClient
+    {
+      protected override WebRequest GetWebRequest(Uri address)
+      {
+        WebRequest request = base.GetWebRequest(address);
+        request.Timeout = 5000;
+        return request;
+      }
+    }
   }
 }


git-svn-id: svn://localhost/mosa@760 45b04e34-05f1-4d87-a130-40a8491d5c8b

--- Mosa/Platforms/x86/IRToX86TransformationStage.cs
+++ Mosa/Platforms/x86/IRToX86TransformationStage.cs
@@ -695,7 +695,7 @@
                  * appear.
                  */
                 // int 3
-                _architecture.CreateInstruction(typeof(Instructions.IntInstruction), new ConstantOperand(new SigType(CilElementType.U1), (byte)3)),
+                //_architecture.CreateInstruction(typeof(Instructions.IntInstruction), new ConstantOperand(new SigType(CilElementType.U1), (byte)3)),
                 // Uncomment this line to enable breakpoints within Bochs
                 _architecture.CreateInstruction(typeof(Instructions.Intrinsics.BochsDebug), null),
                 // push ebp


[Modify] Polish it

[Modify] Polish it

--- websocket-sharp/Net/HttpListenerAsyncResult.cs
+++ websocket-sharp/Net/HttpListenerAsyncResult.cs
@@ -144,11 +144,13 @@
         asyncResult._completed = true;

         var waitHandle = asyncResult._waitHandle;
+
         if (waitHandle != null)
           waitHandle.Set ();
       }

       var callback = asyncResult._callback;
+
       if (callback == null)
         return;


Build tests fix.

Build tests fix.

--- ApplicationServices.Test/FileGenerator/ReportGeneratorTest.cs
+++ ApplicationServices.Test/FileGenerator/ReportGeneratorTest.cs
@@ -4,6 +4,7 @@
 using Core.ApplicationServices.FileGenerator;
 using Core.DomainModel;
 using NUnit.Framework;
+using Core.ApplicationServices.Logger;

 namespace ApplicationServices.Test.FileGenerator
 {
@@ -14,7 +15,7 @@
         public void WriteRecordsShouldAlterReportStatusToInvoiced()
         {
             var repoMock = new ReportRepositoryMock();
-            var reportGenerator = new ReportGenerator(repoMock, new FileWriterMock());
+            var reportGenerator = new ReportGenerator(repoMock, new FileWriterMock(), new Logger());

             Assert.AreEqual(ReportStatus.Accepted, repoMock.Report1.Status, "Status should be accepted before being passed to file generator");
             Assert.AreEqual(ReportStatus.Accepted, repoMock.Report2.Status, "Status should be accepted before being passed to file generator");
@@ -42,7 +43,7 @@
         {
             var repoMock = new ReportRepositoryMock();
             var writerMock = new FileWriterMock();
-            var reportGenerator = new ReportGenerator(repoMock, writerMock);
+            var reportGenerator = new ReportGenerator(repoMock, writerMock, new Logger());

             Assert.AreEqual(0, writerMock.RecordList.Count, "The writer should have an empty list before the generator is called");
             reportGenerator.WriteRecordsToFileAndAlterReportStatus();
@@ -56,7 +57,7 @@
         {
             var repoMock = new ReportRepositoryMock();
             var writerMock = new FileWriterMock();
-            var reportGenerator = new ReportGenerator(repoMock, writerMock);
+            var reportGenerator = new ReportGenerator(repoMock, writerMock, new Logger());

             Assert.AreEqual(0, writerMock.RecordList.Count, "The writer should have an empty list before the generator is called");
             reportGenerator.WriteRecordsToFileAndAlterReportStatus();
@@ -72,7 +73,7 @@
         {
             var repoMock = new ReportRepositoryMock();
             var writerMock = new FileWriterMock();
-            var reportGenerator = new ReportGenerator(repoMock, writerMock);
+            var reportGenerator = new ReportGenerator(repoMock, writerMock, new Logger());

             Assert.AreEqual(0, writerMock.RecordList.Count, "The writer should have an empty list before the generator is called");
             reportGenerator.WriteRecordsToFileAndAlterReportStatus();


ソースコードの文字コード問題対処.

ソースコードの文字コード問題対処.

--- Assets/Scripts/Common/Data/Standard/Riff/Wave/RiffWaveBext.cs
+++ Assets/Scripts/Common/Data/Standard/Riff/Wave/RiffWaveBext.cs
@@ -8,18 +8,18 @@
 	{
 		public const string ID = "bext";

-		public readonly string description;			// ASCII or S-JIS, Description of the sound sequence
-		public readonly string originator;			// ASCII or S-JIS, 制作会社、制作者名
-		public readonly string originatorReference;	// ASCII or S-JIS, 制作ユニークコード
-		public readonly string originationDate;		// ASCII, 制作年月日 yyyy-mm-dd
-		public readonly string originationTime;		// ASCII, 制作時刻 hh:mm:ss
-		public readonly UInt32 timeReferenceLow;	// First sample count since midnight, low word
-		public readonly UInt32 timeReferenceHigh;	// First sample count since midnight, high word
-		public readonly UInt16 version;				// BWF-Jのバージョン番号
-		public readonly Byte[] umid;				// Binary Byte 0 of SMPTE UMID
-		//public readonly Byte umid_63;				// Binary Byte 63 of SMPTE UMID
-		public readonly Byte[] reserved;			// 190 Bytes, reserved for future use, set to “NULL”
-		public readonly string codingHistory;		// ASCII or S-JIS, Coding history
+		public readonly string description;
+		public readonly string originator;
+		public readonly string originatorReference;
+		public readonly string originationDate;
+		public readonly string originationTime;
+		public readonly UInt32 timeReferenceLow;
+		public readonly UInt32 timeReferenceHigh;
+		public readonly UInt16 version;
+		public readonly Byte[] umid;
+		//public readonly Byte umid_63;
+		public readonly Byte[] reserved;
+		public readonly string codingHistory;

 		public RiffWaveBext( string aId, UInt32 aSize, ByteArray aByteArray, RiffChunkList aParent )
 			: base( aId, aSize, aByteArray, aParent )


Map ResponseStatus default to NEEDS-ACTION in MapParticipation1To2 to avoid exception.

--- CalDavSynchronizer/Implementation/Events/EventEntityMapper.cs
+++ CalDavSynchronizer/Implementation/Events/EventEntityMapper.cs
@@ -361,14 +361,14 @@
           return "DECLINED";
         case OlResponseStatus.olResponseNone:
           return null;
-        case OlResponseStatus.olResponseNotResponded:
-          return "NEEDS-ACTION";
         case OlResponseStatus.olResponseOrganized:
           return "ACCEPTED";
         case OlResponseStatus.olResponseTentative:
           return "TENTATIVE";
-      }
-      throw new NotImplementedException (string.Format ("Mapping for value '{0}' not implemented.", value));
+        case OlResponseStatus.olResponseNotResponded:
+        default:
+          return "NEEDS-ACTION";
+      }
     }

     private OlResponseStatus MapParticipation2To1 (string value)


Avoid possible NullReferenceExceptions in MapAttendeesandOrganizer2To1

--- CalDavSynchronizer/Implementation/Events/EventEntityMapper.cs
+++ CalDavSynchronizer/Implementation/Events/EventEntityMapper.cs
@@ -1396,7 +1396,7 @@
           }
         }

-        if (source.Organizer != null)
+        if (source.Organizer != null && source.Organizer.Value != null)
         {
           string sourceOrganizerEmail = string.Empty;

@@ -1415,7 +1415,15 @@

             target.MeetingStatus = OlMeetingStatus.olMeetingReceived;

-            targetRecipient = target.Recipients.Add (source.Organizer.CommonName + "<" + sourceOrganizerEmail + ">");
+            if (!string.IsNullOrEmpty (source.Organizer.CommonName))
+            {
+              targetRecipient = target.Recipients.Add (source.Organizer.CommonName + "<" + sourceOrganizerEmail + ">");
+            }
+            else
+            {
+              targetRecipient = target.Recipients.Add (sourceOrganizerEmail);
+            }
+
             recipientsToDispose.Add (targetRecipient);
             targetRecipientsWhichShouldRemain.Add (targetRecipient);
             targetRecipient.Type = (int) OlMeetingRecipientType.olOrganizer;
@@ -1428,35 +1436,38 @@
               {
                 using (var organizerAddressEntry = GenericComObjectWrapper.Create (targetRecipient.AddressEntry))
                 {
-                  organizerID = organizerAddressEntry.Inner.ID;
-                }
-              }
-
-              var propertyTagsSentRepresenting = new object[] { PR_SENT_REPRESENTING_NAME, PR_SENT_REPRESENTING_EMAIL_ADDRESS, PR_SENT_REPRESENTING_ADDRTYPE, PR_SENT_REPRESENTING_ENTRYID };
-              var propertyTagsSender = new object[] { PR_SENDER_NAME, PR_SENDER_EMAIL_ADDRESS, PR_SENT_REPRESENTING_ADDRTYPE, PR_SENDER_ENTRYID };
-              object[] propertyValues;
-
-              if (source.Organizer.CommonName != null)
-              {
-                propertyValues = new object[] { source.Organizer.CommonName, sourceOrganizerEmail, "SMTP", oPa.Inner.StringToBinary (organizerID) };
-              }
-              else
-              {
-                propertyValues = new object[] { sourceOrganizerEmail, sourceOrganizerEmail, "SMTP", oPa.Inner.StringToBinary (organizerID) };
-              }
-
-              try
-              {
-                oPa.Inner.SetProperties (propertyTagsSentRepresenting, propertyValues);
-
-                if (_outlookMajorVersion >= 15)
-                {
-                  oPa.Inner.SetProperties (propertyTagsSender, propertyValues);
-                }
-              }
-              catch (COMException ex)
-              {
-                s_logger.Error ("Could not set property PR_SENDER_* for organizer", ex);
+                  organizerID = organizerAddressEntry.Inner != null ? organizerAddressEntry.Inner.ID : null;
+                }
+              }
+
+              if (organizerID != null && oPa.Inner != null)
+              {
+                var propertyTagsSentRepresenting = new object[] { PR_SENT_REPRESENTING_NAME, PR_SENT_REPRESENTING_EMAIL_ADDRESS, PR_SENT_REPRESENTING_ADDRTYPE, PR_SENT_REPRESENTING_ENTRYID };
+                var propertyTagsSender = new object[] { PR_SENDER_NAME, PR_SENDER_EMAIL_ADDRESS, PR_SENT_REPRESENTING_ADDRTYPE, PR_SENDER_ENTRYID };
+                object[] propertyValues;
+
+                if (source.Organizer.CommonName != null)
+                {
+                  propertyValues = new object[] { source.Organizer.CommonName, sourceOrganizerEmail, "SMTP", oPa.Inner.StringToBinary(organizerID) };
+                }
+                else
+                {
+                  propertyValues = new object[] { sourceOrganizerEmail, sourceOrganizerEmail, "SMTP", oPa.Inner.StringToBinary(organizerID) };
+                }
+
+                try
+                {
+                  oPa.Inner.SetProperties (propertyTagsSentRepresenting, propertyValues);
+
+                  if (_outlookMajorVersion >= 15)
+                  {
+                    oPa.Inner.SetProperties (propertyTagsSender, propertyValues);
+                  }
+                }
+                catch (COMException ex)
+                {
+                  s_logger.Error ("Could not set property PR_SENDER_* for organizer", ex);
+                }
               }
             }
           }


Rework of exdate generation to work around some strange Outlook Exception Collection missing elements, fixes Bug #91 and other recurrence exceptions with complex patterns

--- CalDavSynchronizer/Implementation/Events/EventEntityMapper.cs
+++ CalDavSynchronizer/Implementation/Events/EventEntityMapper.cs
@@ -547,48 +547,53 @@

           target.RecurrenceRules.Add (targetRecurrencePattern);

-          Dictionary<DateTime, PeriodList> targetExceptionDatesByOriginalOutlookDate = new Dictionary<DateTime, PeriodList>();
+          Dictionary<DateTime, PeriodList> targetExceptionDatesByDate = new Dictionary<DateTime, PeriodList>();
           HashSet<DateTime> originalOutlookDatesWithExceptions = new HashSet<DateTime>();

           foreach (var sourceException in sourceRecurrencePattern.Exceptions.ToSafeEnumerable<Exception>())
           {
             if (!sourceException.Deleted)
             {
-              targetExceptionDatesByOriginalOutlookDate.Remove (sourceException.OriginalDate);
               originalOutlookDatesWithExceptions.Add (sourceException.OriginalDate);
+            }
+          }
+          foreach (var sourceException in sourceRecurrencePattern.Exceptions.ToSafeEnumerable<Exception>())
+          {
+            if (!sourceException.Deleted)
+            {
+              targetExceptionDatesByDate.Remove (sourceException.OriginalDate.Date);

               var targetException = new Event();
               target.Calendar.Events.Add (targetException);
               targetException.UID = target.UID;
-              using (var wrapper = new AppointmentItemWrapper (sourceException.AppointmentItem, _ => { throw new InvalidOperationException ("Cannot reload exception AppointmentITem!"); }))
+              using (var wrapper = new AppointmentItemWrapper (sourceException.AppointmentItem, _ => { throw new InvalidOperationException("Cannot reload exception AppointmentITem!"); }))
               {
                 Map1To2 (wrapper.Inner, targetException, true, startIcalTimeZone, endIcalTimeZone);

                 // check if new exception is already present in target
                 // if it is found and not already present as exdate then add a new exdate to avoid 2 events
-                var targetContainsExceptionList = target.GetOccurrences (wrapper.Inner.Start.Date, wrapper.Inner.End.Date.AddDays (1));
-                if (targetContainsExceptionList.Count > 0)
-                {
-                  if (!originalOutlookDatesWithExceptions.Contains (wrapper.Inner.Start) && wrapper.Inner.Start.Date != sourceException.OriginalDate.Date)
+                var from = (wrapper.Inner.Start.Date < sourceException.OriginalDate.Date) ? wrapper.Inner.Start.Date : sourceException.OriginalDate.Date;
+                var to = (wrapper.Inner.Start.Date > sourceException.OriginalDate.Date) ? wrapper.Inner.Start.Date.AddDays (1) : sourceException.OriginalDate.Date.AddDays (1);
+
+                var targetContainsExceptionList = target.GetOccurrences (from, to);
+                foreach (var el in targetContainsExceptionList)
+                {
+                  if (!originalOutlookDatesWithExceptions.Contains (el.Period.StartTime.Value))
                   {
                     PeriodList targetExList = new PeriodList();

-                    if (wrapper.Inner.AllDayEvent)
+                    if (!el.Period.StartTime.HasTime)
                     {
-                      iCalDateTime exDate = new iCalDateTime (wrapper.Inner.Start);
+                      iCalDateTime exDate = new iCalDateTime (el.Period.StartTime.Date);
                       exDate.HasTime = false;
                       targetExList.Add (exDate);
                       targetExList.Parameters.Add ("VALUE", "DATE");
                     }
                     else
                     {
-                      var timeZone = TimeZoneInfo.FindSystemTimeZoneById (wrapper.Inner.StartTimeZone.ID);
-                      var originalDateUtc = TimeZoneInfo.ConvertTimeToUtc (wrapper.Inner.StartInStartTimeZone.Date, timeZone);
-                      iCalDateTime exDate = new iCalDateTime (originalDateUtc.Add (source.StartInStartTimeZone.TimeOfDay)) { IsUniversalTime = true };
-
-                      targetExList.Add (exDate);
+                      targetExList.Add (new iCalDateTime (el.Period.StartTime.UTC) { IsUniversalTime = true });
                     }
-                    targetExceptionDatesByOriginalOutlookDate.Add (wrapper.Inner.Start.Date.Add (source.StartInStartTimeZone.TimeOfDay), targetExList);
+                    targetExceptionDatesByDate.Add (el.Period.StartTime.Date, targetExList);
                   }
                 }
               }
@@ -627,11 +632,11 @@

                   targetExList.Add (exDate);
                 }
-                targetExceptionDatesByOriginalOutlookDate.Add (sourceException.OriginalDate, targetExList);
-              }
-            }
-          }
-          target.ExceptionDates.AddRange (targetExceptionDatesByOriginalOutlookDate.Values);
+                targetExceptionDatesByDate.Add (sourceException.OriginalDate, targetExList);
+              }
+            }
+          }
+          target.ExceptionDates.AddRange (targetExceptionDatesByDate.Values);
         }
       }
     }


Fix entering noclip when a locker is closed over a buckled entity and the chair is then deleted

--- Content.Server/GameObjects/Components/Mobs/BuckleComponent.cs
+++ Content.Server/GameObjects/Components/Mobs/BuckleComponent.cs
@@ -212,8 +212,12 @@
                     .PlayFromEntity(strap.UnbuckleSound, Owner);
             }

-            Owner.Transform.DetachParent();
-            Owner.Transform.WorldRotation = BuckledTo.Owner.Transform.WorldRotation;
+            if (Owner.Transform.Parent == BuckledTo.Owner.Transform)
+            {
+                Owner.Transform.DetachParent();
+                Owner.Transform.WorldRotation = BuckledTo.Owner.Transform.WorldRotation;
+            }
+
             BuckledTo = null;

             if (Owner.TryGetComponent(out AppearanceComponent appearance))
@@ -268,12 +272,12 @@
             base.Startup();
             BuckleStatus();
         }
-
         public override void OnRemove()
         {
             base.OnRemove();

-            if (BuckledTo != null && BuckledTo.Owner.TryGetComponent(out StrapComponent strap))
+            if (BuckledTo != null &&
+                BuckledTo.Owner.TryGetComponent(out StrapComponent strap))
             {
                 strap.Remove(this);
             }


Add DeployApplicationPackageToAppCatalog method to automate package deployment

--- Core/OfficeDevPnP.Core/AppModelExtensions/TenantExtensions.cs
+++ Core/OfficeDevPnP.Core/AppModelExtensions/TenantExtensions.cs
@@ -683,6 +683,73 @@
         }
         #endregion

+        #region ClientSide Package Deployment
+        /// <summary>
+        /// Adds a package to the tenants app catalog and by default deploys it if the package is a client side package (sppkg)
+        /// </summary>
+        /// <param name="tenant">Tenant to operate against</param>
+        /// <param name="appCatalogSiteUrl">Full url to the tenant admin site (e.g. https://contoso.sharepoint.com/sites/apps) </param>
+        /// <param name="spPkgName">Name of the package to upload (e.g. demo.sppkg) </param>
+        /// <param name="spPkgPath">Path on the filesystem where this package is stored</param>
+        /// <param name="autoDeploy">Automatically deploy the package, only applies to client side packages (sppkg)</param>
+        /// <param name="overwrite">Overwrite the package if it was already listed in the app catalog</param>
+        /// <returns>The ListItem of the added package row</returns>
+        public static ListItem DeployApplicationPackageToAppCatalog(this Tenant tenant, string appCatalogSiteUrl, string spPkgName, string spPkgPath, bool autoDeploy=true, bool overwrite=true)
+        {
+            if (String.IsNullOrEmpty(appCatalogSiteUrl))
+            {
+                throw new ArgumentException("Please specify a app catalog site url");
+            }
+
+            Uri catalogUri;
+            if (!Uri.TryCreate(appCatalogSiteUrl, UriKind.Absolute, out catalogUri))
+            {
+                throw new ArgumentException("Please specify a valid app catalog site url");
+            }
+
+            if (String.IsNullOrEmpty(spPkgName))
+            {
+                throw new ArgumentException("Please specify a package name");
+            }
+
+            if (String.IsNullOrEmpty(spPkgPath))
+            {
+                throw new ArgumentException("Please specify a package path");
+            }
+
+            using (var appCatalogContext = tenant.Context.Clone(catalogUri))
+            {
+                List catalog = appCatalogContext.Web.GetListByUrl("appcatalog");
+                if (catalog == null)
+                {
+                    throw new Exception($"No app catalog found...did you provide a valid app catalog site?");
+                }
+
+                Folder rootFolder = catalog.RootFolder;
+
+                // Upload package
+                var sppkgFile = rootFolder.UploadFile(spPkgName, System.IO.Path.Combine(spPkgPath, spPkgName), overwrite);
+                if (sppkgFile == null)
+                {
+                    throw new Exception($"Upload of {spPkgName} failed");
+                }
+
+                if (autoDeploy && System.IO.Path.GetExtension(spPkgName).ToLower() == ".sppkg")
+                {
+                    // Trigger "deployment" by setting the IsClientSideSolutionDeployed bool to true which triggers
+                    // an event receiver that will process the sppkg file and update the client side componenent manifest list
+                    sppkgFile.ListItemAllFields["IsClientSideSolutionDeployed"] = true;
+                    sppkgFile.ListItemAllFields.Update();
+                }
+
+                appCatalogContext.Load(sppkgFile.ListItemAllFields);
+                appCatalogContext.ExecuteQueryRetry();
+
+                return sppkgFile.ListItemAllFields;
+            }
+        }
+        #endregion
+
         #region Private helper methods
         private static bool WaitForIsComplete(Tenant tenant, SpoOperation op, Func<TenantOperationMessage, bool> timeoutFunction = null, TenantOperationMessage operationMessage = TenantOperationMessage.None)
         {


Amend.

Amend.

--- Gu.Analyzers.Analyzers/Helpers/SymbolHelpers/TypeSymbolExt.cs
+++ Gu.Analyzers.Analyzers/Helpers/SymbolHelpers/TypeSymbolExt.cs
@@ -10,6 +10,10 @@
     [SuppressMessage("ReSharper", "UnusedMember.Global")]
     internal static partial class TypeSymbolExt
     {
+        internal static bool IsEither(this ITypeSymbol symbol, QualifiedType t1, QualifiedType t2) => symbol == t1 || symbol == t2;
+
+        internal static bool IsEither(this ITypeSymbol symbol, QualifiedType t1, QualifiedType t2, QualifiedType t3) => symbol == t1 || symbol == t2 || symbol == t3;
+
         internal static bool IsSameType(this ITypeSymbol first, ITypeSymbol other)
         {
             if (ReferenceEquals(first, other) ||


- fixed issue #12: HTTP sessions are not reused

--- HudsonTrayTracker/BusinessComponents/ProjectsUpdateService.cs
+++ HudsonTrayTracker/BusinessComponents/ProjectsUpdateService.cs
@@ -39,7 +39,7 @@

         ConfigurationService configurationService;
         HudsonService hudsonService;
-        SmartThreadPool threadPool = new SmartThreadPool(60, TOTAL_THREAD_COUNT);
+        SmartThreadPool threadPool = new SmartThreadPool(3600, TOTAL_THREAD_COUNT, TOTAL_THREAD_COUNT);

         Timer timer;
         int timeBetweenUpdates = DEFAULT_TIME_BETWEEN_UPDATES;


relation fixed

relation fixed

--- Kooboo.CMS/Kooboo.CMS.Web/Areas/Sites/Views/Home/Index.cshtml
+++ Kooboo.CMS/Kooboo.CMS.Web/Areas/Sites/Views/Home/Index.cshtml
@@ -21,6 +21,9 @@
     var site =  @Html.Raw(JsonConvert.SerializeObject(ViewBag.Sites, Formatting.Indented))
     var content = @Html.Raw(JsonConvert.SerializeObject(ViewBag.Databases, Formatting.Indented))
     var membership = @Html.Raw(JsonConvert.SerializeObject(ViewBag.Memberships, Formatting.Indented))
+
+	console.log(site);
+	console.log(content);

     var max_length = Math.max(site.length, content.length, membership.length);

@@ -113,10 +116,10 @@
 				.text(function (d) { return d.text });

     var hasMemberships = _.filter(site,function(d){
-       return d.membership >0;
+       return d.membership > -1;
     });
     var hasContents = _.filter(site,function(d){
-        return d.content >0;
+        return d.content > -1;
     });

     // lines
@@ -188,22 +191,38 @@
         }
         var content_index = site[index]['content'];
         var membership_index = site[index]['membership'];
-        $('.content-rect').eq(content_index).attr('fill', '#d24726');
-        $('.membership-rect').eq(membership_index).attr('fill', '#d24726');
+        if(content_index > -1){
+        	$('.content-rect').eq(content_index).attr('fill', '#d24726');
+        }
+        if(membership_index > -1){
+        	$('.membership-rect').eq(membership_index).attr('fill', '#d24726');
+        }
     });
     $('.content-rect').on('click', function (e) {
         $('.content-rect').attr('fill', '#1076a6');
         $('.site-rect').attr('fill', '#3ca8db');
         $('.membership-rect').attr('fill', '#3cbabb');
         $(this).attr('fill', '#d24726');
-        var index = content.indexOf($(this).data('name'));
+        var click_name = $(this).data('name');
+        for(var i=0;i<content.length;i++){
+        	if(content[i].name==click_name){
+        		var index = i;
+        		break;
+        	} else {
+        		continue;
+        	}
+        }
         for (var i = 0; i < site.length; i++) {
             if (site[i]['content'] == index) {
                 $('.site-rect').eq(site[i]['num']).attr('fill', '#d24726');
                 var content_index = site[i]['content'];
                 var membership_index = site[i]['membership'];
-                $('.content-rect').eq(content_index).attr('fill', '#d24726');
-                $('.membership-rect').eq(membership_index).attr('fill', '#d24726');
+                if(content_index > -1){
+                	$('.content-rect').eq(content_index).attr('fill', '#d24726');
+                }
+                if(membership_index > -1){
+                	$('.membership-rect').eq(membership_index).attr('fill', '#d24726');
+                }
             }
         }
     });
@@ -212,14 +231,26 @@
         $('.site-rect').attr('fill', '#3ca8db');
         $('.membership-rect').attr('fill', '#3cbabb');
         $(this).attr('fill', '#d24726');
-        var index = membership.indexOf($(this).data('name'));
+        var click_name = $(this).data('name');
+        for(var i=0;i<membership.length;i++){
+        	if(membership[i].name==click_name){
+        		var index = i;
+        		break;
+        	} else {
+        		continue;
+        	}
+        }
         for (var i = 0; i < site.length; i++) {
             if (site[i]['membership'] == index) {
                 $('.site-rect').eq(site[i]['num']).attr('fill', '#d24726');
                 var content_index = site[i]['content'];
                 var membership_index = site[i]['membership'];
-                $('.content-rect').eq(content_index).attr('fill', '#d24726');
-                $('.membership-rect').eq(membership_index).attr('fill', '#d24726');
+                if(content_index > -1){
+                	$('.content-rect').eq(content_index).attr('fill', '#d24726');
+                }
+                if(membership_index > -1){
+                	$('.membership-rect').eq(membership_index).attr('fill', '#d24726');
+                }
             }
         }
     })


Fix last edit.

Fix last edit.

--- LCIAToolAPI/CalRecycleLCA.Services/FlowFlowPropertyService.cs
+++ LCIAToolAPI/CalRecycleLCA.Services/FlowFlowPropertyService.cs
@@ -53,15 +53,15 @@
         /// <returns></returns>
         public ICollection<FlowPropertyMagnitude> GetFlowPropertyMagnitudes(FragmentFlowResource ff, int scenarioId)
         {
-            IEnumerable<FlowPropertyMagnitude> ffpData =
-                (ff.FlowID == null ? new List<FlowPropertyMagnitude>()
-                : _repository.GetFlowPropertyMagnitudes((int)ff.FlowID, scenarioId));
+            ICollection<FlowPropertyMagnitude> ffpData =
+                (ff.FlowID == null ? new List<FlowPropertyMagnitude>()
+                : _repository.GetFlowPropertyMagnitudes((int)ff.FlowID, scenarioId)).ToList();
             if (ff.NodeWeight != null)
                 foreach (var fp in ffpData)
                 {
                     fp.Magnitude *= (double)ff.NodeWeight;
                 }
-            return ffpData.ToList();
+            return ffpData;

         }


One final improvement to instanced geometry in the libomv model: create only the necessary assets.

--- OpenMetaverse/ImportExport/ColladalLoader.cs
+++ OpenMetaverse/ImportExport/ColladalLoader.cs
@@ -452,6 +452,7 @@
                         var nodes = Nodes.FindAll(n => n.MeshID == geo.id);
                         if (nodes != null)
                         {
+                            byte[] mesh_asset = null;
                             foreach (var node in nodes)
                             {
                                 var prim = new ModelPrim();
@@ -474,7 +475,13 @@
                                     }
                                 }

-                                prim.CreateAsset(UUID.Zero);
+                                if (mesh_asset == null)
+                                {
+                                    prim.CreateAsset(UUID.Zero);
+                                    mesh_asset = prim.Asset;
+                                }
+                                else
+                                    prim.Asset = mesh_asset;
                             }
                         }
                     }


Slightly improve "Unable to space collide" logging message, though I don't think I've ever seen this.

--- OpenSim/Region/Physics/OdePlugin/OdeScene.cs
+++ OpenSim/Region/Physics/OdePlugin/OdeScene.cs
@@ -1556,8 +1556,9 @@
                 }
                 catch (AccessViolationException)
                 {
-                    m_log.Warn("[PHYSICS]: Unable to space collide");
-                }
+                    m_log.WarnFormat("[PHYSICS]: Unable to space collide {0}", Name);
+                }
+
                 //float terrainheight = GetTerrainHeightAtXY(chr.Position.X, chr.Position.Y);
                 //if (chr.Position.Z + (chr.Velocity.Z * timeStep) < terrainheight + 10)
                 //{


screensavver

screensavver

--- OpenTK/Dibuixos/DibuixScreenSaver/Program.cs
+++ OpenTK/Dibuixos/DibuixScreenSaver/Program.cs
@@ -217,6 +217,12 @@
 using System.Threading.Tasks;
 using System.Windows.Forms;

+/*
+[HKEY_CURRENT_USER\Control Panel\Desktop]
+"ScreenSaveTimeOut"="7200"
+"SCRNSAVE.EXE"="C:\\WINDOWS\\system32\\scrnsave.scr"
+ */
+
 namespace DibuixScreenSaver
 {
     static class Program


Don't crash if clipboard unavailable

Don't crash if clipboard unavailable

--- PlatformWin32/win32/WindowsFormsClipboard.cs
+++ PlatformWin32/win32/WindowsFormsClipboard.cs
@@ -9,12 +9,25 @@
 	{
 		public string GetText()
 		{
-			return System.Windows.Forms.Clipboard.GetText();
+			try
+			{
+				return System.Windows.Forms.Clipboard.GetText();
+			}
+			catch
+			{
+				return "Clipboard Failed";
+			}
 		}

 		public void SetText(string text)
 		{
-			System.Windows.Forms.Clipboard.SetText(text);
+			try
+			{
+				System.Windows.Forms.Clipboard.SetText(text);
+			}
+			catch
+			{
+			}
 		}

 		public bool ContainsText