Commit Graph

81 Commits

Author SHA1 Message Date
Martin Molinero 9631cd6749 Fix nuget QC dependency version 2020-05-21 16:21:59 -03:00
Martin Molinero 09c17b71ed Add assembly description to nuspec
- Due to bug in nuget failing to replace description and copyright token, setting
  .nuspec description to match assembly description
2020-05-21 14:42:12 -03:00
Martin-Molinero 1d0d4f4d7b Add assembly descriptions (#4442)
Add assembly descriptions
2020-05-21 09:35:12 -07:00
Martin Molinero 891cf4d69b Update to .Net 4.6.2 2020-05-15 17:32:46 -03:00
Martin Molinero e73e927c0f Enable parallel unit testing 2020-04-27 17:45:53 -03:00
Martin Molinero f01185227b Remove QC StreamingApi client
- Removing unused QC StreamingApi client
2020-04-27 12:23:28 -03:00
Laur Aliste 47748a9a61 fix StreamingMessageHandler - null reference
- assign value to _orderEventJsonConverter in SetAuthentication()
  _before_ it's referenced by Transmit(), fixing nullpointer;
2020-04-16 03:00:25 +02:00
Martin Molinero 24b6cc6d9a Refactor Order and OrderEvent json
- Adding new SerializedOrderEvent and SerializedOrder with new
  JsonConverters
- Specifying OrderEvent json converter when storing, streaming data
- Adding unit tests
2020-04-07 17:40:25 -03:00
Adam May 18e481ef58 Make IMessagingHandler extend from IDisposable to allow for packing up of resources 2020-03-19 12:28:10 -03:00
Martin Molinero 0027ab1e66 Regression test assert order list hash
- Regression tests assert order list hash value
- Normalizing some regression test behavior that had differences between
C# and Py
2020-02-19 20:26:12 -03:00
Stefano Raggi e0a08cbb8d Add XML documentation generation for release builds 2019-12-14 13:50:10 +01:00
Michael Handschuh c7df4e9fb3 Add StringExtensions and Parse utilizing CultureInfo.InvariantCulture
Adds static methods of the form Parse.<TypeName>(string str) that use
CultureInfo.InvariantCulture. These are to be used when parsing strings.
It's still safe (from the CA1304/CA1305 perspective) to use the ToDecimal
extension method for decimals.

Adds string extension methods for common operations that will now require
CultureInfo.InvariantCulture. These are to be used when converting values
to strings, such as ToStringInvariant()/ToStringInvariant(format), but also
useful for searching within strings, StartsWithInvariant, EndsWithInvariant
 and IndexOfInvariant.
2019-08-16 18:08:28 -03:00
Michael Handschuh 703f915182 Configure QuantConnect.ruleset in all projects
The initial ruleset is specifically aimed at addressing #3045. When we'd like
to start addressing other issues available via the FxCopAnalyzers, we can update
the action in QuantConnect.ruleset. A nice way to do it is to first set it to
warning, then go through the solution, project-by-project, fixing each warning.
At the end you can flip it to error and ensure it still builds. Moving forward,
any changes will fail if they violate the rule.

In support of #3045, we'll be configuring the following rules:
> CA1304: https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1304-specify-cultureinfo?view=vs-2017
> CA1305: https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1305-specify-iformatprovider?view=vs-2017
2019-08-16 18:08:18 -03:00
Michael Handschuh c42057809d Add Microsoft.CodeAnalysis.FxCopAnalyzers to all projects
FxCop has various rulesets for enforcing things within our codebase.
For this particular issue, we'll be enforcing CA1304 and CA1305 to
ensure we're always using an IFormatProvider or a CultureInfo where
applicable.

Linked Issue: #3045
2019-08-16 18:08:05 -03:00
Stefano Raggi e39791ac6c Upgrade RestSharp library from v105.2.3 to v106.6.10 2019-07-17 10:28:35 +02:00
Gerardo Salazar 2033c7873b Update outdated DotNetZip dependency in nuspec files 2019-07-02 18:02:23 -07:00
Martin Molinero f6b5e92a96 Add conditional optimization flag 2019-06-19 16:11:15 -03:00
Martin Molinero c58b479578 Reduce shutdown time 2019-06-14 16:05:45 -03:00
Michael Handschuh 87d18b609d Improve process for updating regression statistics
Can now simply flip a flag in the code at the top of Messaging.cs or
specify via configuration 'regression-update-statistics' and it will
automatically update the code statistics using the statistics from
the current run. Useful when updating factor files and need to update
all statistics :P
2018-06-07 11:43:56 -04:00
Juan José D'Ambrosio bda5b11cc2 Nuspec files added for all projects.
Launcher project is packed as `QuantConnect.Lean`but as a mean ot having all Lean features just calling one package. 

In the same sense, `QuantConnect.Algorithm.CSharp` is included as package and added as dependecy in the `QuantConnect.Lean` package just to have a working example aailable out-of-the-box.
2018-04-13 07:28:34 -03:00
Michael Handschuh 6b239674e2 Renames Alpha -> Insight
The term 'alpha' is used to describe the entire algorithm. Therefore, 'alpha'
produces insights. From this we have things like IAlphaModel, which is the model
defining how insights are produced. We have IAlphaHandler, which defines how the
insights from a single 'alpha' (the algorithm) are managed, analyzed, and stored.
Types closer to the individual prediction level, such as InsightDirection, or
InsightScore relate directly to exactly 1 insight. The distinction between the
two became more clear as we developed the insights API, and from that effort it
was decided to harmonize alpha/insight terminology across the various QC systems.
2018-03-09 16:12:56 -05:00
Michael Handschuh 69d3a10a93 Decompose DefaultAlphaHandler into IAlphaManagerExtension
The IAlphaManagerExtension defines a type that needs to react to events produced
by the AlphaManager. The actual events were removed in favor of a interface to
handle the events. This removes the need to wire events and instead just pass the
extensions to the alph manager and it will handle invoking the extensions at the
appropriate time.

This change removes all charting and statistics aggregation logic from the alpha
handler and moves it into dedicated types, AlphaChartingManagerExtension and
AlphaStatisticsManagerExtension. The resulting types are highly decoupled from the
LEAN ecosystem allowing them to be easily unit tested, whereas before the logic
was embedded in a handler with many many dependencies which would be very hard to
properly unit test.

As part of this change (and in preparation for moving scoring to the alpha thread)
the resolution of SecurityValues was removed from the alpha manager. In this new
pattern, the alpha manager is pushed generated alphas and security values at each
time step.
2018-01-12 12:08:40 -05:00
Michael Handschuh d38323b98c Add alpha statistics regression test functionality
When the algorithm finishes, the alpha statistics are merged with the backtest
result statistics. This keeps the regression testing pattern of alpha statistics
the same as the existing regular statistics.
2018-01-12 12:08:40 -05:00
Michael Handschuh 363003815b Rename AlphaPacket -> AlphaResultPacket
Making room for the AlphaWorkPacket
2018-01-04 12:43:41 -05:00
Michael Handschuh b4b3aae112 Rename Signal -> Alpha
Whoa... I think I got everything :)
2017-12-15 18:24:58 -05:00
Michael Handschuh 5910bc620f Add ISignalHandler
Handles signals generated by the algorithm. The default implementation
sends a SignalPacket to the messaging handler.
2017-12-12 08:56:19 -05:00
Andrew f8ef941690 Add 5 minute timout to the RestClient in StreamingApi 2017-09-18 17:54:13 -04:00
Andrew e116709b24 Specify <LangVersion> of 6 in all csproj files 2017-08-07 15:27:26 -04:00
Stefano Raggi 087a69f002 Upgrade libraries AsyncIO, Castle.Core, Moq, NetMQ, NUnit, NLog 2017-07-08 00:07:17 +02:00
Stefano Raggi d88d82af12 Upgrade Json.NET to version 10.0.3 2017-07-07 23:21:47 +02:00
Stefano Raggi e463ccf088 Upgrade all projects to target .NET Framework 4.5.2
In the advanced build settings, Language version was also upgraded from C# 5.0 to C# 6.0. The minimum Visual Studio version required will now be VS2015.
2017-07-07 22:49:17 +02:00
Victor Baybekov de21307a32 Update Json.Net to 9.0.1 2017-03-14 01:35:59 +03:00
Andrew 27fd860be1 Added processing of SystemDebug messages 2017-02-27 15:02:49 -05:00
Andrew Hart 5a633df6e9 Make xml comment file names consistent across projects
For project that have xml comment files, make the comment file end with .xml instead of .Xml or .XML.
2016-12-30 16:18:54 -05:00
Andrew Hart bbb7f28525 Refactored StreamMessageHandler to send packet only.
In order to avoid switching on types in StreamingMessageHandler, the NetMQ tcp Push Socket will now only send the serialized packet to the desktop client, instead of the serialized packet and the packet type.

