martell's comments

martell | 5 years ago | on: Ask HN: How do international software engineering contracts work?

There seems to be a taxation agreement between Canada and India -

https://www.treaty-accord.gc.ca/text-texte.aspx?lang=eng&id=...

Read article 23 - the elimination of double taxation

Without getting too specific - it seems pretty standard where you would get credit in one country against the other

I don't know the specifics of the difference between being a contractor vs employee in Canada or the implications of that ( in the US they are very distinct ). My best guess however based on the circumstances is that your (ex)-employer withholds tax for the Canadian government and then you would still declare that income on your Indian tax return and claim the credits for the taxes paid in Canada.

It also seems based on some googling that if you are outside India for 245 days of the year you are non resident - so you might not have to declare your total gross for the year and only the income which is considered based in India.

Again this is just a guess based on past experiences of mine with a lot of assumptions based on 2 very different countries and is most definitely not legal advice - I'd read the treaty thoroughly and try to find an expert in international tax compliance for India & Canada.

Also be extra careful about making sure you get this right - In the US for example when non resident one has to give the US company a W8-BEN (individual) or W8-BEN-E (company) form for them to file the taxes correctly at the end of year and to not withhold tax from you when they pay you when availing of a treaty.

My reference to type of work really refers to what nation states consider work vs product but also some types of work are also exempt from tax where people are at sea or working at an embassy etc

While on the surface software engineering remote from India seems like something outside the scope of Canadian tax law ( if you are non resident to Canada), the government might not look at it that way - is it then considered a product you are selling into Canada and taxable that way? - wording on invoices could have tax implications as a result - so be careful.

Lastly if this is a short term thing then it probably makes sense as an individual - but if this is going to be a long term arrangement you should spend time investigating the pros/cons of creating a company vs being an individual to optimize your return

And Good Luck :)

martell | 5 years ago | on: Ask HN: How do international software engineering contracts work?

Can't say much without knowing the specifics such as, what are the 2 countries, and if this is company to company relationship or company to you individually relationship.

There are things to consider after knowing that such as the type of work, if there is a double taxation agreement between the countries, if it is to you individually were you resident in one or both countries during the year and which one.

Some countries also always expect you to pay tax regardless of presence - for example the US if you are a citizen or permanent resident which is a somewhat more complicated situation

For context I've dealt with some international situations between Ireland and the US in the past - but don't take anything I say as legal advice because IANAL or tax expert

martell | 5 years ago | on: Apple says game streaming services violate App Store policies

Netflix has interactive videos with multiple story path choices which is by definition a kind of game.

In this context it is the same as a game streaming service.

So they have already allowed Netflix to do exactly what they are banning here.

The only technical difference is you have 1 game input every 2-3 minutes vs inputs every 2-3 ms.

martell | 5 years ago | on: Apple confirms cloud gaming services violate App Store guidelines

I understand that you end up with a skinned webkit and JavaScriptCore - A few years ago I wrote bindings for JSC for a mobile game engine so that you could invoke native code from js in an ios app. That aside, my point still stands that they can not possible vet content on the internet, so why should they be able to apply this to streaming games also.

Perhaps netflix would have been a better example. Do they vet every piece of content netflix have, if not then they can't reasonably apply this to games.

martell | 7 years ago | on: Do one have to be an exceptional programmer to contribute to opensource projects

More generally with OSS I have found that it mostly depends on the level of contribution.

There are usually some trivial tasks around docs or simple items that can be done with minimal knowledge of the language or project codebase, additionally there are more low-mid tier tasks that require looking at past commits / structure of the project but follow the same pattern.

source: I have contributed to probably close to 100 OSS projects in the last decade varying in size and complexity.

Specifically With respect to kubernetes I have spent some time with trivial tasks for related projects like acs-engine because I am using azure for deployments.

I have not contributed to TensorFlow but in limited areas I imagine I could help with bindings, cross platform support and maybe optimisations of functions given that this is important because the compute cost involved. I would not however be able to dig into some of the complex models the codebase because I have not studied data-science or in any great detail.

