Code Monkey home page Code Monkey logo

future's Introduction

future's People

Contributors

dhhyuk avatar heckj avatar kean avatar moto0000 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  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

future's Issues

question/possible bug - platforms designation in package is latest on all fronts

I pulled 0.4.0 after you tagged it and included it into a project, noticing almost immediately after that you'd updated the platforms designator in Package.swift to be some of the more recent ones.

I'm not sure if that was explicitly intentional, and you didn't want to support older versions with this library and release version, which is the implication. You may already know this, but the platform segment of Package.swift provides the "minimum level" of API by platform that is to be supported by the code, roughly equivalent and related to the @available() macro that's used to indicate specific APIs aren't available before a given point.

In practice, this means that anyone relying on Future with this version (0.4.0) can't link to generate targets earlier than macOS 10.13, iOS & tvOS 11, etc. I didn't see any of those specific changes in the recent updates, so I think these could easily be older versions without any ill effect.

I understand this is your library and you want to be clear about expectations around "supported" versions, as such it's clearly your call - but I'd like to encourage you to consider being as conservative as possible with updating those values, as it promotes constraints external to this library on anyone using it that may not be needed.

Feature request: allow throwing inside map/flatMap closures

Similar to the Swift NIO EventLoopFuture implementation, it would be nice to be able to do something like this:

let someFuture: Future<Data, Error> ...
someFuture.map { someData -> SomeCodableObject in 
    let decoder = JSONDecoder()
    return try decoder.decode(SomeCodableObject.self, someData)
}

This would also apply to flatMap and the other operators of course.

Although it would probably break the typed error functionalities.

Question - open to support swift on linux with this?

I was looking around at promise style libraries to help solve a problem in another project, and wanted to utilize this library. It's pretty close, but doesn't currently easily (and consistently) support swift on linux out of the box. I'm willing to make some tweaks and updates to enable that, but wanted to inquire first if that would be acceptable.

I've offered a partial (small) update to Package.swift in #10 - but I'd like to take it a bit further based on my initial exploration:

  • update the tests to push them slightly lower (into a subdirectory) to more easily exclude the Host IOS app
  • add swift test to macOS command line to validate that continues to work as expected (not just through xcodebuild)
  • add linux focused CI running the tests (in either .travis or .github actions, if you have a preference)
  • replace the arc4random usage in the test extensions with a more platform neutral https://developer.apple.com/documentation/swift/randomnumbergenerator

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.