Code Monkey home page Code Monkey logo

bot.dart's People

Contributors

adam-singer avatar dvorapa avatar eskimoblood avatar kevmoo avatar sethladd avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bot.dart's Issues

"Upstream" code integration

I have written some open source dart here: https://github.com/generateui/Dartan.
Candidates to possibly move to this lib:
-Observable (+ListenableList)
-Some functions in Dartan.dart
-Copyable interface? (Dartan.dart)

or maybe other code I haven't realized it's genericity from. If there's any code there, feel feel to c/p, or drop me a line here, I can tailor it to work with the rest of this lib.

Error: line 129 pos 27: class '_HopTestConfiguration@0x3e30fde0'

Sorry to trouble you, but when recently updating my dart to r19425, running my hop_runner I get:

'package:bot/src/hop_tasks/unit_test.dart': Error: line 129 pos 27: class '_HopTestConfiguration@0x3e30fde0' overrides function 'handleExternalError' of super class 'Configuration' with incompatible parameters
  void handleExternalError(error, String message) {

Then after pub install, I got the following error even after trying various back versions of bot in my pubspec.yaml.

Some packages that were installed are not compatible with your SDK version 0.4.1+0.r19425 and may not work:
- 'browser' requires >=0.4.2
- 'html5lib' requires >=0.4.2+0.r20121
- 'args' requires >=0.4.2
- 'meta' requires >=0.4.2
- 'logging' requires >=0.4.2+1
- 'unittest' requires >=0.4.2
- 'pathos' requires >=0.4.2
- 'source_maps' requires >=0.4.2+0.r20121

DumpRenderTree unit test task

Opening up for discussion the idea of having DumpRenderTree hop task. DRT should be shipped now with the DartEditor, not sure if it will be shipped with the sdk. Since its not with the sdk this might be better off as a custom process.

Event code review

feedback per @sam-mccall

I agree this is definitely something Dart needs, it'd be a shame if it wasn't 'built-in' enough for dart:html to use it, because that's probably the biggest source of events.

My nitpicks, in descending order of (perceived) importance:

  • 'sender' isn't always useful and is often meaningless. It complicates the API and makes fortuitous compatibility between function types (e.g. [1,2,3].forEach(print)) less likely.
    For the cases it is needed, it can easily be attached to the event object, this is an established convention in DOM land.
    (Nice side effect of removing it, EventHandler goes away because it's just Function)
  • The separation of EventHandle and IEvent is confusing and doesn't add value.
  • EventHandler and EventHandle are too similar, and I don't find the latter descriptive. I'd prefer EventSource or similar.
  • IEvent is a bad name - it's not an event (it's something like a type of event) and interfaces don't have a prefix in Dart. Went with EventRoot
  • I don't understand how handlerCount could be useful - either List<EventHandler<T>> handlers or nothing would be better (or even bool hasHandlers, but I'm skeptical)
  • Lack of closurization identity is a bummer. One alternative is to have add() return a function that, when called, removes the handler. I don't feel strongly either way though.

hop_runner.dart with analyze_lib does not work from Windows command prompt

dart_analyzer fails very much like issue #51 on Windows due to error in path.
Related to conversation at johnmccutchan/spectre#58

Example:

C:\Users\Paul\Documents\Code\github\PaulECoyote\spectre>dart tool\hop_runner.dart analyze_test
analyze_test: Exception thrown by task
analyze_test: ProcessException: The system cannot find the file specified.

                Command: dart_analyzer --extended-exit-code --work C:\Users\Paul
\AppData\Local\Temp\tempdir-04824fea-8b4b-11e2-b9d6-b959b7d0a571 test\test_runner.dart
Task did not complete - EXCEPTION (81)

Remove copy of unittest code

Waiting on a clean model from the core lib. At the moment, one needs to hard-wire paths to the local install of the SDK, which is just asking for trouble.

CC @prujohn

Why only shiftKey in ElementMouseEventArgs?

Really more of a question than an issue:

Brand new to dart here and was browsing pop-pop-win. Wanted to change shift-click to right-click for flagging balloons and made my way back to this class:
https://github.com/kevmoo/bot.dart/blob/master/lib/src/retained/element_mouse_event_args.dart

just curious why mouseEvent is being parsed down to just the shiftKey state in the bag of tricks retained library rather than bringing all the mouseEvent args to support various use-cases?

What geometric class to we need

I think about to implement line, ellipse, triangle, rect, polygon classes. Also the Size class needs to be rewritten as it only works for rects. Btw. why is the rect class called PRect?

dart_analyzer task

Just want to open up interest before actually implementing. Like to collect feedback before integrating into a hop task.

I've been toying around with the idea of using the dart_analyzer as a first pass before running unit tests. Running it against code that might not be directly unit tested such as example/ or some code in web/. Also could easily be used for the other folders lib, bin, etc.. The idea is to catch bit rot or warnings earlier then later. You might want to be notified earlier then later, for example, deprecated members, multiple part/part of, just wonky stuff a static checker would know about. I've put together a sample of what I'm thinking here and what potential output would look like here, scroll to the bottom. Its also kind of nice to have something "testable" or "checkable" before actually having a good collection of unit tests in place.

Array2d .get()

I'm getting this exception:

Exception: '.../web/packages/bot/src/bot/collection/array_2d.dart':
Failed assertion: line 109 pos 12: 'y >= 0 && y < height' is not true.

The line it occurred:
m.geometry.vertices = grid.hexes.get(i, j).vertices;

Some more information about my Array2d implementation:
Array2d hexes;
hexes = new Array2d(height, width);

I add elements like so:
hexes.set(0, 0, new HexCell(0.0 + xOffset, 0.0 + yOffset, side));

And before this exception occurs, I get elements just fine like so:
print(hexes.get(i, j).position().toString());

The above prints my objects just fine:
(1.0, 1.0, 0.0)
(76.0, 44.30127018922194, 0.0)
(151.0, 1.0, 0.0)
(226.0, 44.30127018922194, 0.0)
(301.0, 1.0, 0.0)
(376.0, 44.30127018922194, 0.0)
...
...
..

Any idea what the issue might be?

Thank you!

You can reference the SDK unit test files

Use

import('path/to/your/dart/sdk/location/unittest/unittest.dart');

The problem right now is that everyone who forks/clones this will have their SDK files in a different path. This will get better if they make it part of the core dart namespace ("dart:unittest") or when the pub packaging system is ready.

But that's ok, they are just unit tests... ;)

ReadOnlyCollection's superclass must be const

Just got the following error after updating to Dart SDK version 0.3.2.0_r17657.
This is with bot 0.11.3.

/bot/src/bot/collection/read_only_collection.dart': Error: line 3 pos 7: superclass 'ListBase' must be const
class ReadOnlyCollection extends ListBase {
^

Making the constructor const seems to fix it, but I'm a noob in dart :)

License?

I typically use Apache 2.0, but would accept something more liberal like the MIT license. Either way, this should be established up front, so contributors know what they are licensing under.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.