We are in an era where OSS project organisers can now see the value and build on these small changes. If you can get enough people interested and contributing towards a goal you can reach a critical mass.

The one tip I would have if you were looking to get started out in OSS development is to make some kind of assessment around how easy it would be to work on a project.

For example: Rust is very popular right now and has been gaining traction for awhile. This is no accident and building a programming language out in the open is very very difficult. A number of very skilled Engineers have allocated time to mentoring. So if you wanted to just jump in having never contributed before you could just filter an issue by mentor. https://github.com/rust-lang/rust/issues?q=is%3Aopen+is%3Ais... Filtering this further by E-easy to get yourself started.

This is probably not the best example as writing a programming language is not an easy feat. The example was chosen however to more highlight what to look for in projects if you want to get your feet wet and start contributing to OSS.

martell | 7 years ago | on: Implementing Impersonation

> Never, ever disable notifications. Notifications are the only way the user has to cross-check that the agent actually did the thing they were supposed to do, and only that thing.

Disagree here, when the user is not aware of the impersonation disabling things like notifications and the ability of the admin to interact with notifications is the correct thing to do so that the admin does not dismiss other notification on behalf of the user or spam the user from activity the user didn't do themselves. The user could think that their account has been hijacked by an external actor which creates it's own set of trust problems for the user with your product. (I would however, leave them enabled on a non production environment; for testing purposes)

> I worked for a large benefits outsourcing corporation. We had impersonation, and we had a way for agents to cancel notification. A few agents realized they could change a participant address, get a 401k loan, and then cancel the notifications for those things. They used these combined capabilities to steal from our participants.

This sounds like a failure from the product and development team who designed and implemented this system. If you are tracking the impersonation correctly it should be easy to see internally that the user didn't change the address or request a 401k loan themselves and a system should be in place to ensure that such changes get flagged and reviewed.

Impersonation should generally only be used in 3 situations.

1. With a user to reproduce a problem they are having. (In this case leaving notifications enabled should be fine) Though you can use an external integration like inspectlet to (and look at logs) replay user sessions.

2. As read only impersonation to ensure the user world view is correct. (This stops you from testing/navigating everything because some times you need to POST or PUT to get to certain frontend pages or reproduce other user behaviour) It is still very useful though in most cases.

3. A write impersonation on a non production environment (staging/devtest/locally). You can dump production data into one of those to test deeper on the frontend.

In general, some kind of admin panel/support system should be used to do write changes to a users account but lets say you need to do writes on production with impersonations like your example above.

It is generally support staff that is using this feature to write on behalf of the users (developers generally have access to way more and have all other kinds of tools and knowledge at their disposal to manipulate user data)

I always wondered why support systems show staff members user details like the last 4 digits of a SSN instead of hiding that information and having the support member enter in the digits the user gives them to validate and unlock more functionality like your situation above for the duration of the call. This way the admins/support staff can not randomly decide to act on behalf of users, they are also generally going to be on a recorded call so it is easy to ascertain if the user actually needed the impersonation support. This means that the review backlog from the flagged activities is minimal and easy for another isolated team to go through/ heck you could even train some ai models to do that part for you with some voice transcription.

martell | 8 years ago | on: Clang Is Now Used to Build Chrome for Windows

I tend to ignore both gcc and MSVC. Clang is really good at bootstrapping itself with this setup even when cross compiling without any real complexity. Without diverting into a cmake vs autotools battle I like that llvm and clang just work and bootstrap so easily. Gone are the days of messing around with gmp isl and co to bootstrap a toolchain.

martell | 8 years ago | on: Clang Is Now Used to Build Chrome for Windows

mingw-w64 llvm maintainer/developer here.

Over the past 2-3 years, with great help from a few other LLVM devs I have slowly pushed for native clang support for mingw-w64. With the current in tree HEAD you can now build and bootstrap mingw-w64 with a llvm-only toolchain (no binutils or gcc, thus no disregard of the PECOFF SPEC)