The DesktopClient now only accepts single part messages in order to accomadate the changes in StreamingMessageHandler.  The type of the packet is distinguished in the DesktopClient because StreamingMessageHandler does not disnguish the types of the packets.

The StreamingMessageHandler tests and DesktopClientTests have been altered to reflect these changes.
2016-09-01 09:39:21 -04:00
Andrew Hart 588ae2c21a Added new message handler: StreamingMessageHandler
This message handler uses NetMQ Push socket to push messages over tcp to a client.  It makes no garantees about the client.  It will always send two part messages.  The first part of the message is the resource and the second part of the message is the serialized packet.
2016-08-31 11:59:06 -04:00
AlexCatarino d3e45f4b26 Fixes desktop not displaying charts
When algorithm run ends before the message system is loaded (it depends on the UX loading), enqueued packets used on charting are never sent to the UX.
2016-07-28 18:36:45 -03:00
devalkeralia dd3a487c78 Changed the error message 2016-06-27 19:35:02 -04:00
devalkeralia 9aa6ff807b Added a try catch block to catch the exception thrown by response.Content 2016-06-27 19:25:39 -04:00
devalkeralia 96aad51fdf Added a return statement if the response.content is empty 2016-06-24 17:14:27 -04:00
devalkeralia 542dcb71d5 Changed ExecutAsync to ExecuteAsyncPost to handle Json error 2016-06-22 12:31:50 -04:00
jaredbroad e9b2b34fa0 Speed updates for desktop charting 2016-06-16 23:30:11 -04:00
Michael Handschuh 68e267474e Merge remote-tracking branch 'origin/master' into multi-subscriptions 2016-04-20 12:14:20 -04:00
jaredbroad dd8a6442b6 Tidy unneccessary TravisCI build configuration 2016-04-19 19:51:51 -04:00
jaredbroad f28902cbdf Added messaging to streaming and and ux for when config not set properly 2016-04-19 19:32:40 -04:00
jaredbroad e93006b6a5 Added Travis CI release configuration and disabled views from building in linux 2016-04-15 12:44:37 -04:00
Michael Handschuh e779cab0ab Fixes typo in generating statistics dictionary 2016-04-12 19:06:41 -04:00
jaredbroad 29c3859f80 Save off reference to event handlers for robustness 2016-04-12 13:32:34 -04:00
jaredbroad 2670b41be6 Bug fixes and event onload for when embed url is loaded 2016-04-11 20:06:25 -04:00
jaredbroad 632c21c99c New UX for LEAN, launched from Launcher using embedded HTML browser 2016-04-11 18:29:50 -04:00