The stack is as follows. LLVM+CLANG+LLD+COMPILER-RT+LIBCXX+LIBCXXABI+LIBUNWIND+MINGW-W64.

The libraries and executables built this way can be dropped into visual studio quite easily, the two environments are now basically interchangeable. This also means we can borrow the PDB debugging work by Zachary Turner and/or any msvc features added to llvm for free that was done by the various googlers working on chrome. See a talk from Reid on the most recent LLVM developer meetup for more info on PDB and how it works. There has been no formal release of this environment yet but you should see something in the coming weeks/months. I keep build scripts here for those interested.

https://github.com/martell/mingw-w64-clang

I'm due another cleanup of the repo now that wine 3.0 is out so I can actually run x64 tests within a linux docker container. I'm going to be doing some blogging to make this more visible with various partners that want to support this.

The most interesting part of this for me was implementing a llvm-dlltool alternative to binutils dlltool that actually works within the PECOFF spec so msvc lib.exe and link.exe likes what it produces.

https://reviews.llvm.org/rL308379

martell | 8 years ago | on: Mozilla Awards Over Half a Million to Open Source Projects

It would be awesome if we could get some security audit funding focused towards rust projects. For example an audit of rustls pki and co, so we can start pushing the rust ecosystem forward without having to depend on c/c++ projects like openssl for production use. Fingers Crossed :D

martell | 8 years ago | on: Using Clang on Windows

> (We still link Chrome on Windows with link.exe even when compiling with Clang.)

I wasn't aware of this, I know Rui the COFF owner in lld puts in a lot of effort into lld for chrome link times. Maybe he just uses it as a benchmark then :D

I actually caused a regression in migrating def code from lld to llvm with symbol mangling because we were missing a test case for this specific type of mangling and within hours it ended up on a chromium bug tracker and was fixed also within hours by Reid another googler on LLVM.

martell | 8 years ago | on: Using Clang on Windows

This seems super interesting, I am currently looking at building the whole mingw-w64 crt as LTO libs.

I wonder if this would be applicable with that in combination with gcc-rs.

Disclaimer: I'm also on that rust hype train :)

martell | 8 years ago | on: Using Clang on Windows

By using clang-cl you are getting the advantage of the LLVM backend.

LLVM/Clang can target many different platforms besides windows and it is open source so it is sponsored by many large companies including Google Apple etc.

Google use it for Chrome for example (which includes windows) and have engineers working full time to meet their needs.

Intel, ARM, AMD and co have upstreamed many optimisations into LLVM also.

If you have a bug it probably will be resolved faster. Instead of waiting months for the next Visual Studio Release etc

In general, LLVM because of the intermediate bytecode language and well made libraries like libclang enables new kind of tooling.

Microsoft actually use LLVM themselves in many places and have a bunch of open source projects that use it, which is great

The would actually probably be better off retiring MSVC's c++ compiler and focus on clang along with everyone else because other companies are basically paying for the engineering for their platform with clang.

Unlike gcc the license for llvm/clang is more liberal so if they want private internal tooling they can still do that also.

martell | 8 years ago | on: Using Clang on Windows

Exactly, In fact clang, clang++ and clang-cl are all the same program. The frontend just behaves differently based on the file name.

Disclaimer: I am a LLVM Engineer working on a mingw-w64 standalone clang :)

martell | 9 years ago | on: Iaito – A Qt and C++ GUI for radare2 reverse engineering framework

MSVC is the main target for windows for qt5.

They do provide a mingw version to support the community of devs and are great for accepting code upstream.

With most projects however mingw targets are often somewhat neglected and broken even with release versions in some subtle ways.

Our Mingw packages are actually used more broadly by devs on a daily basis and tested regularly by a package manager with other projects that depend on qt5.

Fixes end up in msys2 before they reach qt5 upstream because of that, some times we have too many as you can see here.

https://github.com/Alexpux/MINGW-packages/tree/master/mingw-...

We also have static builds and 64bit support for the mingw-w64 target as previously mentioned by jsheard

page 1